From 960af0b1692bbf0b40fa8c49732f024f8e6f5933 Mon Sep 17 00:00:00 2001 From: Nathan Woodburn Date: Wed, 14 Jun 2023 15:49:56 +1000 Subject: [PATCH] main: fixed settings location --- FireWallet/DomainForm.cs | 2 -- FireWallet/MainForm.Designer.cs | 30 +++++++++++++++--------------- FireWallet/MainForm.cs | 27 +++++++++++++++------------ 3 files changed, 30 insertions(+), 29 deletions(-) diff --git a/FireWallet/DomainForm.cs b/FireWallet/DomainForm.cs index 55f1a49..5743cb5 100644 --- a/FireWallet/DomainForm.cs +++ b/FireWallet/DomainForm.cs @@ -264,8 +264,6 @@ namespace FireWallet buttonActionAlt.Hide(); buttonActionMain.Hide(); groupBoxAction.Text = "Reserved"; - - } } catch (Exception ex) diff --git a/FireWallet/MainForm.Designer.cs b/FireWallet/MainForm.Designer.cs index 2ecbe9a..b5ef3bb 100644 --- a/FireWallet/MainForm.Designer.cs +++ b/FireWallet/MainForm.Designer.cs @@ -59,7 +59,6 @@ namespace FireWallet buttonNavSend = new Button(); buttonNavPortfolio = new Button(); panelPortfolio = new Panel(); - buttonRenewAll = new Button(); buttonRevealAll = new Button(); groupBoxTransactions = new GroupBox(); groupBoxinfo = new GroupBox(); @@ -70,6 +69,7 @@ namespace FireWallet labelBalanceTotal = new Label(); labelLocked = new Label(); labelBalance = new Label(); + buttonRenewAll = new Button(); panelSend = new Panel(); checkBoxSendSubFee = new CheckBox(); buttonSendMax = new Button(); @@ -400,18 +400,6 @@ namespace FireWallet panelPortfolio.TabIndex = 7; panelPortfolio.Visible = false; // - // buttonRenewAll - // - buttonRenewAll.FlatStyle = FlatStyle.Flat; - buttonRenewAll.Font = new Font("Segoe UI", 12F, FontStyle.Regular, GraphicsUnit.Point); - buttonRenewAll.Location = new Point(813, 9); - buttonRenewAll.Name = "buttonRenewAll"; - buttonRenewAll.Size = new Size(89, 32); - buttonRenewAll.TabIndex = 10; - buttonRenewAll.Text = "Renew All"; - buttonRenewAll.UseVisualStyleBackColor = true; - buttonRenewAll.Click += buttonRenewAll_Click; - // // buttonRevealAll // buttonRevealAll.FlatStyle = FlatStyle.Flat; @@ -518,6 +506,18 @@ namespace FireWallet labelBalance.TabIndex = 0; labelBalance.Text = "labelBalance"; // + // buttonRenewAll + // + buttonRenewAll.FlatStyle = FlatStyle.Flat; + buttonRenewAll.Font = new Font("Segoe UI", 12F, FontStyle.Regular, GraphicsUnit.Point); + buttonRenewAll.Location = new Point(813, 9); + buttonRenewAll.Name = "buttonRenewAll"; + buttonRenewAll.Size = new Size(89, 32); + buttonRenewAll.TabIndex = 10; + buttonRenewAll.Text = "Renew All"; + buttonRenewAll.UseVisualStyleBackColor = true; + buttonRenewAll.Click += buttonRenewAll_Click; + // // panelSend // panelSend.Controls.Add(checkBoxSendSubFee); @@ -792,7 +792,7 @@ namespace FireWallet panelSettings.Controls.Add(buttonSettingsSave); panelSettings.Controls.Add(groupBoxSettingsExplorer); panelSettings.Font = new Font("Segoe UI", 12F, FontStyle.Regular, GraphicsUnit.Point); - panelSettings.Location = new Point(1065, 211); + panelSettings.Location = new Point(1065, 51); panelSettings.Name = "panelSettings"; panelSettings.Size = new Size(930, 550); panelSettings.TabIndex = 19; @@ -1007,6 +1007,7 @@ namespace FireWallet AutoScaleDimensions = new SizeF(7F, 15F); AutoScaleMode = AutoScaleMode.Font; ClientSize = new Size(1152, 575); + Controls.Add(panelSettings); Controls.Add(panelaccount); Controls.Add(panelPortfolio); Controls.Add(panelRecieve); @@ -1014,7 +1015,6 @@ namespace FireWallet Controls.Add(panelSend); Controls.Add(panelNav); Controls.Add(statusStripmain); - Controls.Add(panelSettings); Icon = (Icon)resources.GetObject("$this.Icon"); Name = "MainForm"; Opacity = 0D; diff --git a/FireWallet/MainForm.cs b/FireWallet/MainForm.cs index 9868ca6..937a18a 100644 --- a/FireWallet/MainForm.cs +++ b/FireWallet/MainForm.cs @@ -221,7 +221,8 @@ namespace FireWallet if (hideScreen) { hsdProcess.StartInfo.RedirectStandardError = true; - } else + } + else { hsdProcess.StartInfo.RedirectStandardError = false; } @@ -240,7 +241,7 @@ namespace FireWallet hsdProcess.Start(); // Wait for HSD to start await Task.Delay(2000); - + // Check if HSD is running if (hsdProcess.HasExited) { @@ -866,7 +867,7 @@ namespace FireWallet // Check how many TX there are - APIresponse = await APIGet("wallet/"+ account,true); + APIresponse = await APIGet("wallet/" + account, true); JObject wallet = JObject.Parse(APIresponse); if (!wallet.ContainsKey("balance")) { @@ -883,7 +884,7 @@ namespace FireWallet int toSkip = TotalTX - toGet; // GET TXs - APIresponse = await APIPost("", true, "{\"method\": \"listtransactions\",\"params\": [\"default\"," +toGet+","+ toSkip+ "]}"); + APIresponse = await APIPost("", true, "{\"method\": \"listtransactions\",\"params\": [\"default\"," + toGet + "," + toSkip + "]}"); if (APIresponse == "Error") { @@ -891,7 +892,7 @@ namespace FireWallet return; } JObject TXGET = JObject.Parse(APIresponse); - + // Check for error if (TXGET["error"].ToString() != "") { @@ -950,7 +951,7 @@ namespace FireWallet AutoSize = true, Location = new Point(10, 25) }; - + tmpPanel.Controls.Add(labelHash); JArray inputs = JArray.Parse(tx["inputs"].ToString()); @@ -968,10 +969,10 @@ namespace FireWallet { cost = "Received: " + costHNS.ToString() + " HNS"; } - - - + + + Label labelInputOutput = new Label() { @@ -1172,6 +1173,7 @@ namespace FireWallet } panelSettings.Show(); + panelSettings.Dock = DockStyle.Fill; buttonSettingsSave.Top = panelSettings.Height - buttonSettingsSave.Height - 10; labelSettingsSaved.Top = buttonSettingsSave.Top + 10; textBoxExTX.Text = userSettings["explorer-tx"]; @@ -1677,7 +1679,8 @@ namespace FireWallet domainTMP.Controls.Add(domainName); - if (!name.ContainsKey("stats")) { + if (!name.ContainsKey("stats")) + { AddLog("Domain " + Domains[i] + " does not have stats"); continue; } @@ -1716,8 +1719,8 @@ namespace FireWallet foreach (Control c in domainTMP.Controls) { - c.Click += new EventHandler((sender, e) => - { + c.Click += new EventHandler((sender, e) => + { DomainForm domainForm = new DomainForm(this, name["name"].ToString(), userSettings["explorer-tx"], userSettings["explorer-domain"]); domainForm.Show(); });