UI Slice 5: Menueleiste (Fenster nebeneinander), sicheres Beenden, Modul-Aktivierung
- Fenster-Menue: WindowMenu fuellt die oberste MenuStrip mit Top-Level-Eintraegen nebeneinander (mit Icon) statt Untermenue "Fenster"; ModuleView.Icon zentral in der App zugewiesen (AssignMenuIcons). Kein miFenster mehr im Launcher-Designer. - Sicheres Beenden: ShutdownConfirmDialog (10s-Timer sperrt "Jetzt beenden", Abbrechen jederzeit) via IModuleUiHost.RequestShutdown(). Nur der Launcher (Hauptprozess) bietet "Beenden"; andere Fenster nur "Fenster schliessen" (kein App-Shutdown, Module laufen weiter). Launcher-Schliessen-X routet ueber dieselbe Abfrage. - Modul-Aktivierung (restart-basiert): ServerSettings.DisabledModules, in Program.Main vor der DI-Registrierung gefiltert -> deaktivierte Module werden nicht geladen. Dashboard-Tab "Module" zeigt Status + schaltet um (Hinweis: greift nach Neustart). Optionaler IPolyTraderModule.GetActivationBlocker fuer "nicht aktivierbar"-Info. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 4.8
parent
886de3a85b
commit
039bc240f8
Generated
+98
-2
@@ -58,8 +58,17 @@ namespace PolyTraderSharp.Ui.Views
|
||||
lblErgebnis = new Label();
|
||||
tbSearch = new TextBox();
|
||||
lblSuche = new Label();
|
||||
tabModules = new TabPage();
|
||||
dgvModules = new DataGridView();
|
||||
colModName = new DataGridViewTextBoxColumn();
|
||||
colModStatus = new DataGridViewTextBoxColumn();
|
||||
colModHint = new DataGridViewTextBoxColumn();
|
||||
colModAction = new DataGridViewButtonColumn();
|
||||
lblModulesInfo = new Label();
|
||||
toolStripDash.SuspendLayout();
|
||||
tabControlDash.SuspendLayout();
|
||||
tabModules.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)dgvModules).BeginInit();
|
||||
tabDashboard.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)picEquity).BeginInit();
|
||||
pnlChartsBottom.SuspendLayout();
|
||||
@@ -140,6 +149,7 @@ namespace PolyTraderSharp.Ui.Views
|
||||
//
|
||||
tabControlDash.Controls.Add(tabDashboard);
|
||||
tabControlDash.Controls.Add(tabHistory);
|
||||
tabControlDash.Controls.Add(tabModules);
|
||||
tabControlDash.Dock = DockStyle.Fill;
|
||||
tabControlDash.Location = new Point(0, 34);
|
||||
tabControlDash.Margin = new Padding(4, 5, 4, 5);
|
||||
@@ -452,9 +462,86 @@ namespace PolyTraderSharp.Ui.Views
|
||||
lblSuche.Size = new Size(63, 25);
|
||||
lblSuche.TabIndex = 0;
|
||||
lblSuche.Text = "Suche:";
|
||||
//
|
||||
//
|
||||
// tabModules
|
||||
//
|
||||
tabModules.Controls.Add(dgvModules);
|
||||
tabModules.Controls.Add(lblModulesInfo);
|
||||
tabModules.Location = new Point(4, 34);
|
||||
tabModules.Margin = new Padding(4, 5, 4, 5);
|
||||
tabModules.Name = "tabModules";
|
||||
tabModules.Padding = new Padding(12, 12, 12, 12);
|
||||
tabModules.Size = new Size(1706, 1000);
|
||||
tabModules.TabIndex = 2;
|
||||
tabModules.Text = "Module";
|
||||
tabModules.UseVisualStyleBackColor = true;
|
||||
//
|
||||
// lblModulesInfo
|
||||
//
|
||||
lblModulesInfo.Dock = DockStyle.Top;
|
||||
lblModulesInfo.Font = new Font("Segoe UI", 10F);
|
||||
lblModulesInfo.Location = new Point(12, 12);
|
||||
lblModulesInfo.Name = "lblModulesInfo";
|
||||
lblModulesInfo.Padding = new Padding(4, 8, 4, 12);
|
||||
lblModulesInfo.Size = new Size(1682, 56);
|
||||
lblModulesInfo.TabIndex = 0;
|
||||
lblModulesInfo.Text = "Module aktivieren/deaktivieren. Änderungen greifen nach dem nächsten Neustart von PolyTrader.";
|
||||
//
|
||||
// dgvModules
|
||||
//
|
||||
dgvModules.AllowUserToAddRows = false;
|
||||
dgvModules.AllowUserToDeleteRows = false;
|
||||
dgvModules.AllowUserToResizeRows = false;
|
||||
dgvModules.AutoGenerateColumns = false;
|
||||
dgvModules.ColumnHeadersHeightSizeMode = DataGridViewColumnHeadersHeightSizeMode.AutoSize;
|
||||
dgvModules.Columns.AddRange(new DataGridViewColumn[] { colModName, colModStatus, colModHint, colModAction });
|
||||
dgvModules.Dock = DockStyle.Fill;
|
||||
dgvModules.Location = new Point(12, 68);
|
||||
dgvModules.Margin = new Padding(4, 5, 4, 5);
|
||||
dgvModules.Name = "dgvModules";
|
||||
dgvModules.ReadOnly = true;
|
||||
dgvModules.RowHeadersVisible = false;
|
||||
dgvModules.RowHeadersWidth = 62;
|
||||
dgvModules.SelectionMode = DataGridViewSelectionMode.FullRowSelect;
|
||||
dgvModules.Size = new Size(1682, 920);
|
||||
dgvModules.TabIndex = 1;
|
||||
//
|
||||
// colModName
|
||||
//
|
||||
colModName.DataPropertyName = "Modul";
|
||||
colModName.HeaderText = "Modul";
|
||||
colModName.Name = "colModName";
|
||||
colModName.ReadOnly = true;
|
||||
colModName.Width = 220;
|
||||
//
|
||||
// colModStatus
|
||||
//
|
||||
colModStatus.DataPropertyName = "Status";
|
||||
colModStatus.HeaderText = "Status";
|
||||
colModStatus.Name = "colModStatus";
|
||||
colModStatus.ReadOnly = true;
|
||||
colModStatus.Width = 260;
|
||||
//
|
||||
// colModHint
|
||||
//
|
||||
colModHint.AutoSizeMode = DataGridViewAutoSizeColumnMode.Fill;
|
||||
colModHint.DataPropertyName = "Hinweis";
|
||||
colModHint.HeaderText = "Hinweis";
|
||||
colModHint.Name = "colModHint";
|
||||
colModHint.ReadOnly = true;
|
||||
//
|
||||
// colModAction
|
||||
//
|
||||
colModAction.DataPropertyName = "Aktion";
|
||||
colModAction.HeaderText = "Aktion";
|
||||
colModAction.Name = "colModAction";
|
||||
colModAction.ReadOnly = true;
|
||||
colModAction.Text = "Umschalten";
|
||||
colModAction.UseColumnTextForButtonValue = false;
|
||||
colModAction.Width = 160;
|
||||
//
|
||||
// DashboardView
|
||||
//
|
||||
//
|
||||
AutoScaleDimensions = new SizeF(10F, 25F);
|
||||
AutoScaleMode = AutoScaleMode.Font;
|
||||
ClientSize = new Size(1714, 1083);
|
||||
@@ -477,6 +564,8 @@ namespace PolyTraderSharp.Ui.Views
|
||||
((System.ComponentModel.ISupportInitialize)dgvTrades).EndInit();
|
||||
pnlHistFilters.ResumeLayout(false);
|
||||
pnlHistFilters.PerformLayout();
|
||||
tabModules.ResumeLayout(false);
|
||||
((System.ComponentModel.ISupportInitialize)dgvModules).EndInit();
|
||||
ResumeLayout(false);
|
||||
PerformLayout();
|
||||
}
|
||||
@@ -523,5 +612,12 @@ namespace PolyTraderSharp.Ui.Views
|
||||
private System.Windows.Forms.DataGridViewTextBoxColumn colPnl;
|
||||
private System.Windows.Forms.DataGridViewTextBoxColumn colPnlPct;
|
||||
private System.Windows.Forms.DataGridViewTextBoxColumn colClosedAt;
|
||||
private System.Windows.Forms.TabPage tabModules;
|
||||
private System.Windows.Forms.Label lblModulesInfo;
|
||||
private System.Windows.Forms.DataGridView dgvModules;
|
||||
private System.Windows.Forms.DataGridViewTextBoxColumn colModName;
|
||||
private System.Windows.Forms.DataGridViewTextBoxColumn colModStatus;
|
||||
private System.Windows.Forms.DataGridViewTextBoxColumn colModHint;
|
||||
private System.Windows.Forms.DataGridViewButtonColumn colModAction;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user