mirror of
https://github.com/babalae/better-genshin-impact.git
synced 2026-04-06 11:55:31 +08:00
restore start genshin code
This commit is contained in:
@@ -103,7 +103,7 @@
|
||||
</Grid>
|
||||
</ui:CardExpander.Header>
|
||||
<StackPanel>
|
||||
<!--<Grid Margin="16">
|
||||
<Grid Margin="16">
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="Auto" />
|
||||
<RowDefinition Height="Auto" />
|
||||
@@ -131,7 +131,7 @@
|
||||
Margin="0,0,36,0"
|
||||
Command="{Binding SelectInstallPathCommand}"
|
||||
Content="浏览" />
|
||||
</Grid>-->
|
||||
</Grid>
|
||||
<Separator Margin="-18,0" BorderThickness="0,1,0,0" />
|
||||
<Grid Margin="16">
|
||||
<Grid.RowDefinitions>
|
||||
|
||||
@@ -147,10 +147,10 @@ public partial class HomePageViewModel : ObservableObject, INavigationAware
|
||||
var hWnd = SystemControl.FindGenshinImpactHandle();
|
||||
if (hWnd == IntPtr.Zero)
|
||||
{
|
||||
//if (!string.IsNullOrEmpty(Config.InstallPath))
|
||||
//{
|
||||
// hWnd = await SystemControl.StartFromLocalAsync(Config.InstallPath);
|
||||
//}
|
||||
if (!string.IsNullOrEmpty(Config.InstallPath))
|
||||
{
|
||||
hWnd = await SystemControl.StartFromLocalAsync(Config.InstallPath);
|
||||
}
|
||||
if (hWnd == IntPtr.Zero)
|
||||
{
|
||||
System.Windows.MessageBox.Show("未找到原神窗口,请先启动原神!");
|
||||
|
||||
Reference in New Issue
Block a user