forked from Public/monero-gui
Merge pull request #73
4155944remove wizardOpenWallet.qml - not ready yet (Jacob Brydolf)0691b48Don't send path as argument on wallet store (windows fix) (Jacob Brydolf)9cc3deeRemove trailing slash on wallet_path (Jacob Brydolf)fc2a086corrected path on wallet store after refresh (Jacob Brydolf)10d3d3fSave wallet after every refresh (Jacob Brydolf)
This commit is contained in:
11
main.qml
11
main.qml
@@ -245,12 +245,11 @@ ApplicationWindow {
|
|||||||
var dTargetBlock = currentWallet.daemonBlockChainTargetHeight();
|
var dTargetBlock = currentWallet.daemonBlockChainTargetHeight();
|
||||||
leftPanel.daemonProgress.updateProgress(dCurrentBlock,dTargetBlock);
|
leftPanel.daemonProgress.updateProgress(dCurrentBlock,dTargetBlock);
|
||||||
|
|
||||||
// Store wallet after first refresh. To prevent broken wallet after a crash
|
// Store wallet after every refresh.
|
||||||
if(isNewWallet && currentWallet.blockChainHeight() > 0){
|
//TODO: Doesn't need path after creation. Change libwalletqt
|
||||||
currentWallet.store(persistentSettings.wallet_path)
|
currentWallet.store("")
|
||||||
isNewWallet = false
|
console.log("Saving wallet");
|
||||||
console.log("wallet stored after first successfull refresh")
|
isNewWallet = false
|
||||||
}
|
|
||||||
|
|
||||||
// initialize transaction history once wallet is initializef first time;
|
// initialize transaction history once wallet is initializef first time;
|
||||||
if (!walletInitialized) {
|
if (!walletInitialized) {
|
||||||
|
|||||||
@@ -111,10 +111,16 @@ Rectangle {
|
|||||||
console.log("Here we apply the settings");
|
console.log("Here we apply the settings");
|
||||||
// here we need to actually move wallet to the new location
|
// here we need to actually move wallet to the new location
|
||||||
|
|
||||||
|
// Remove trailing slash - (default on windows and mac)
|
||||||
|
if (settings.wallet_path.substring(settings.wallet_path.length -1) === "/"){
|
||||||
|
settings.wallet_path = settings.wallet_path.substring(0,settings.wallet_path.length -1)
|
||||||
|
}
|
||||||
|
|
||||||
var new_wallet_filename = settings.wallet_path + "/"
|
var new_wallet_filename = settings.wallet_path + "/"
|
||||||
+ settings.account_name + "/"
|
+ settings.account_name + "/"
|
||||||
+ settings.account_name;
|
+ settings.account_name;
|
||||||
|
|
||||||
|
console.log("saving to wizard: "+ new_wallet_filename)
|
||||||
// moving wallet files to the new destination, if user changed it
|
// moving wallet files to the new destination, if user changed it
|
||||||
if (new_wallet_filename !== settings.wallet_filename) {
|
if (new_wallet_filename !== settings.wallet_filename) {
|
||||||
// using previously saved wallet;
|
// using previously saved wallet;
|
||||||
|
|||||||
Reference in New Issue
Block a user