Skip to content

Commit bfc987f

Browse files
committed
Merge remote-tracking branch 'origin/master'
2 parents 422ff40 + 9cefa5d commit bfc987f

11 files changed

Lines changed: 220 additions & 105 deletions

Amethyst/App.axaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -142,10 +142,10 @@
142142
</Application.Resources>
143143

144144
<Application.Styles>
145-
<sty:FluentAvaloniaTheme PreferSystemTheme="True" PreferUserAccentColor="True" />
145+
<sty:FluentAvaloniaTheme PreferSystemTheme="True" PreferUserAccentColor="{OnPlatform Windows='True', Default='False'}" />
146146

147147
<Style Selector=":is(TopLevel)">
148-
<Setter Property="FontFamily" Value="Segoe UI" />
148+
<Setter Property="FontFamily" Value="avares://Amethyst/Assets/Fonts#Inter" />
149149
</Style>
150150

151151
<Style Selector="controls|FontIcon">

Amethyst/App.axaml.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -81,9 +81,9 @@ public override void OnFrameworkInitializationCompleted()
8181
base.OnFrameworkInitializationCompleted();
8282
}
8383

84-
private void SetupCoreApplication()
84+
private async Task SetupCoreApplication()
8585
{
86-
AsyncUtils.RunSync(PathsHandler.Setup);
86+
await PathsHandler.Setup();
8787

8888
// Listen for and log all uncaught second-chance exceptions : Domain
8989
AppDomain.CurrentDomain.UnhandledException += (_, e) =>
@@ -200,7 +200,7 @@ private async Task SetupApplication(IClassicDesktopStyleApplicationLifetime desk
200200
{
201201
if (desktop?.MainWindow == null) throw new ArgumentNullException(nameof(desktop));
202202

203-
SetupCoreApplication();
203+
await SetupCoreApplication();
204204
var args = desktop.Args;
205205

206206
if (args != null)
883 KB
Binary file not shown.
854 KB
Binary file not shown.

Amethyst/Assets/Licenses.txt

Lines changed: 27 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1099,4 +1099,30 @@ Redistribution and use in source and binary forms, with or without modification,
10991099

11001100
* Neither the name Facebook nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.
11011101

1102-
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
1102+
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
1103+
1104+
1105+
AVALONIA
1106+
1107+
The MIT License (MIT)
1108+
1109+
Copyright (c) AvaloniaUI OÜ All Rights Reserved
1110+
1111+
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
1112+
1113+
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
1114+
1115+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
1116+
1117+
1118+
FLUENTAVALONIAUI
1119+
1120+
MIT License
1121+
1122+
Copyright (c) 2025 amwx
1123+
1124+
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
1125+
1126+
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
1127+
1128+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

Amethyst/MainWindow.axaml

Lines changed: 28 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<UserControl xmlns="https://github.com/avaloniaui"
1+
<UserControl xmlns="https://github.com/avaloniaui"
22
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
33
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
44
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
@@ -12,37 +12,48 @@
1212

1313
<Grid x:Name="RootGrid" RowDefinitions="Auto,*">
1414
<Grid Name="TitleBarHost" ZIndex="1"
15-
ColumnDefinitions="Auto,Auto,*,Auto"
16-
Background="Transparent">
15+
ColumnDefinitions="Auto,Auto,*,Auto,Auto"
16+
Background="Transparent"
17+
PointerPressed="TitleBarHost_OnPointerPressed">
1718
<Image Margin="16,4,12,4"
1819
IsHitTestVisible="False"
1920
Source="/Assets/ktvr.ico"
2021
Width="18" Height="18"
2122
DockPanel.Dock="Left"
2223
Name="MainWindowIcon"
23-
RenderOptions.BitmapInterpolationMode="HighQuality">
24-
<Image.IsVisible>
25-
<OnPlatform Default="False">
26-
<On Options="Windows" Content="True" />
27-
</OnPlatform>
28-
</Image.IsVisible>
29-
</Image>
24+
RenderOptions.BitmapInterpolationMode="HighQuality" />
3025

3126
<TextBlock Text="{Binding Title, RelativeSource={RelativeSource FindAncestor, AncestorType=Window}}"
3227
x:Name="AppTitleLabel" FontSize="12"
3328
IsHitTestVisible="False"
3429
VerticalAlignment="Center"
35-
Grid.Column="1">
36-
<TextBlock.IsVisible>
37-
<OnPlatform Default="False">
38-
<On Options="Windows" Content="True" />
39-
</OnPlatform>
40-
</TextBlock.IsVisible>
41-
</TextBlock>
30+
Grid.Column="1" />
4231

4332
<Border Grid.Column="2" Padding="6" Margin="0,-2,0,0">
4433
<AutoCompleteBox ZIndex="1" Name="SearchBox" MaxHeight="40" MaxWidth="500" Watermark="Search" />
4534
</Border>
35+
36+
<StackPanel Grid.Column="4" VerticalAlignment="Center"
37+
Orientation="Horizontal" Spacing="4" Margin="0,0,4,0">
38+
<Button Height="34" Width="34" BorderThickness="0" Background="Transparent"
39+
Click="MinimizeButton_OnClick">
40+
<Button.Content>
41+
<controls:FontIcon Glyph="&#xE921;" FontSize="13" />
42+
</Button.Content>
43+
</Button>
44+
<Button Height="34" Width="34" BorderThickness="0" Background="Transparent"
45+
Click="MaximizeButton_OnClick">
46+
<Button.Content>
47+
<controls:FontIcon Glyph="&#xE922;" FontSize="13" />
48+
</Button.Content>
49+
</Button>
50+
<Button Height="34" Width="34" BorderThickness="0" Background="Transparent"
51+
Click="CloseButton_OnClick">
52+
<Button.Content>
53+
<controls:FontIcon Glyph="&#xE8BB;" FontSize="13" />
54+
</Button.Content>
55+
</Button>
56+
</StackPanel>
4657
</Grid>
4758

4859
<!-- ~1~ ReSharper disable once Xaml.MissingGridIndex @1@ -->
@@ -85,21 +96,6 @@
8596
<!-- </TextBlock> -->
8697
<!-- </Grid> -->
8798

88-
<Grid VerticalAlignment="Stretch" HorizontalAlignment="Stretch" Background="Transparent">
89-
<Grid.ColumnDefinitions>
90-
<ColumnDefinition Width="62" />
91-
<ColumnDefinition Width="*" />
92-
</Grid.ColumnDefinitions>
93-
94-
<Grid.RowDefinitions>
95-
<RowDefinition Height="40" />
96-
<RowDefinition Height="*" />
97-
</Grid.RowDefinitions>
98-
99-
<Grid Background="Transparent" VerticalAlignment="Stretch" HorizontalAlignment="Stretch"
100-
Grid.Column="1" x:Name="DragElement" ZIndex="1" />
101-
</Grid>
102-
10399
<Grid VerticalAlignment="Top" HorizontalAlignment="Left"
104100
Width="70" Height="300" Margin="0,40,0,0"
105101
x:Name="NavigationBlockerGrid" Background="Transparent"

0 commit comments

Comments
 (0)