Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Samsung Tizen #12151

Merged
merged 55 commits into from
Sep 22, 2023
Merged
Show file tree
Hide file tree
Changes from 54 commits
Commits
Show all changes
55 commits
Select commit Hold shift + click to select a range
4684653
implement tizen platform, resolve #6110
OmidID Jun 20, 2023
297fe43
Fix enum types of touch event
OmidID Jun 20, 2023
ed8f7f9
Fix issue of touch tracking.
OmidID Jun 20, 2023
785dd54
#6110 fix ui thread lock
OmidID Jun 21, 2023
0906be8
Merge branch 'master' of https://github.com/AvaloniaUI/Avalonia into …
OmidID Jun 21, 2023
c1453f7
#6110 send keypad from tizen window
OmidID Jun 21, 2023
b193082
#6110 fix touch update
OmidID Jun 23, 2023
2ac4faf
Merge branch 'master' of https://github.com/AvaloniaUI/Avalonia into …
OmidID Jun 23, 2023
c13e87b
#6110 add text editor for input fields
OmidID Jun 25, 2023
959d047
#6110 Hide text field
OmidID Jun 25, 2023
1f3c5ae
#6110 Fix issue of text selection and backspace
OmidID Jun 25, 2023
a0c346b
#6110 support multi and single line for input
OmidID Jun 28, 2023
7061ef0
Merge branch 'master' of https://github.com/AvaloniaUI/Avalonia into …
OmidID Jun 28, 2023
0ef6c0b
#6110 temporary set multiline true by default.
OmidID Jul 1, 2023
af45181
Merge branch 'master' of https://github.com/AvaloniaUI/Avalonia into …
OmidID Jul 1, 2023
407fe2f
#6110 fix issue of build with latest version and make it compatible
OmidID Jul 1, 2023
99d4d7f
#6110 by pass double input when softkeyboard showing.
OmidID Jul 2, 2023
4420110
#6110 adding support for clipboard.
OmidID Jul 2, 2023
7f06df3
Merge branch 'master' of https://github.com/AvaloniaUI/Avalonia into …
OmidID Jul 2, 2023
18605e2
#6110 add permission helper to tizen platform
OmidID Jul 2, 2023
c68b53f
#6110 Implementation of storage provider for tizen
OmidID Jul 6, 2023
de6b4c1
Merge branch 'master' of https://github.com/AvaloniaUI/Avalonia into …
OmidID Jul 6, 2023
93f94eb
#6110 send text for key character from hard keyboard
OmidID Jul 10, 2023
bb54a7f
#6110 Complete the input implementation. soft and hard keyboard
OmidID Jul 11, 2023
4acb3d4
Merge branch 'master' of https://github.com/AvaloniaUI/Avalonia into …
OmidID Jul 11, 2023
d3cb937
#6110 remove ElmSharp
OmidID Jul 11, 2023
a8513ca
Update Permissions.cs
rookiejava Jul 12, 2023
3c3cf3e
Merge pull request #1 from rookiejava/patch-2
OmidID Jul 12, 2023
11e0396
#6110 remove open folder for tizen
OmidID Jul 13, 2023
f8d80b0
Merge branch 'master' of https://github.com/AvaloniaUI/Avalonia into …
OmidID Jul 13, 2023
499836d
#6110 fix the issue of keyboard frezee for tizen
OmidID Jul 13, 2023
f9bc400
#6110 add workload to build tizen
OmidID Jul 16, 2023
c4556fd
#6110 try to setup tizen workloads for windows
OmidID Jul 16, 2023
38566ce
#6110 change tizen workload install to powershell
OmidID Jul 16, 2023
7a5ff9d
#6110 skip api diff check when package not exists
OmidID Jul 17, 2023
11e0091
#6110 try to fix linux pipeline
OmidID Jul 17, 2023
3f13cd7
#6110 implement tizen native view
OmidID Jul 20, 2023
39da5ca
#6110 add dev analyzer and trimming
OmidID Jul 20, 2023
6871362
Merge branch 'features/tizen' of github.com:OmidID/Avalonia into feat…
OmidID Jul 20, 2023
5ccc3ee
Merge branch 'master' of https://github.com/AvaloniaUI/Avalonia into …
OmidID Jul 20, 2023
42717ee
#6110 Migrate to GLES and remove framebuffer
OmidID Aug 1, 2023
ef5e113
Merge branch 'master' of https://github.com/AvaloniaUI/Avalonia into …
OmidID Aug 1, 2023
d3dcc51
#6110 Temporary solution to make GL work
OmidID Aug 2, 2023
915d701
#6110 WIP and add comments
OmidID Aug 2, 2023
f9f4548
#6110 optimise gles rendering and timing.
OmidID Aug 4, 2023
0e0cbe4
#6110 fix dependency issue of tizen HarfBuzzSharp
OmidID Aug 4, 2023
9757f56
#6110 patch a fix for clipboard issue
OmidID Aug 4, 2023
a3482e5
#6110 Support tizen sdk for old proj type, WIP
OmidID Aug 6, 2023
b764bf5
#6110 wip setup app
OmidID Aug 9, 2023
c02d44f
#6110 support only net6 for tizen
OmidID Aug 9, 2023
323395b
Merge branch 'master' of https://github.com/AvaloniaUI/Avalonia into …
OmidID Aug 9, 2023
0b9f72b
Merge branch 'master' into features/tizen
OmidID Aug 10, 2023
83f278b
#6110 resolve comments
OmidID Aug 11, 2023
cb2093e
Merge branch 'features/tizen' of github.com:OmidID/Avalonia into feat…
OmidID Aug 11, 2023
84f160a
Merge branch 'master' into features/tizen
maxkatz6 Sep 22, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 17 additions & 0 deletions Avalonia.sln
Original file line number Diff line number Diff line change
Expand Up @@ -274,6 +274,11 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Avalonia.Headless.XUnit.Uni
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "MobileSandbox.Browser", "samples\MobileSandbox.Browser\MobileSandbox.Browser.csproj", "{43FCC14E-EEBE-44B3-BCBC-F1C537EECBF8}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Tizen", "Tizen", "{D1300000-7217-4693-8B0F-57CBD5814302}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Avalonia.Tizen", "src\Tizen\Avalonia.Tizen\Avalonia.Tizen.csproj", "{DFFBDBF5-5DBE-47ED-9EAE-D40B75AC99E8}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ControlCatalog.Tizen", "samples\ControlCatalog.Tizen\ControlCatalog.Tizen.csproj", "{A0B29221-2B6F-4B29-A4D5-2227811B5915}"
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Avalonia.Metal", "src\Avalonia.Metal\Avalonia.Metal.csproj", "{60B4ED1F-ECFA-453B-8A70-1788261C8355}"
EndProject
Global
Expand Down Expand Up @@ -663,6 +668,16 @@ Global
{43FCC14E-EEBE-44B3-BCBC-F1C537EECBF8}.Debug|Any CPU.Build.0 = Debug|Any CPU
{43FCC14E-EEBE-44B3-BCBC-F1C537EECBF8}.Release|Any CPU.ActiveCfg = Release|Any CPU
{43FCC14E-EEBE-44B3-BCBC-F1C537EECBF8}.Release|Any CPU.Build.0 = Release|Any CPU
{DFFBDBF5-5DBE-47ED-9EAE-D40B75AC99E8}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{DFFBDBF5-5DBE-47ED-9EAE-D40B75AC99E8}.Debug|Any CPU.Build.0 = Debug|Any CPU
{DFFBDBF5-5DBE-47ED-9EAE-D40B75AC99E8}.Release|Any CPU.ActiveCfg = Release|Any CPU
{DFFBDBF5-5DBE-47ED-9EAE-D40B75AC99E8}.Release|Any CPU.Build.0 = Release|Any CPU
{A0B29221-2B6F-4B29-A4D5-2227811B5915}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{A0B29221-2B6F-4B29-A4D5-2227811B5915}.Debug|Any CPU.Build.0 = Debug|Any CPU
{A0B29221-2B6F-4B29-A4D5-2227811B5915}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
{A0B29221-2B6F-4B29-A4D5-2227811B5915}.Release|Any CPU.ActiveCfg = Release|Any CPU
{A0B29221-2B6F-4B29-A4D5-2227811B5915}.Release|Any CPU.Build.0 = Release|Any CPU
{A0B29221-2B6F-4B29-A4D5-2227811B5915}.Release|Any CPU.Deploy.0 = Release|Any CPU
{60B4ED1F-ECFA-453B-8A70-1788261C8355}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{60B4ED1F-ECFA-453B-8A70-1788261C8355}.Debug|Any CPU.Build.0 = Debug|Any CPU
{60B4ED1F-ECFA-453B-8A70-1788261C8355}.Release|Any CPU.ActiveCfg = Release|Any CPU
Expand Down Expand Up @@ -749,6 +764,8 @@ Global
{2999D79E-3C20-4A90-B651-CA7E0AC92D35} = {C5A00AC3-B34C-4564-9BDD-2DA473EF4D8B}
{F83FC908-A4E3-40DE-B4CF-A4BA1E92CDB3} = {C5A00AC3-B34C-4564-9BDD-2DA473EF4D8B}
{43FCC14E-EEBE-44B3-BCBC-F1C537EECBF8} = {9B9E3891-2366-4253-A952-D08BCEB71098}
{DFFBDBF5-5DBE-47ED-9EAE-D40B75AC99E8} = {D1300000-7217-4693-8B0F-57CBD5814302}
{A0B29221-2B6F-4B29-A4D5-2227811B5915} = {9B9E3891-2366-4253-A952-D08BCEB71098}
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {87366D66-1391-4D90-8999-95A620AD786A}
Expand Down
23 changes: 22 additions & 1 deletion azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,13 @@ jobs:
script: |
dotnet workload install wasm-tools wasm-experimental

