1
0
This commit is contained in:
Scott E. Graves
2017-05-05 09:35:52 -05:00
parent cfb393cb91
commit c5eaa64c13
2 changed files with 42 additions and 8 deletions

View File

@@ -206,6 +206,16 @@
</div>
</div>
</div>
<div class="hidden-element" id="send_window">
<div class="box">
<h1>Send to Address</h1>
<input type="text" id="ID_Send_Address" style="width: 100%;"><br><br>
<h1>Send Amount <a href="javascript:void(0)" id="ID_SendMaxAmount">max</a></h1>
<input type="number" id="ID_Send_Amount"><br><br>
<button id="ID_SendOK" type="button">Send</button>
<button id="ID_SendCancel" type="button">Cancel</button>
</div>
</div>
<div id="shutdown_window" class="hidden-element" style="padding: 0; margin: 0;position: fixed; height: 100%; width: 100%;background-image: url(./images/shutdown.gif); background-size: 100% 100%; background-repeat: no-repeat; z-index: 99999"></div>
</body>
</html>

View File

@@ -330,17 +330,16 @@
}
function handleRenterUploads() {
setMainWindow('upload_progress_window');
const okButton = document.getElementById('ID_RenterUploadsOk');
okButton.onclick = () => {
okButton.onclick = null;
beginMainApplication(false);
};
setMainWindow('upload_progress_window');
}
function handleSiaEditSettings() {
setMainWindow('sia_settings_window');
const cancelButton = document.getElementById('ID_SiaSettingsCancel');
cancelButton.onclick = () => {
cancelButton.onclick = null;
@@ -372,15 +371,39 @@
}
});
};
setMainWindow('sia_settings_window');
}
function handleWalletSend() {
const saveButton = document.getElementById('ID_SendOK');
const cancelButton = document.getElementById('ID_SendCancel');
cancelButton.onclick = () => {
cancelButton.onclick = null;
saveButton.onclick = null;
beginMainApplication(false);
};
saveButton.onclick = () => {
cancelButton.onclick = null;
saveButton.onclick = null;
beginMainApplication(false);
};
setMainWindow('send_window');
}
function beginMainApplication(checkAutoMount) {
setMainWindow('app_window');
const settingsEditLink = document.getElementById('ID_Sia_Settings_Edit');
settingsEditLink.onclick = () => {
settingsEditLink.onclick = null;
handleSiaEditSettings();
};
const sendLink = document.getElementById('ID_Wallet_Send');
sendLink.onclick = () => {
sendLink.onclick = null;
handleWalletSend();
};
const renterEditLink = document.getElementById('ID_Renter_Edit');
renterEditLink.onclick = () => {
renterEditLink.onclick = null;
@@ -430,6 +453,7 @@
if (checkAutoMount) {
AppActions.autoMountDrive( );
}
setMainWindow('app_window');
}
function handleRenterEditSettings() {
@@ -495,7 +519,6 @@
}
function manualUnlockWallet() {
setMainWindow('unlock_window');
const unlockButton = document.getElementById('ID_UnlockWalletButton');
unlockButton.onclick = () => {
unlockButton.onclick = null;
@@ -515,6 +538,7 @@
password.value = '';
}
};
setMainWindow('unlock_window');
}
function handleUnlockWallet() {
@@ -536,17 +560,16 @@
}
function handleWalletCreated(seed) {
setMainWindow('wallet_created_window');
document.getElementById('ID_WalletSeed').innerText = seed;
const button = document.getElementById('ID_WalletCreatedButton');
button.onclick = () => {
button.onclick = null;
handleUnlockWallet();
};
setMainWindow('wallet_created_window');
}
function handleCreateWallet() {
setMainWindow('create_window');
const createButton = document.getElementById('ID_CreateWalletButton');
createButton.onclick = () => {
createButton.onclick = null;
@@ -560,6 +583,7 @@
}
});
};
setMainWindow('create_window');
}
function reloadApplication(checkAutoMount) {