mirror of
https://github.com/sourcegit-scm/sourcegit
synced 2025-06-01 09:24:58 +00:00
code_style: move platform dependent code to initialize window to namespace SourceGit.Native
Signed-off-by: leo <longshuang@msn.cn>
This commit is contained in:
parent
c62b4a031f
commit
ef4b639f8e
9 changed files with 41 additions and 68 deletions
|
@ -29,14 +29,9 @@ namespace SourceGit.Views
|
|||
set => SetValue(HasLeftCaptionButtonProperty, value);
|
||||
}
|
||||
|
||||
public bool IsRightCaptionButtonsVisible
|
||||
public bool HasRightCaptionButton
|
||||
{
|
||||
get
|
||||
{
|
||||
if (OperatingSystem.IsLinux())
|
||||
return !ViewModels.Preferences.Instance.UseSystemWindowFrame;
|
||||
return OperatingSystem.IsWindows();
|
||||
}
|
||||
get => OperatingSystem.IsWindows() || !Native.OS.UseSystemWindowFrame;
|
||||
}
|
||||
|
||||
public Launcher()
|
||||
|
@ -52,8 +47,7 @@ namespace SourceGit.Views
|
|||
{
|
||||
HasLeftCaptionButton = true;
|
||||
CaptionHeight = new GridLength(34);
|
||||
ExtendClientAreaChromeHints = ExtendClientAreaChromeHints.SystemChrome |
|
||||
ExtendClientAreaChromeHints.OSXThickTitleBar;
|
||||
ExtendClientAreaChromeHints = ExtendClientAreaChromeHints.SystemChrome | ExtendClientAreaChromeHints.OSXThickTitleBar;
|
||||
}
|
||||
else if (UseSystemWindowFrame)
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue