Skip to content

Commit d0c92e6

Browse files
Merge pull request #4 from SowntharyaJ/main
Changed Sample Target Version to Latest .NET9 Target Version.
2 parents c57857b + 8835c62 commit d0c92e6

29 files changed

+780
-275
lines changed

ListViewDemo.sln

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,27 +1,25 @@
11

22
Microsoft Visual Studio Solution File, Format Version 12.00
33
# Visual Studio Version 17
4-
VisualStudioVersion = 17.0.31611.283
4+
VisualStudioVersion = 17.13.35919.96 d17.13
55
MinimumVisualStudioVersion = 10.0.40219.1
6-
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ListViewDemo", "ListViewDemo\ListViewDemo.csproj", "{E214FF70-3140-44E6-A1E6-B0B19430AF88}"
6+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ListViewDemo", "ListViewDemo\ListViewDemo.csproj", "{D0E585AE-5D09-4524-BBBC-3084B7762363}"
77
EndProject
88
Global
99
GlobalSection(SolutionConfigurationPlatforms) = preSolution
1010
Debug|Any CPU = Debug|Any CPU
1111
Release|Any CPU = Release|Any CPU
1212
EndGlobalSection
1313
GlobalSection(ProjectConfigurationPlatforms) = postSolution
14-
{E214FF70-3140-44E6-A1E6-B0B19430AF88}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
15-
{E214FF70-3140-44E6-A1E6-B0B19430AF88}.Debug|Any CPU.Build.0 = Debug|Any CPU
16-
{E214FF70-3140-44E6-A1E6-B0B19430AF88}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
17-
{E214FF70-3140-44E6-A1E6-B0B19430AF88}.Release|Any CPU.ActiveCfg = Release|Any CPU
18-
{E214FF70-3140-44E6-A1E6-B0B19430AF88}.Release|Any CPU.Build.0 = Release|Any CPU
19-
{E214FF70-3140-44E6-A1E6-B0B19430AF88}.Release|Any CPU.Deploy.0 = Release|Any CPU
14+
{D0E585AE-5D09-4524-BBBC-3084B7762363}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
15+
{D0E585AE-5D09-4524-BBBC-3084B7762363}.Debug|Any CPU.Build.0 = Debug|Any CPU
16+
{D0E585AE-5D09-4524-BBBC-3084B7762363}.Release|Any CPU.ActiveCfg = Release|Any CPU
17+
{D0E585AE-5D09-4524-BBBC-3084B7762363}.Release|Any CPU.Build.0 = Release|Any CPU
2018
EndGlobalSection
2119
GlobalSection(SolutionProperties) = preSolution
2220
HideSolutionNode = FALSE
2321
EndGlobalSection
2422
GlobalSection(ExtensibilityGlobals) = postSolution
25-
SolutionGuid = {61F7FB11-1E47-470C-91E2-47F8143E1572}
23+
SolutionGuid = {8697E2A7-3423-4107-BBF1-FF7424A26F58}
2624
EndGlobalSection
2725
EndGlobal

ListViewDemo/App.xaml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
<Application xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
1+
<?xml version = "1.0" encoding = "UTF-8" ?>
2+
<Application xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
23
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
34
xmlns:local="clr-namespace:ListViewDemo"
45
x:Class="ListViewDemo.App">

ListViewDemo/App.xaml.cs

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,15 @@
1-
namespace ListViewDemo;
2-
1+
namespace ListViewDemo
2+
{
33
public partial class App : Application
44
{
55
public App()
66
{
77
InitializeComponent();
8+
}
89

9-
MainPage = new MainPage();
10+
protected override Window CreateWindow(IActivationState? activationState)
11+
{
12+
return new Window(new MainPage());
1013
}
1114
}
15+
}

ListViewDemo/ListViewDemo.csproj

Lines changed: 34 additions & 52 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,24 @@
1-
<Project Sdk="Microsoft.NET.Sdk">
1+
<Project Sdk="Microsoft.NET.Sdk">
22

