From 284216ac4c991481da4cac38a476b16c45712317 Mon Sep 17 00:00:00 2001 From: Michael Date: Wed, 26 Apr 2017 19:03:02 -0400 Subject: SuperDesk now has a shiftnet site. --- ShiftOS.WinForms/Program.cs | 26 +++++++++++++++++++++++--- 1 file changed, 23 insertions(+), 3 deletions(-) (limited to 'ShiftOS.WinForms/Program.cs') diff --git a/ShiftOS.WinForms/Program.cs b/ShiftOS.WinForms/Program.cs index 3343cb0..a8f5693 100644 --- a/ShiftOS.WinForms/Program.cs +++ b/ShiftOS.WinForms/Program.cs @@ -103,15 +103,15 @@ namespace ShiftOS.WinForms foreach(var exe in Directory.GetFiles(Environment.CurrentDirectory)) { - if(exe.EndsWith(".exe") || exe.EndsWith(".dll")) + if (exe.EndsWith(".exe") || exe.EndsWith(".dll")) { try { var asm = Assembly.LoadFile(exe); - foreach(var type in asm.GetTypes()) + foreach (var type in asm.GetTypes()) { var attrib = type.GetCustomAttributes(false).FirstOrDefault(x => x is AppscapeEntryAttribute) as AppscapeEntryAttribute; - if(attrib != null) + if (attrib != null) { var upgrade = new ShiftoriumUpgrade { @@ -124,7 +124,27 @@ namespace ShiftOS.WinForms }; defaultList.Add(upgrade); } + + var sattrib = type.GetCustomAttributes(false).FirstOrDefault(x => x is StpContents) as StpContents; + if (sattrib != null) + { + var upgrade = new ShiftoriumUpgrade + { + Id = sattrib.Upgrade, + Name = sattrib.Name, + Description = "This is a hidden dummy upgrade for the .stp file installation attribute \"" + sattrib.Name + "\".", + Cost = 0, + Category = "If this is shown, there's a bug in the Shiftorium Provider or the user is a supreme Shifter.", + Dependencies = "dummy_nodisplay" + }; + defaultList.Add(upgrade); + } + } + + + + } catch { } } -- cgit v1.2.3