- task: CmdLine@2
displayName: 'Install Tizen Workload'
inputs:
targetType: 'inline'
script: |
curl -sSL https://raw.githubusercontent.com/Samsung/Tizen.NET/main/workload/scripts/workload-install.sh | sudo bash -s -- -d "/opt/hostedtoolcache/dotnet"

- task: CmdLine@2
displayName: 'Run Build'
inputs:
Expand Down Expand Up @@ -81,7 +88,14 @@ jobs:
inputs:
script: |
dotnet workload install wasm-tools wasm-experimental


- task: CmdLine@2
displayName: 'Install Tizen Workload'
inputs:
targetType: 'inline'
script: |
curl -sSL https://raw.githubusercontent.com/Samsung/Tizen.NET/main/workload/scripts/workload-install.sh | sudo bash

- task: CmdLine@2
displayName: 'Generate avalonia-native'
inputs:
Expand Down Expand Up @@ -153,6 +167,13 @@ jobs:
script: |
dotnet workload install android ios wasm-tools wasm-experimental

- task: PowerShell@2
displayName: 'Install Tizen Workload'
inputs:
targetType: 'inline'
script: |
(New-Object System.Net.WebClient).DownloadString('https://raw.githubusercontent.com/Samsung/Tizen.NET/main/workload/scripts/workload-install.ps1') | Invoke-Expression

