UI: Master-Key-Button (Settings, via Designer) + UI-Designer-WIP + Steuer-PDF
- Settings: neuer Toolbar-Button 'Master-Key erzeugen' (Tab General Settings, via Designer). Erzeugt zufaelligen 32-Byte-AES-Key -> master.key (gitignored), nur aktiv wenn KEIN Key existiert (Env-Var oder Datei), Lockout-Schutz + Backup-Warnung, danach deaktiviert. - Einbezogen: laufende Designer-Umstrukturierung (SettingsView/LauncherForm: Button-Bilder aus Properties.Resources statt eingebettet; dgv_accountlist im Launcher; DashboardView.resx). - docs/steuer: US-CPA-Fragebogen als PDF. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 4.8
parent
36c89a6acf
commit
4df07bd3d2
Generated
+89
-117
@@ -17,52 +17,48 @@ namespace PolyTraderSharp.Ui.Views
|
||||
|
||||
private void InitializeComponent()
|
||||
{
|
||||
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(SettingsView));
|
||||
propertyGrid = new PropertyGrid();
|
||||
toolStrip1 = new ToolStrip();
|
||||
tabControl1 = new TabControl();
|
||||
tabPage1 = new TabPage();
|
||||
tabPage2 = new TabPage();
|
||||
toolStrip2 = new ToolStrip();
|
||||
btn_save = new ToolStripButton();
|
||||
btn_loadsettings = new ToolStripButton();
|
||||
btnGenMasterKey = new ToolStripButton();
|
||||
tabPage2 = new TabPage();
|
||||
pgAccount = new PropertyGrid();
|
||||
dgvAccounts = new DataGridView();
|
||||
toolStripAccounts = new ToolStrip();
|
||||
btnAccNew = new ToolStripButton();
|
||||
btnAccDelete = new ToolStripButton();
|
||||
dgvAccounts = new DataGridView();
|
||||
colAccName = new DataGridViewTextBoxColumn();
|
||||
colAccWallet = new DataGridViewTextBoxColumn();
|
||||
colAccDemo = new DataGridViewCheckBoxColumn();
|
||||
colAccActive = new DataGridViewCheckBoxColumn();
|
||||
pgAccount = new PropertyGrid();
|
||||
tabControl1.SuspendLayout();
|
||||
tabPage1.SuspendLayout();
|
||||
tabPage2.SuspendLayout();
|
||||
toolStrip2.SuspendLayout();
|
||||
toolStripAccounts.SuspendLayout();
|
||||
tabPage2.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)dgvAccounts).BeginInit();
|
||||
toolStripAccounts.SuspendLayout();
|
||||
SuspendLayout();
|
||||
//
|
||||
//
|
||||
// propertyGrid
|
||||
//
|
||||
//
|
||||
propertyGrid.Dock = DockStyle.Bottom;
|
||||
propertyGrid.Location = new Point(3, 610);
|
||||
propertyGrid.Margin = new Padding(4, 25, 4, 5);
|
||||
propertyGrid.Name = "propertyGrid";
|
||||
propertyGrid.Size = new Size(1171, 274);
|
||||
propertyGrid.TabIndex = 1;
|
||||
//
|
||||
//
|
||||
// toolStrip1
|
||||
//
|
||||
//
|
||||
toolStrip1.ImageScalingSize = new Size(24, 24);
|
||||
toolStrip1.Location = new Point(0, 0);
|
||||
toolStrip1.Name = "toolStrip1";
|
||||
toolStrip1.Size = new Size(1185, 25);
|
||||
toolStrip1.TabIndex = 2;
|
||||
toolStrip1.Text = "toolStrip1";
|
||||
//
|
||||
//
|
||||
// tabControl1
|
||||
//
|
||||
//
|
||||
tabControl1.Anchor = AnchorStyles.Top | AnchorStyles.Bottom | AnchorStyles.Left | AnchorStyles.Right;
|
||||
tabControl1.Controls.Add(tabPage1);
|
||||
tabControl1.Controls.Add(tabPage2);
|
||||
@@ -71,9 +67,9 @@ namespace PolyTraderSharp.Ui.Views
|
||||
tabControl1.SelectedIndex = 0;
|
||||
tabControl1.Size = new Size(1185, 925);
|
||||
tabControl1.TabIndex = 3;
|
||||
//
|
||||
//
|
||||
// tabPage1
|
||||
//
|
||||
//
|
||||
tabPage1.Controls.Add(toolStrip2);
|
||||
tabPage1.Controls.Add(propertyGrid);
|
||||
tabPage1.Location = new Point(4, 34);
|
||||
@@ -83,9 +79,43 @@ namespace PolyTraderSharp.Ui.Views
|
||||
tabPage1.TabIndex = 0;
|
||||
tabPage1.Text = "General Settings";
|
||||
tabPage1.UseVisualStyleBackColor = true;
|
||||
//
|
||||
// toolStrip2
|
||||
//
|
||||
toolStrip2.ImageScalingSize = new Size(24, 24);
|
||||
toolStrip2.Items.AddRange(new ToolStripItem[] { btn_save, btn_loadsettings, btnGenMasterKey });
|
||||
toolStrip2.Location = new Point(3, 3);
|
||||
toolStrip2.Name = "toolStrip2";
|
||||
toolStrip2.Size = new Size(1171, 34);
|
||||
toolStrip2.TabIndex = 0;
|
||||
toolStrip2.Text = "toolStrip2";
|
||||
//
|
||||
// btn_save
|
||||
//
|
||||
btn_save.Image = Properties.Resources.diskette;
|
||||
btn_save.ImageTransparentColor = Color.Magenta;
|
||||
btn_save.Name = "btn_save";
|
||||
btn_save.Size = new Size(150, 29);
|
||||
btn_save.Text = "Save Changes";
|
||||
//
|
||||
// btn_loadsettings
|
||||
//
|
||||
btn_loadsettings.Image = Properties.Resources.token_quantifier;
|
||||
btn_loadsettings.ImageTransparentColor = Color.Magenta;
|
||||
btn_loadsettings.Name = "btn_loadsettings";
|
||||
btn_loadsettings.Size = new Size(223, 29);
|
||||
btn_loadsettings.Text = "Load Settings from File";
|
||||
//
|
||||
// btnGenMasterKey
|
||||
//
|
||||
btnGenMasterKey.DisplayStyle = ToolStripItemDisplayStyle.Text;
|
||||
btnGenMasterKey.Name = "btnGenMasterKey";
|
||||
btnGenMasterKey.Size = new Size(200, 29);
|
||||
btnGenMasterKey.Text = "Master-Key erzeugen";
|
||||
btnGenMasterKey.ToolTipText = "Erzeugt einen zufälligen AES-Master-Key (nur wenn noch keiner existiert).";
|
||||
//
|
||||
// tabPage2
|
||||
//
|
||||
//
|
||||
tabPage2.Controls.Add(pgAccount);
|
||||
tabPage2.Controls.Add(dgvAccounts);
|
||||
tabPage2.Controls.Add(toolStripAccounts);
|
||||
@@ -96,115 +126,56 @@ namespace PolyTraderSharp.Ui.Views
|
||||
tabPage2.TabIndex = 1;
|
||||
tabPage2.Text = "Polymarket Accounts";
|
||||
tabPage2.UseVisualStyleBackColor = true;
|
||||
//
|
||||
// toolStrip2
|
||||
//
|
||||
toolStrip2.ImageScalingSize = new Size(24, 24);
|
||||
toolStrip2.Items.AddRange(new ToolStripItem[] { btn_save, btn_loadsettings });
|
||||
toolStrip2.Location = new Point(3, 3);
|
||||
toolStrip2.Name = "toolStrip2";
|
||||
toolStrip2.Size = new Size(1171, 34);
|
||||
toolStrip2.TabIndex = 0;
|
||||
toolStrip2.Text = "toolStrip2";
|
||||
//
|
||||
// btn_save
|
||||
//
|
||||
btn_save.Image = (Image)resources.GetObject("btn_save.Image");
|
||||
btn_save.ImageTransparentColor = Color.Magenta;
|
||||
btn_save.Name = "btn_save";
|
||||
btn_save.Size = new Size(150, 29);
|
||||
btn_save.Text = "Save Changes";
|
||||
//
|
||||
// btn_loadsettings
|
||||
//
|
||||
btn_loadsettings.Image = (Image)resources.GetObject("btn_loadsettings.Image");
|
||||
btn_loadsettings.ImageTransparentColor = Color.Magenta;
|
||||
btn_loadsettings.Name = "btn_loadsettings";
|
||||
btn_loadsettings.Size = new Size(223, 29);
|
||||
btn_loadsettings.Text = "Load Settings from File";
|
||||
//
|
||||
// toolStripAccounts
|
||||
//
|
||||
toolStripAccounts.ImageScalingSize = new Size(24, 24);
|
||||
toolStripAccounts.Items.AddRange(new ToolStripItem[] { btnAccNew, btnAccDelete });
|
||||
toolStripAccounts.Location = new Point(3, 3);
|
||||
toolStripAccounts.Name = "toolStripAccounts";
|
||||
toolStripAccounts.Size = new Size(1171, 34);
|
||||
toolStripAccounts.TabIndex = 0;
|
||||
//
|
||||
// btnAccNew
|
||||
//
|
||||
btnAccNew.DisplayStyle = ToolStripItemDisplayStyle.Text;
|
||||
btnAccNew.Name = "btnAccNew";
|
||||
btnAccNew.Size = new Size(130, 29);
|
||||
btnAccNew.Text = "Neuer Account";
|
||||
//
|
||||
// btnAccDelete
|
||||
//
|
||||
btnAccDelete.DisplayStyle = ToolStripItemDisplayStyle.Text;
|
||||
btnAccDelete.Name = "btnAccDelete";
|
||||
btnAccDelete.Size = new Size(90, 29);
|
||||
btnAccDelete.Text = "Löschen";
|
||||
//
|
||||
//
|
||||
// pgAccount
|
||||
//
|
||||
pgAccount.Dock = DockStyle.Fill;
|
||||
pgAccount.Location = new Point(623, 37);
|
||||
pgAccount.Name = "pgAccount";
|
||||
pgAccount.Size = new Size(551, 847);
|
||||
pgAccount.TabIndex = 2;
|
||||
//
|
||||
// dgvAccounts
|
||||
//
|
||||
//
|
||||
dgvAccounts.AllowUserToAddRows = false;
|
||||
dgvAccounts.AllowUserToDeleteRows = false;
|
||||
dgvAccounts.AutoGenerateColumns = false;
|
||||
dgvAccounts.ColumnHeadersHeightSizeMode = DataGridViewColumnHeadersHeightSizeMode.AutoSize;
|
||||
dgvAccounts.Columns.AddRange(new DataGridViewColumn[] { colAccName, colAccWallet, colAccDemo, colAccActive });
|
||||
dgvAccounts.Dock = DockStyle.Left;
|
||||
dgvAccounts.Location = new Point(3, 37);
|
||||
dgvAccounts.MultiSelect = false;
|
||||
dgvAccounts.Name = "dgvAccounts";
|
||||
dgvAccounts.ReadOnly = true;
|
||||
dgvAccounts.RowHeadersVisible = false;
|
||||
dgvAccounts.RowHeadersWidth = 62;
|
||||
dgvAccounts.SelectionMode = DataGridViewSelectionMode.FullRowSelect;
|
||||
dgvAccounts.Size = new Size(620, 847);
|
||||
dgvAccounts.TabIndex = 1;
|
||||
//
|
||||
// colAccName
|
||||
//
|
||||
colAccName.DataPropertyName = "Name";
|
||||
colAccName.HeaderText = "Name";
|
||||
colAccName.Name = "colAccName";
|
||||
colAccName.ReadOnly = true;
|
||||
colAccName.Width = 200;
|
||||
//
|
||||
// colAccWallet
|
||||
//
|
||||
colAccWallet.DataPropertyName = "WalletAddress";
|
||||
colAccWallet.HeaderText = "Wallet";
|
||||
colAccWallet.Name = "colAccWallet";
|
||||
colAccWallet.ReadOnly = true;
|
||||
colAccWallet.Width = 260;
|
||||
//
|
||||
// colAccDemo
|
||||
//
|
||||
colAccDemo.DataPropertyName = "IsDemo";
|
||||
colAccDemo.HeaderText = "Demo";
|
||||
colAccDemo.Name = "colAccDemo";
|
||||
colAccDemo.ReadOnly = true;
|
||||
colAccDemo.Width = 60;
|
||||
//
|
||||
// colAccActive
|
||||
//
|
||||
colAccActive.DataPropertyName = "IsActive";
|
||||
colAccActive.HeaderText = "Aktiv";
|
||||
colAccActive.Name = "colAccActive";
|
||||
colAccActive.ReadOnly = true;
|
||||
colAccActive.Width = 60;
|
||||
//
|
||||
// pgAccount
|
||||
//
|
||||
pgAccount.Dock = DockStyle.Fill;
|
||||
pgAccount.Location = new Point(623, 37);
|
||||
pgAccount.Name = "pgAccount";
|
||||
pgAccount.Size = new Size(551, 847);
|
||||
pgAccount.TabIndex = 2;
|
||||
//
|
||||
//
|
||||
// toolStripAccounts
|
||||
//
|
||||
toolStripAccounts.ImageScalingSize = new Size(24, 24);
|
||||
toolStripAccounts.Items.AddRange(new ToolStripItem[] { btnAccNew, btnAccDelete });
|
||||
toolStripAccounts.Location = new Point(3, 3);
|
||||
toolStripAccounts.Name = "toolStripAccounts";
|
||||
toolStripAccounts.Size = new Size(1171, 34);
|
||||
toolStripAccounts.TabIndex = 0;
|
||||
//
|
||||
// btnAccNew
|
||||
//
|
||||
btnAccNew.Image = Properties.Resources.add;
|
||||
btnAccNew.Name = "btnAccNew";
|
||||
btnAccNew.Size = new Size(157, 29);
|
||||
btnAccNew.Text = "Neuer Account";
|
||||
//
|
||||
// btnAccDelete
|
||||
//
|
||||
btnAccDelete.Image = Properties.Resources.cancel;
|
||||
btnAccDelete.Name = "btnAccDelete";
|
||||
btnAccDelete.Size = new Size(104, 29);
|
||||
btnAccDelete.Text = "Löschen";
|
||||
//
|
||||
// SettingsView
|
||||
//
|
||||
//
|
||||
AutoScaleDimensions = new SizeF(10F, 25F);
|
||||
AutoScaleMode = AutoScaleMode.Font;
|
||||
ClientSize = new Size(1185, 1523);
|
||||
@@ -216,13 +187,13 @@ namespace PolyTraderSharp.Ui.Views
|
||||
tabControl1.ResumeLayout(false);
|
||||
tabPage1.ResumeLayout(false);
|
||||
tabPage1.PerformLayout();
|
||||
tabPage2.ResumeLayout(false);
|
||||
tabPage2.PerformLayout();
|
||||
toolStrip2.ResumeLayout(false);
|
||||
toolStrip2.PerformLayout();
|
||||
tabPage2.ResumeLayout(false);
|
||||
tabPage2.PerformLayout();
|
||||
((System.ComponentModel.ISupportInitialize)dgvAccounts).EndInit();
|
||||
toolStripAccounts.ResumeLayout(false);
|
||||
toolStripAccounts.PerformLayout();
|
||||
((System.ComponentModel.ISupportInitialize)dgvAccounts).EndInit();
|
||||
ResumeLayout(false);
|
||||
PerformLayout();
|
||||
}
|
||||
@@ -237,6 +208,7 @@ namespace PolyTraderSharp.Ui.Views
|
||||
private TabPage tabPage2;
|
||||
private ToolStripButton btn_save;
|
||||
private ToolStripButton btn_loadsettings;
|
||||
private ToolStripButton btnGenMasterKey;
|
||||
private ToolStrip toolStripAccounts;
|
||||
private ToolStripButton btnAccNew;
|
||||
private ToolStripButton btnAccDelete;
|
||||
|
||||
Reference in New Issue
Block a user