mirror of
https://github.com/sourcegit-scm/sourcegit
synced 2025-05-22 12:45:00 +00:00
feature<Window>: remember window state
This commit is contained in:
parent
9f58e0c715
commit
f04c01b878
3 changed files with 12 additions and 3 deletions
|
@ -25,7 +25,11 @@ namespace SourceGit.Views.Controls {
|
|||
|
||||
public Window() {
|
||||
Style = FindResource("Style.Window") as Style;
|
||||
Loaded += (_, __) => adornerLayer = AdornerLayer.GetAdornerLayer(Content as FrameworkElement);
|
||||
|
||||
Loaded += (_, __) => {
|
||||
adornerLayer = AdornerLayer.GetAdornerLayer(Content as FrameworkElement);
|
||||
OnStateChanged(null);
|
||||
};
|
||||
}
|
||||
|
||||
public static void AddAdorner(FrameworkElement windowContext, Adorner adorner) {
|
||||
|
@ -50,8 +54,6 @@ namespace SourceGit.Views.Controls {
|
|||
}
|
||||
|
||||
protected override void OnStateChanged(EventArgs e) {
|
||||
base.OnStateChanged(e);
|
||||
|
||||
if (WindowState == WindowState.Maximized) {
|
||||
if (!IsMaximized) IsMaximized = true;
|
||||
BorderThickness = new Thickness(0);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue