Skip to content

Commit

Permalink
upd MAUI sample
Browse files Browse the repository at this point in the history
  • Loading branch information
xDaijobu committed Mar 21, 2024
1 parent be12bc9 commit 15e86c9
Show file tree
Hide file tree
Showing 5 changed files with 23 additions and 7 deletions.
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>net7.0-android;net7.0-ios</TargetFrameworks>
<TargetFrameworks>net8.0-android;net8.0-ios</TargetFrameworks>
<OutputType>Exe</OutputType>
<RootNamespace>LocalNotificationsSample2</RootNamespace>
<UseMaui>true</UseMaui>
Expand All @@ -25,10 +25,11 @@

<ItemGroup>
<!-- App Icon -->
<MauiIcon Include="Resources\AppIcon\appicon.svg" ForegroundFile="Resources\AppIcon\appiconfg.svg" Color="#512BD4" />
<AndroidResource Include="Resources\AppIcon\appicon.svg" ForegroundFile="Resources\AppIcon\appiconfg.svg" Color="#512BD4" />
<AndroidResource Include="Resources\Images\dotnet_bot.svg" />

<!-- Splash Screen -->
<MauiSplashScreen Include="Resources\Splash\splash.svg" Color="#512BD4" BaseSize="128,128" />
<AndroidResource Include="Resources\Splash\splash.svg" Color="#512BD4" BaseSize="128,128" />

<!-- Images -->
<MauiImage Include="Resources\Images\*" />
Expand All @@ -38,8 +39,24 @@
<MauiAsset Include="Resources\Raw\**" LogicalName="%(RecursiveDir)%(Filename)%(Extension)" />
</ItemGroup>

<ItemGroup>
<MauiFont Remove="Resources\Fonts\OpenSansRegular.ttf" />
<MauiFont Remove="Resources\Fonts\OpenSansSemibold.ttf" />
</ItemGroup>

<ItemGroup>
<MauiImage Remove="Resources\Images\dotnet_bot.svg" />
</ItemGroup>


<ItemGroup>
<AndroidResource Include="Resources\Fonts\OpenSansRegular.ttf" />
<AndroidResource Include="Resources\Fonts\OpenSansSemibold.ttf" />
</ItemGroup>

<ItemGroup>
<PackageReference Include="Microsoft.Extensions.Logging.Debug" Version="7.0.0-rc.1.22426.10" />
<PackageReference Include="Microsoft.Maui.Controls" Version="8.0.3" />
</ItemGroup>

<ItemGroup>
Expand Down
4 changes: 2 additions & 2 deletions Sample/Maui/LocalNotificationsSample2/MauiProgram.cs
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ public static MauiApp CreateMauiApp()
.UseMauiApp<App>()
.ConfigureFonts(fonts =>
{
fonts.AddFont("OpenSans-Regular.ttf", "OpenSansRegular");
fonts.AddFont("OpenSans-Semibold.ttf", "OpenSansSemibold");
fonts.AddFont("OpenSansRegular.ttf", "OpenSansRegular");
fonts.AddFont("OpenSansSemibold.ttf", "OpenSansSemibold");
})
.UseLocalNotifications(isFirebase: false, autoRegistration: false);

Expand Down
3 changes: 1 addition & 2 deletions Source/LocalNotifications/LocalNotifications.csproj
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<Project Sdk="MSBuild.Sdk.Extras/3.0.44">
<PropertyGroup>
<TargetFrameworks>netstandard2.0;MonoAndroid13.0;Xamarin.iOS10;net8.0;net8.0-android;net8.0-ios;</TargetFrameworks> <!---->
<TargetFrameworks>netstandard2.0;MonoAndroid13.0;Xamarin.iOS10;net8.0;net8.0-android;net8.0-ios;</TargetFrameworks>
<SingleProject>true</SingleProject>
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
<Product>$(AssemblyName) ($(TargetFramework))</Product>
Expand Down Expand Up @@ -65,7 +65,6 @@
<PackageReference Include="Xamarin.GooglePlayServices.Tasks" Version="117.2.1.3" />
<PackageReference Include="Xamarin.Build.Download" Version="0.11.3" PrivateAssets="All" />
<PackageReference Include="Xamarin.Essentials" Version="1.7.4" />

</ItemGroup>

<ItemGroup Condition="$(TargetFramework.StartsWith('Xamarin.iOS'))">
Expand Down

0 comments on commit 15e86c9

Please sign in to comment.