33
<PropertyGroup>
4-
<TargetFrameworks>net6.0-android;net6.0-ios;net6.0-maccatalyst</TargetFrameworks>
5-
<TargetFrameworks Condition="$([MSBuild]::IsOSPlatform('windows')) and '$(MSBuildRuntimeType)' == 'Full'">$(TargetFrameworks);net6.0-windows10.0.19041</TargetFrameworks>
4+
<TargetFrameworks>net9.0-android;net9.0-ios;net9.0-maccatalyst</TargetFrameworks>
5+
<TargetFrameworks Condition="$([MSBuild]::IsOSPlatform('windows'))">$(TargetFrameworks);net9.0-windows10.0.19041.0</TargetFrameworks>
6+
<!-- Uncomment to also build the tizen app. You will need to install tizen by following this: https://github.com/Samsung/Tizen.NET -->
7+
<!-- <TargetFrameworks>$(TargetFrameworks);net9.0-tizen</TargetFrameworks> -->
8+
9+
<!-- Note for MacCatalyst:
10+
The default runtime is maccatalyst-x64, except in Release config, in which case the default is maccatalyst-x64;maccatalyst-arm64.
11+
When specifying both architectures, use the plural <RuntimeIdentifiers> instead of the singular <RuntimeIdentifier>.
12+
The Mac App Store will NOT accept apps with ONLY maccatalyst-arm64 indicated;
13+
either BOTH runtimes must be indicated or ONLY macatalyst-x64. -->
14+
<!-- For example: <RuntimeIdentifiers>maccatalyst-x64;maccatalyst-arm64</RuntimeIdentifiers> -->
15+
616
<OutputType>Exe</OutputType>
717
<RootNamespace>ListViewDemo</RootNamespace>
818
<UseMaui>true</UseMaui>
919
<SingleProject>true</SingleProject>
1020
<ImplicitUsings>enable</ImplicitUsings>
11-
<EnablePreviewMsixTooling>true</EnablePreviewMsixTooling>
21+
<Nullable>enable</Nullable>
1222

1323
<!-- Display name -->
1424
<ApplicationTitle>ListViewDemo</ApplicationTitle>
@@ -17,27 +27,30 @@
1727
<ApplicationId>com.companyname.listviewdemo</ApplicationId>
1828

1929
<!-- Versions -->
30+
<ApplicationDisplayVersion>1.0</ApplicationDisplayVersion>
2031
<ApplicationVersion>1</ApplicationVersion>
2132

22-
<!-- Required for C# Hot Reload -->
23-
<UseInterpreter Condition="'$(Configuration)' == 'Debug'">True</UseInterpreter>
33+
<!-- To develop, package, and publish an app to the Microsoft Store, see: https://aka.ms/MauiTemplateUnpackaged -->
34+
<WindowsPackageType>None</WindowsPackageType>
2435

25-
<SupportedOSPlatformVersion Condition="'$(TargetFramework)' == 'net6.0-ios'">14.2</SupportedOSPlatformVersion>
26-
<SupportedOSPlatformVersion Condition="'$(TargetFramework)' == 'net6.0-maccatalyst'">14.0</SupportedOSPlatformVersion>
27-
<SupportedOSPlatformVersion Condition="'$(TargetFramework)' == 'net6.0-android'">21.0</SupportedOSPlatformVersion>
28-
<SupportedOSPlatformVersion Condition="$(TargetFramework.Contains('-windows'))">10.0.17763.0</SupportedOSPlatformVersion>
29-
<TargetPlatformMinVersion Condition="$(TargetFramework.Contains('-windows'))">10.0.17763.0</TargetPlatformMinVersion>
36+
<SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'ios'">15.0</SupportedOSPlatformVersion>
37+
<SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'maccatalyst'">15.0</SupportedOSPlatformVersion>
38+
<SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'android'">21.0</SupportedOSPlatformVersion>
39+
<SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'windows'">10.0.17763.0</SupportedOSPlatformVersion>
40+
<TargetPlatformMinVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'windows'">10.0.17763.0</TargetPlatformMinVersion>
41+
<SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'tizen'">6.5</SupportedOSPlatformVersion>
3042
</PropertyGroup>
3143

3244
<ItemGroup>
3345
<!-- App Icon -->
34-
<MauiIcon Include="Resources\appicon.svg" ForegroundFile="Resources\appiconfg.svg" Color="#512BD4" />
46+
<MauiIcon Include="Resources\AppIcon\appicon.svg" ForegroundFile="Resources\AppIcon\appiconfg.svg" Color="#512BD4" />
3547

