Skip to content

Commit

Permalink
optimize
Browse files Browse the repository at this point in the history
  • Loading branch information
PHAN Xuan Quang committed Oct 14, 2024
1 parent 64d22dc commit 133e296
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 14 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,17 @@
<SelfContained>true</SelfContained>
<WindowsAppSDKSelfContained>true</WindowsAppSDKSelfContained>
<PackageId>AdobeCameraProfilesUnlocker_Neo</PackageId>
<PublishTrimmed>true</PublishTrimmed>
<PublishReadyToRun>true</PublishReadyToRun>
<PackageTags>Neo 2.0.0</PackageTags>
</PropertyGroup>

<Target Name="RemoveFoldersWithMuiFiles" AfterTargets="Build">
<ItemGroup>
<RemovingFiles Include="$(OutDir)*\*.mui" Exclude="$(OutDir)en-us\*.mui" />
<RemovingFolders Include="@(RemovingFiles->'%(RootDir)%(Directory)')" />
</ItemGroup>
<RemoveDir Directories="@(RemovingFolders)" />
</Target>
<ItemGroup>
<Content Include="Resources\icons8_camera_9.ico" />
</ItemGroup>
Expand Down Expand Up @@ -78,4 +86,10 @@
<PropertyGroup Condition="'$(DisableHasPackageAndPublishMenuAddedByProject)'!='true' and '$(EnableMsixTooling)'=='true'">
<HasPackageAndPublishMenu>true</HasPackageAndPublishMenu>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x86'">
<Optimize>false</Optimize>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<Optimize>false</Optimize>
</PropertyGroup>
</Project>
26 changes: 13 additions & 13 deletions Adobe Camera Profiles Unlocker Neo/MainWindow.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -63,19 +63,19 @@ private async void MainWindow_Activated(object sender, WindowActivatedEventArgs
Application.Current.Exit();
}

//if (!GeneralHelper.IsUserAdmin())
//{
// ContentDialog adminDialog = new ContentDialog
// {
// XamlRoot = RootGrid.XamlRoot,
// Title = "Error",
// Content = "The application must be ran with the administrator right.",
// PrimaryButtonText = "OK",
// DefaultButton = ContentDialogButton.Primary
// };
// await adminDialog.ShowAsync();
// Application.Current.Exit();
//}
if (!GeneralHelper.IsUserAdmin())
{
ContentDialog adminDialog = new ContentDialog
{
XamlRoot = RootGrid.XamlRoot,
Title = "Error",
Content = "The application must be ran with the administrator right.",
PrimaryButtonText = "OK",
DefaultButton = ContentDialogButton.Primary
};
await adminDialog.ShowAsync();
Application.Current.Exit();
}

if (!Directory.Exists(CameraRaw.BaseDir))
{
Expand Down

0 comments on commit 133e296

Please sign in to comment.