mirror of
https://github.com/9ParsonsB/Pulsar.git
synced 2025-06-30 16:23:41 -04:00
[Core] Spit and polish on PluginList and tabs (#138)
Add checkboxes to the PluginList which allow you to enable/disable each plugin on-the-fly (it will no longer respond to events, but you can still configure it, etc.). These settings are preserved in a new Core setting. Also enabled full-row select for easier selection in the listview. Also increased the height of the PluginList slightly. (Personally, I'd like it even taller.) Also made slight sizing adjustments to the plugin tabs, which now show 3 letters when collapsed and has a bit of extra space so the longest one does not get cut-off when selected/bolded. Furthermore, the list of plugins is now sorted alphabetically. Finally, set the plugin listview Dock = Fill (vs. Anchored). This seems to have fixed the listview resize problem I was experiencing.
This commit is contained in:
@ -17,7 +17,7 @@ namespace Observatory.UI
|
||||
internal static List<string> CreatePluginTabs(MenuStrip menu, IEnumerable<(IObservatoryWorker plugin, PluginManagement.PluginManager.PluginStatus signed)> plugins, Dictionary<object, Panel> uiPanels)
|
||||
{
|
||||
List<string> pluginList = new List<string>();
|
||||
foreach (var plugin in plugins)
|
||||
foreach (var plugin in plugins.OrderBy(p => p.plugin.ShortName))
|
||||
{
|
||||
AddPlugin(menu, plugin.plugin, plugin.signed, uiPanels);
|
||||
pluginList.Add(plugin.plugin.ShortName);
|
||||
@ -28,7 +28,7 @@ namespace Observatory.UI
|
||||
internal static List<string> CreatePluginTabs(MenuStrip menu, IEnumerable<(IObservatoryNotifier plugin, PluginManagement.PluginManager.PluginStatus signed)> plugins, Dictionary<object, Panel> uiPanels)
|
||||
{
|
||||
List<string> pluginList = new List<string>();
|
||||
foreach (var plugin in plugins)
|
||||
foreach (var plugin in plugins.OrderBy(p => p.plugin.ShortName))
|
||||
{
|
||||
AddPlugin(menu, plugin.plugin, plugin.signed, uiPanels);
|
||||
pluginList.Add(plugin.plugin.ShortName);
|
||||
@ -73,12 +73,13 @@ namespace Observatory.UI
|
||||
View = View.Details,
|
||||
Location = new Point(0, 0),
|
||||
Size = panel.Size,
|
||||
Anchor = AnchorStyles.Left | AnchorStyles.Right | AnchorStyles.Bottom | AnchorStyles.Top,
|
||||
Dock = DockStyle.Fill,
|
||||
BackColor = Color.FromArgb(64, 64, 64),
|
||||
ForeColor = Color.LightGray,
|
||||
ListViewItemSorter = columnSorter,
|
||||
Font = new Font(new FontFamily("Segoe UI"), 10, FontStyle.Regular)
|
||||
};
|
||||
panel.Controls.Add(listView);
|
||||
|
||||
string colSize = Properties.Core.Default.ColumnSizing;
|
||||
List<ColumnSizing>? columnSizing = null;
|
||||
@ -213,8 +214,6 @@ namespace Observatory.UI
|
||||
listView.Sort();
|
||||
};
|
||||
|
||||
panel.Controls.Add(listView);
|
||||
|
||||
plugin.PluginUI.DataGrid.CollectionChanged += (sender, e) =>
|
||||
{
|
||||
var updateGrid = () =>
|
||||
|
Reference in New Issue
Block a user