Add wallet menu
MODIFY
HiddenWallet/HiddenWallet.GUI/HiddenWallet.GUI.njsproj
HiddenWallet/HiddenWallet.GUI/HiddenWallet.GUI.njsproj
<Content Include="app\html\decryption-phase-content.html" />
<Content Include="app\html\decryption-phase-menu.html" />
<Content Include="app\html\shutdown.html" />
+ <Content Include="app\html\wallet-menu.html" />
<Content Include="app\html\wallet-phase-tabs.html" />
<Content Include="index.html" />
<Content Include="package.json" />

ADD
HiddenWallet/HiddenWallet.GUI/app/html/wallet-menu.html
+<!-- The justified navigation menu is meant for single line per list item.
+Multiple lines will require custom code not provided by Bootstrap. -->
+<div class="masthead" id="receive-active">
+ <nav>
+ <ul class="nav nav-justified">
+ <li class="active"><a>Receive</a></li>
+ <li><a href="javascript:walletShow('send')">Send</a></li>
+ <li><a href="javascript:walletShow('history')">History</a></li>
+ </ul>
+ </nav>
+</div>
+
+<div class="masthead" id="send-active">
+ <nav>
+ <ul class="nav nav-justified">
+ <li><a href="javascript:walletShow('receive')">Receive</a></li>
+ <li class="active"><a>Send</a></li>
+ <li><a href="javascript:walletShow('history')">History</a></li>
+ </ul>
+ </nav>
+</div>
+
+<div class="masthead" id="history-active">
+ <nav>
+ <ul class="nav nav-justified">
+ <li><a href="javascript:walletShow('receive')">Receive</a></li>
+ <li><a href="javascript:walletShow('send')">Send</a></li>
+ <li class="active"><a>History</a></li>
+ </ul>
+ </nav>
+</div>
\ No newline at end of file

MODIFY
HiddenWallet/HiddenWallet.GUI/app/js/wallet-phase.js
HiddenWallet/HiddenWallet.GUI/app/js/wallet-phase.js
@@ -25,6 +25,20 @@ function walletPhaseShow(tabItem = "") {
writeHint("Move coins between Alice and Bob only by mixing!");
- document.getElementById("menu").innerHTML = "menu not implemented";
+ walletShow('receive');
document.getElementById("content").innerHTML = "content not implemented";
}
+
+function walletShow(menuItem) {
+ if (menuItem === 'receive') {
+ document.getElementById("menu").innerHTML = document.getElementById("wallet-menu-frame").contentWindow.document.getElementById("receive-active").innerHTML;
+ }
+ else if (menuItem === 'send') {
+ writeHint('Consider feeding nopara73 with some pizza: 186n7me3QKajQZJnUsVsezVhVrSwyFCCZ');
+ document.getElementById("menu").innerHTML = document.getElementById("wallet-menu-frame").contentWindow.document.getElementById("send-active").innerHTML;
+ }
+ else if (menuItem === 'history') {
+ document.getElementById("menu").innerHTML = document.getElementById("wallet-menu-frame").contentWindow.document.getElementById("history-active").innerHTML;
+ writeHint('HiddenWallet? Easy Peasy Lemon Squeezey!');
+ }
+}
\ No newline at end of file

MODIFY
HiddenWallet/HiddenWallet.GUI/index.html
HiddenWallet/HiddenWallet.GUI/index.html
</head>
<body onload="decryptionPhaseShow(); periodicStatusUpdate();">
<iframe id="decryption-phase-menu-frame" src="app/html/decryption-phase-menu.html" style="display:none"></iframe>
+ <iframe id="wallet-menu-frame" src="app/html/wallet-menu.html" style="display:none"></iframe>
<iframe id="decryption-phase-content-frame" src="app/html/decryption-phase-content.html" style="display:none"></iframe>
<iframe id="wallet-phase-tabs-frame" src="app/html/wallet-phase-tabs.html" style="display:none"></iframe>
<div id="title-bar">
<div id="below-title-bar" class="container">
<h4><span id="hint" class="label label-info"></span></h4>
<div id="tabs"> </div>
+ <br />
<div id="menu"> </div>
<hr />
<div id="content"> </div>

Add wallet menu