3648
<!-- Splash Screen -->
37-
<MauiSplashScreen Include="Resources\appiconfg.svg" Color="#512BD4" />
49+
<MauiSplashScreen Include="Resources\Splash\splash.svg" Color="#512BD4" BaseSize="128,128" />
3850

3951
<!-- Images -->
4052
<MauiImage Include="Resources\Images\*" />
53+
<MauiImage Update="Resources\Images\dotnet_bot.png" Resize="True" BaseSize="300,185" />
4154

4255
<!-- Custom Fonts -->
4356
<MauiFont Include="Resources\Fonts\*" />
@@ -48,51 +61,20 @@
4861

4962
<ItemGroup Condition="$(TargetFramework.Contains('-windows'))">
5063
<!-- Required - WinUI does not yet have buildTransitive for everything -->
51-
<PackageReference Include="Microsoft.WindowsAppSDK" Version="1.0.0" />
52-
<PackageReference Include="Microsoft.Graphics.Win2D" Version="1.0.0.30" />
64+
<PackageReference Include="Microsoft.WindowsAppSDK" Version="*" />
65+
<PackageReference Include="Microsoft.Graphics.Win2D" Version="*" />
5366
</ItemGroup>
5467

5568
<ItemGroup>
56-
<None Remove="Resources\Fonts\Roboto-Medium.ttf" />
57-
<None Remove="Resources\Fonts\Roboto-Regular.ttf" />
58-
<None Remove="Resources\Images\image0.png" />
59-
<None Remove="Resources\Images\image1.png" />
60-
<None Remove="Resources\Images\image10.png" />
61-
<None Remove="Resources\Images\image11.png" />
62-
<None Remove="Resources\Images\image12.png" />
63-
<None Remove="Resources\Images\image13.png" />
64-
<None Remove="Resources\Images\image14.png" />
65-
<None Remove="Resources\Images\image15.png" />
66-
<None Remove="Resources\Images\image16.png" />
67-
<None Remove="Resources\Images\image17.png" />
68-
<None Remove="Resources\Images\image18.png" />
69-
<None Remove="Resources\Images\image19.png" />
70-
<None Remove="Resources\Images\image2.png" />
71-
<None Remove="Resources\Images\image20.png" />
72-
<None Remove="Resources\Images\image21.png" />
73-
<None Remove="Resources\Images\image22.png" />
74-
<None Remove="Resources\Images\image23.png" />
75-
<None Remove="Resources\Images\image24.png" />
76-
<None Remove="Resources\Images\image25.png" />
77-
<None Remove="Resources\Images\image26.png" />
78-
<None Remove="Resources\Images\image27.png" />
79-
<None Remove="Resources\Images\image28.png" />
80-
<None Remove="Resources\Images\image3.png" />
81-
<None Remove="Resources\Images\image4.png" />
82-
<None Remove="Resources\Images\image5.png" />
83-
<None Remove="Resources\Images\image6.png" />
84-
<None Remove="Resources\Images\image7.png" />
85-
<None Remove="Resources\Images\image8.png" />
86-
<None Remove="Resources\Images\image9.png" />
69+
<PackageReference Include="Microsoft.Maui.Controls" Version="$(MauiVersion)" />
70+
<PackageReference Include="Microsoft.Extensions.Logging.Debug" Version="*" />
71+
<PackageReference Include="Syncfusion.Maui.ListView" Version="*" />
8772
</ItemGroup>
8873

8974
<ItemGroup>
90-
<PackageReference Include="Syncfusion.Maui.ListView" Version="19.4.55-preview" />
75+
<MauiXaml Update="View\MainPage.xaml">
76+
<Generator>MSBuild:Compile</Generator>
77+
</MauiXaml>
9178
</ItemGroup>
9279

93-
<PropertyGroup Condition="$(TargetFramework.Contains('-windows'))">
94-
<OutputType>WinExe</OutputType>
95-
<RuntimeIdentifier>win10-x64</RuntimeIdentifier>
96-
</PropertyGroup>
97-
9880
</Project>

ListViewDemo/MauiProgram.cs

Lines changed: 23 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,27 @@
1-
namespace ListViewDemo;
1+
using Microsoft.Extensions.Logging;
2+
using Syncfusion.Maui.Core.Hosting;
23

