Skip to content

Commit e3dbed7

Browse files
myrootrookiejava
authored andcommitted
Fix build error (#60)
1 parent 093b854 commit e3dbed7

File tree

9 files changed

+16
-18
lines changed

9 files changed

+16
-18
lines changed

src/Compatibility/Core/src/Compatibility-net6.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@
5555
<ProjectReference Include="..\..\Android.FormsViewGroup\src\Compatibility.Android.FormsViewGroup-net6.csproj" />
5656
</ItemGroup>
5757

58-
<ItemGroup Condition=" '$(TargetPlatformIdentifier)' == 'net6.0-tizen'" >
58+
<ItemGroup Condition=" '$(TargetPlatformIdentifier)' == 'tizen'" >
5959
<Compile Include="$(TizenRoot)**\*.cs"></Compile>
6060
<EmbeddedResource Include="$(TizenRoot)Resources\*.resx" />
6161
<EmbeddedResource Include="$(TizenRoot)Resources\*.png" />

src/Core/src/Animations/NativeTicker.Tizen.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ public NativeTicker()
1919
}
2020

2121
_context = SynchronizationContext.Current;
22-
_timer = new Timer((object o) => HandleElapsed(o), this, Timeout.Infinite, Timeout.Infinite);
22+
_timer = new Timer((object? o) => HandleElapsed(o), this, Timeout.Infinite, Timeout.Infinite);
2323
}
2424

2525
public override void Start()
@@ -34,7 +34,7 @@ public override void Stop()
3434
_isRunning = false;
3535
}
3636

37-
void HandleElapsed(object state)
37+
void HandleElapsed(object? state)
3838
{
3939
_context?.Post((o) => Fire?.Invoke(), null);
4040
}

src/Core/src/Handlers/Entry/EntryHandler.Tizen.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -187,7 +187,7 @@ void OnCursorChanged(object? sender, EventArgs e)
187187
VirtualView.CursorPosition = position;
188188
}
189189

190-
void OnSelectionCleared(object sender, EventArgs e)
190+
void OnSelectionCleared(object? sender, EventArgs e)
191191
{
192192
if (VirtualView == null || NativeView == null)
193193
return;

src/Core/src/Platform/Tizen/CoreUIAppContext.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -177,7 +177,7 @@ void InitializeMainWindow()
177177
MainWindow.BackButtonPressed += OnBackButtonPressed;
178178
}
179179

180-
void OnBackButtonPressed(object sender, EventArgs e)
180+
void OnBackButtonPressed(object? sender, EventArgs e)
181181
{
182182
if (!(_handleBackButtonPressed?.Invoke() ?? false))
183183
{

src/Core/src/Platform/Tizen/ModalStack.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ void UpdateTopView()
7777
{
7878
_lastTop?.Hide();
7979
_lastTop = InternalStack.LastOrDefault();
80-
_lastTop.Show();
80+
_lastTop?.Show();
8181
(_lastTop as Widget)?.SetFocus(true);
8282
}
8383
}

src/Core/src/Platform/Tizen/TransformationExtensions.cs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -129,8 +129,9 @@ public static void Perspective3D(this EvasMap map, int px, int py, int z0, int f
129129
{
130130
var mapType = typeof(EvasMap);
131131
var propInfo = mapType.GetProperty("Handle", System.Reflection.BindingFlags.NonPublic | System.Reflection.BindingFlags.Instance);
132-
var handle = (IntPtr)propInfo.GetValue(map);
133-
evas_map_util_3d_perspective(handle, px, py, z0, foc);
132+
IntPtr? handle = (IntPtr?)propInfo?.GetValue(map);
133+
if (handle != null)
134+
evas_map_util_3d_perspective(handle.Value, px, py, z0, foc);
134135
}
135136

136137
[DllImport("libevas.so.1")]

src/Core/src/Platform/Tizen/WrapperView.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ partial void ClipChanged()
5252
_clipperView.Value.Invalidate();
5353
}
5454

55-
void OnClipPaint(object sender, SKPaintSurfaceEventArgs e)
55+
void OnClipPaint(object? sender, SKPaintSurfaceEventArgs e)
5656
{
5757
var canvas = e.Surface.Canvas;
5858
canvas.Clear();
@@ -83,7 +83,7 @@ void OnClipPaint(object sender, SKPaintSurfaceEventArgs e)
8383
}
8484
}
8585

86-
void OnLayout(object sender, Tizen.UIExtensions.Common.LayoutEventArgs e)
86+
void OnLayout(object? sender, Tizen.UIExtensions.Common.LayoutEventArgs e)
8787
{
8888
if (Content != null)
8989
{

src/Essentials/src/Essentials-net6.csproj

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,6 @@
5454
<Compile Include="**\*.watchos.*.cs" Exclude="$(DefaultItemExcludes);$(DefaultExcludesInProjectFolder)" />
5555
</ItemGroup> -->
5656
<ItemGroup Condition=" '$(TargetPlatformIdentifier)' == 'tizen' ">
57-
<PackageReference Include="Tizen.NET" Version="4.0.0" PrivateAssets="All" />
5857
<Compile Include="**\*.tizen.cs" Exclude="$(DefaultItemExcludes);$(DefaultExcludesInProjectFolder)" />
5958
<Compile Include="**\*.tizen.*.cs" Exclude="$(DefaultItemExcludes);$(DefaultExcludesInProjectFolder)" />
6059
</ItemGroup>

src/Essentials/src/TextToSpeech/TextToSpeech.tizen.cs

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -20,14 +20,12 @@ internal static async Task PlatformSpeakAsync(string text, SpeechOptions options
2020
await tcsUtterances.Task;
2121

2222
tcsUtterances = new TaskCompletionSource<bool>();
23-
if (cancelToken != null)
23+
24+
cancelToken.Register(() =>
2425
{
25-
cancelToken.Register(() =>
26-
{
27-
tts?.Stop();
28-
tcsUtterances?.TrySetResult(true);
29-
});
30-
}
26+
tts?.Stop();
27+
tcsUtterances?.TrySetResult(true);
28+
});
3129

3230
var language = "en_US";
3331
var voiceType = Voice.Auto;

0 commit comments

Comments
 (0)