- task: CmdLine@2
displayName: 'Install Nuke'
inputs:
Expand Down
10 changes: 9 additions & 1 deletion nukebuild/ApiDiffValidation.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
using System.IO;
using System.IO.Compression;
using System.Linq;
using System.Net;
using System.Net.Http;
using System.Text.RegularExpressions;
using System.Threading.Tasks;
Expand All @@ -27,7 +28,10 @@ public static async Task ValidatePackage(
Directory.CreateDirectory(suppressionFilesFolder!);
}

await using (var baselineStream = await DownloadBaselinePackage(packagePath, baselineVersion))
await using var baselineStream = await DownloadBaselinePackage(packagePath, baselineVersion);
if (baselineStream == null)
return;

using (var target = new ZipArchive(File.Open(packagePath, FileMode.Open, FileAccess.Read), ZipArchiveMode.Read))
using (var baseline = new ZipArchive(baselineStream, ZipArchiveMode.Read))
using (Helpers.UseTempDir(out var tempFolder))
Expand Down Expand Up @@ -139,6 +143,10 @@ static async Task<Stream> DownloadBaselinePackage(string packagePath, string bas
memoryStream.Seek(0, SeekOrigin.Begin);
return memoryStream;
}
catch (HttpRequestException e) when (e.StatusCode == HttpStatusCode.NotFound)
{
return null;
}
catch (Exception ex)
{
throw new InvalidOperationException($"Downloading baseline package for {packageId} {baselineVersion} failed.\r" + ex.Message, ex);
Expand Down
20 changes: 20 additions & 0 deletions samples/ControlCatalog.Tizen/ControlCatalog.Tizen.csproj
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net6.0-tizen</TargetFramework>
<OutputType>Exe</OutputType>
</PropertyGroup>

<ItemGroup>
<TizenSharedResource Remove="shared\res\Avalonia.png" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\..\src\Tizen\Avalonia.Tizen\Avalonia.Tizen.csproj" />
<ProjectReference Include="..\ControlCatalog\ControlCatalog.csproj" />
</ItemGroup>


<ItemGroup>
<Folder Include="lib\" />
<Folder Include="res\" />
</ItemGroup>
</Project>
41 changes: 41 additions & 0 deletions samples/ControlCatalog.Tizen/EmbedSampleNuiTizen.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Avalonia.Platform;
using Avalonia.Tizen;
using ControlCatalog.Pages;
using Tizen.NUI.BaseComponents;
using Tizen.NUI.Components;
using Tizen.Pims.Contacts.ContactsViews;

namespace ControlCatalog.Tizen;
public class EmbedSampleNuiTizen : INativeDemoControl
{
public IPlatformHandle CreateControl(bool isSecond, IPlatformHandle parent, Func<IPlatformHandle> createDefault)
{
if (isSecond)
{
var webView = new WebView();
webView.LoadUrl("https://avaloniaui.net/");
return new NuiViewControlHandle(webView);
}
else
{
var clickCount = 0;
var button = new Button
{
Text = "Hello world"
};

button.Clicked += (sender, e) =>
{
clickCount++;
button.Text = $"Click count {clickCount}";
};

return new NuiViewControlHandle(button);
}
}
}
23 changes: 23 additions & 0 deletions samples/ControlCatalog.Tizen/Main.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
using System;
using Avalonia;
using Avalonia.Tizen;
using ElmSharp;
using SkiaSharp;
using Tizen.Applications;

namespace ControlCatalog.Tizen;

class Program : NuiTizenApplication<App>
{
protected override AppBuilder CustomizeAppBuilder(AppBuilder builder) =>
base.CustomizeAppBuilder(builder).AfterSetup(_ =>
{
Pages.EmbedSample.Implementation = new EmbedSampleNuiTizen();
});

static void Main(string[] args)
{
var app = new Program();
app.Run(args);
}
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
23 changes: 23 additions & 0 deletions samples/ControlCatalog.Tizen/tizen-manifest.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest package="com.avalonia.control-catalog" version="1.0.0" api-version="7.0" xmlns="http://tizen.org/ns/packages">
<profile name="common" />
<ui-application appid="com.avalonia.control-catalog" exec="ControlCatalog.Tizen.dll" multiple="false" nodisplay="false" taskmanage="true" type="dotnet" hw-acceleration="on" launch_mode="single">
<label>Avalonia</label>
<icon>Avalonia.png</icon>
<metadata key="http://tizen.org/metadata/prefer_dotnet_aot" value="true" />
<splash-screens />
</ui-application>
<shortcut-list />
<privileges>
<privilege>http://tizen.org/privilege/appdir.shareddata</privilege>
<privilege>http://tizen.org/privilege/appmanager.launch</privilege>
<privilege>http://tizen.org/privilege/externalstorage</privilege>
<privilege>http://tizen.org/privilege/externalstorage.appdata</privilege>
<privilege>http://tizen.org/privilege/internet</privilege>
<privilege>http://tizen.org/privilege/network.get</privilege>
</privileges>
<dependencies />
<provides-appdefined-privileges />
<feature>http://tizen.org/feature/opengles.surfaceless_context</feature>
<feature>http://tizen.org/feature/opengles.version.2_0</feature>
</manifest>
1 change: 1 addition & 0 deletions src/Avalonia.Base/Avalonia.Base.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@
<InternalsVisibleTo Include="Avalonia.Win32, PublicKey=$(AvaloniaPublicKey)" />
<InternalsVisibleTo Include="Avalonia.Android, PublicKey=$(AvaloniaPublicKey)" />
<InternalsVisibleTo Include="Avalonia.iOS, PublicKey=$(AvaloniaPublicKey)" />
<InternalsVisibleTo Include="Avalonia.Tizen, PublicKey=$(AvaloniaPublicKey)" />
<InternalsVisibleTo Include="Avalonia.Dialogs, PublicKey=$(AvaloniaPublicKey)" />
<InternalsVisibleTo Include="Avalonia.Diagnostics, PublicKey=$(AvaloniaPublicKey)" />
<InternalsVisibleTo Include="Avalonia.LinuxFramebuffer, PublicKey=$(AvaloniaPublicKey)" />
Expand Down
20 changes: 20 additions & 0 deletions src/Tizen/Avalonia.Tizen/Avalonia.Tizen.csproj
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>net6.0-tizen</TargetFrameworks>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
<MSBuildEnableWorkloadResolver>true</MSBuildEnableWorkloadResolver>
</PropertyGroup>

<ItemGroup>
<PackageReference Include="SkiaSharp.HarfBuzz" Version="2.88.3" />
<PackageReference Include="HarfBuzzSharp.NativeAssets.Tizen" Version="2.8.2.3" />

<ProjectReference Include="..\..\..\packages\Avalonia\Avalonia.csproj" />
<ProjectReference Include="..\..\Skia\Avalonia.Skia\Avalonia.Skia.csproj" />
</ItemGroup>

<Import Project="..\..\..\build\DevAnalyzers.props" />
<Import Project="..\..\..\build\TrimmingEnable.props" />
</Project>
12 changes: 12 additions & 0 deletions src/Tizen/Avalonia.Tizen/ITizenView.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
using Avalonia.Controls.Platform;
using Avalonia.Input;

namespace Avalonia.Tizen;

internal interface ITizenView
{
Size ClientSize { get; }
double Scaling { get; }
IInputRoot InputRoot { get; set; }
INativeControlHostImpl NativeControlHost { get; }
}
Loading