3-
public static class MauiProgram
4+
namespace ListViewDemo
45
{
5-
public static MauiApp CreateMauiApp()
6-
{
7-
var builder = MauiApp.CreateBuilder();
8-
builder
9-
.UseMauiApp<App>()
10-
.ConfigureFonts(fonts =>
11-
{
12-
fonts.AddFont("OpenSans-Regular.ttf", "OpenSansRegular");
13-
fonts.AddFont("Roboto-Medium.ttf", "Roboto-Medium");
14-
fonts.AddFont("Roboto-Regular.ttf", "Roboto-Regular");
15-
});
6+
public static class MauiProgram
7+
{
8+
public static MauiApp CreateMauiApp()
9+
{
10+
var builder = MauiApp.CreateBuilder();
11+
builder
12+
.UseMauiApp<App>()
13+
.ConfigureFonts(fonts =>
14+
{
15+
fonts.AddFont("OpenSans-Regular.ttf", "OpenSansRegular");
16+
fonts.AddFont("Roboto-Medium.ttf", "Roboto-Medium");
17+
fonts.AddFont("Roboto-Regular.ttf", "Roboto-Regular");
18+
});
1619

17-
return builder.Build();
18-
}
20+
#if DEBUG
21+
builder.Logging.AddDebug();
22+
#endif
23+
builder.ConfigureSyncfusionCore();
24+
return builder.Build();
25+
}
26+
}
1927
}
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<manifest xmlns:android="http://schemas.android.com/apk/res/android">
3-
<uses-sdk android:minSdkVersion="21" android:targetSdkVersion="31" />
43
<application android:allowBackup="true" android:icon="@mipmap/appicon" android:roundIcon="@mipmap/appicon_round" android:supportsRtl="true"></application>
54
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
5+
<uses-permission android:name="android.permission.INTERNET" />
66
</manifest>

ListViewDemo/Platforms/Android/MainActivity.cs

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,10 @@
22
using Android.Content.PM;
33
using Android.OS;
44

5-
namespace ListViewDemo;
6-
7-
[Activity(Theme = "@style/Maui.SplashTheme", MainLauncher = true, ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation | ConfigChanges.UiMode | ConfigChanges.ScreenLayout | ConfigChanges.SmallestScreenSize)]
8-
public class MainActivity : MauiAppCompatActivity
5+
namespace ListViewDemo
96
{
7+
[Activity(Theme = "@style/Maui.SplashTheme", MainLauncher = true, LaunchMode = LaunchMode.SingleTop, ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation | ConfigChanges.UiMode | ConfigChanges.ScreenLayout | ConfigChanges.SmallestScreenSize | ConfigChanges.Density)]
8+
public class MainActivity : MauiAppCompatActivity
9+
{
10+
}
1011
}
Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,16 @@
11
using Android.App;
22
using Android.Runtime;
33

4-
namespace ListViewDemo;
5-
6-
[Application]
7-
public class MainApplication : MauiApplication
4+
namespace ListViewDemo
85
{
9-
public MainApplication(IntPtr handle, JniHandleOwnership ownership)
10-
: base(handle, ownership)
11-
{
12-
}
6+
[Application]
7+
public class MainApplication : MauiApplication
8+
{
9+
public MainApplication(IntPtr handle, JniHandleOwnership ownership)
10+
: base(handle, ownership)
11+
{
12+
}
1313

14-
protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
14+
protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
15+
}
1516
}
Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
11
using Foundation;
22

3-
namespace ListViewDemo;
4-
5-
[Register("AppDelegate")]
6-
public class AppDelegate : MauiUIApplicationDelegate
3+
namespace ListViewDemo
74
{
8-
protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
5+
[Register("AppDelegate")]
6+
public class AppDelegate : MauiUIApplicationDelegate
7+
{
8+
protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
9+
}
910
}
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
3+
<plist version="1.0">
4+
<!-- See https://aka.ms/maui-publish-app-store#add-entitlements for more information about adding entitlements.-->
5+
<dict>
6+
<!-- App Sandbox must be enabled to distribute a MacCatalyst app through the Mac App Store. -->
7+
<key>com.apple.security.app-sandbox</key>
8+
<true/>
9+
<!-- When App Sandbox is enabled, this value is required to open outgoing network connections. -->
10+
<key>com.apple.security.network.client</key>
11+
<true/>
12+
</dict>
13+
</plist>
14+

0 commit comments

Comments
 (0)