aboutsummaryrefslogtreecommitdiff
path: root/source/WindowsFormsApplication1/API.cs
diff options
context:
space:
mode:
Diffstat (limited to 'source/WindowsFormsApplication1/API.cs')
-rw-r--r--source/WindowsFormsApplication1/API.cs18
1 files changed, 18 insertions, 0 deletions
diff --git a/source/WindowsFormsApplication1/API.cs b/source/WindowsFormsApplication1/API.cs
index dfd7eb5..a1be389 100644
--- a/source/WindowsFormsApplication1/API.cs
+++ b/source/WindowsFormsApplication1/API.cs
@@ -1130,6 +1130,7 @@ namespace ShiftOS
formToCreate.Show();
var brdr = new WindowBorder(AppName, AppIcon);
brdr.Tag = "api_brdr";
+ brdr.justopened = true;
formToCreate.Widgets.Add(brdr);
brdr.Show();
foreach(Widget widget in formToCreate.Body.Widgets)
@@ -1141,9 +1142,26 @@ namespace ShiftOS
}
}
brdr.Dock = DockStyle.Fill;
+ BordersToUpdate.Add(brdr);
formToCreate.Body.BorderStyle = BorderStyle.None;
+ formToCreate.TopMost = true;
brdr.setupall();
formToCreate.FormBorderStyle = FormBorderStyle.None;
+ brdr.BringToFront();
+ //REALLY HACKY WAY TO FIX BORDERS. it works.
+ Form formToRoll = formToCreate;
+ formToRoll.Tag = formToRoll.Width.ToString() + "," + formToRoll.Height.ToString() + "," + formToRoll.MinimumSize.Width.ToString() + "," + formToRoll.MinimumSize.Height.ToString() + " " + formToRoll.Location.X.ToString() + "," + formToRoll.Location.Y.ToString();
+ formToRoll.MinimumSize = new Size(0, 0);
+ formToRoll.Height = API.CurrentSkin.titlebarheight;
+ string xyraw = (string)formToRoll.Tag;
+ string[] data = xyraw.Split(' ');
+ string[] xy = data[0].Split(',');
+ int x = Convert.ToInt16(xy[0]);
+ int y = Convert.ToInt16(xy[1]);
+ int mx = Convert.ToInt16(xy[2]);
+ int my = Convert.ToInt16(xy[3]);
+ formToRoll.Size = new Size(x, y);
+ formToRoll.MinimumSize = new Size(mx, my);
}
/// <summary>