aboutsummaryrefslogtreecommitdiff
path: root/src/wallet/wallet2.h
diff options
context:
space:
mode:
authormoneromooo-monero <moneromooo-monero@users.noreply.github.com>2019-03-30 19:21:30 +0000
committermoneromooo-monero <moneromooo-monero@users.noreply.github.com>2019-04-04 18:10:45 +0000
commita2561653cbcba96e7e2dd352b9e0ea57cd220b2c (patch)
treeb41ef6e9785ddd3b46aa3aafff90605a8adc9b11 /src/wallet/wallet2.h
parentMerge pull request #5318 (diff)
downloadmonero-a2561653cbcba96e7e2dd352b9e0ea57cd220b2c.tar.xz
wallet: new option to start background mining
The setup-background-mining option can be used to select background mining when a wallet loads. The user will be asked the first time the wallet is created.
Diffstat (limited to '')
-rw-r--r--src/wallet/wallet2.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/wallet/wallet2.h b/src/wallet/wallet2.h
index 5a67c20d0..4a3f6c7d9 100644
--- a/src/wallet/wallet2.h
+++ b/src/wallet/wallet2.h
@@ -194,6 +194,12 @@ namespace tools
AskPasswordToDecrypt = 2,
};
+ enum BackgroundMiningSetupType {
+ BackgroundMiningMaybe = 0,
+ BackgroundMiningYes = 1,
+ BackgroundMiningNo = 2,
+ };
+
static const char* tr(const char* str);
static bool has_testnet_option(const boost::program_options::variables_map& vm);
@@ -1008,6 +1014,8 @@ namespace tools
void confirm_non_default_ring_size(bool always) { m_confirm_non_default_ring_size = always; }
bool track_uses() const { return m_track_uses; }
void track_uses(bool value) { m_track_uses = value; }
+ BackgroundMiningSetupType setup_background_mining() const { return m_setup_background_mining; }
+ void setup_background_mining(BackgroundMiningSetupType value) { m_setup_background_mining = value; }
const std::string & device_name() const { return m_device_name; }
void device_name(const std::string & device_name) { m_device_name = device_name; }
const std::string & device_derivation_path() const { return m_device_derivation_path; }
@@ -1444,6 +1452,7 @@ namespace tools
uint64_t m_segregation_height;
bool m_ignore_fractional_outputs;
bool m_track_uses;
+ BackgroundMiningSetupType m_setup_background_mining;
bool m_is_initialized;
NodeRPCProxy m_node_rpc_proxy;
std::unordered_set<crypto::hash> m_scanned_pool_txs[2];