Skip to content

Commit

Permalink
fix: [WPF][Tizen] he local function 'EnqueueNative' is declared but n…
Browse files Browse the repository at this point in the history
…ever used
  • Loading branch information
workgroupengineering committed Jan 12, 2022
1 parent acfac1b commit 28e6342
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 27 deletions.
7 changes: 0 additions & 7 deletions src/Uno.UI.Runtime.Skia.Tizen/TizenHost.cs
Original file line number Diff line number Diff line change
Expand Up @@ -70,13 +70,6 @@ public TizenHost(Func<WinUI.Application> appBuilder, string[] args = null)
.Skip(1)
.ToArray();

bool EnqueueNative(DispatcherQueuePriority priority, DispatcherQueueHandler callback)
{
EcoreMainloop.PostAndWakeUp(() => callback());

return true;
}

Windows.UI.Core.CoreDispatcher.DispatchOverride = (d) => EcoreMainloop.PostAndWakeUp(d);
Windows.UI.Core.CoreDispatcher.HasThreadAccessOverride = () => EcoreMainloop.IsMainThread;

Expand Down
20 changes: 0 additions & 20 deletions src/Uno.UI.Runtime.Skia.Wpf/WpfHost.cs
Original file line number Diff line number Diff line change
Expand Up @@ -104,26 +104,6 @@ void CreateApp(WinUI.ApplicationInitializationCallbackParams _)
app.Host = this;
}

bool EnqueueNative(DispatcherQueuePriority priority, DispatcherQueueHandler callback)
{
if (priority == DispatcherQueuePriority.Normal)
{
dispatcher.BeginInvoke(callback);
}
else
{
var p = priority switch
{
DispatcherQueuePriority.Low => DispatcherPriority.Background,
DispatcherQueuePriority.High => DispatcherPriority.Send, // This one is higher than normal
_ => DispatcherPriority.Normal
};
dispatcher.BeginInvoke(p, callback);
}

return true;
}

Windows.UI.Core.CoreDispatcher.DispatchOverride = d => dispatcher.BeginInvoke(d);
Windows.UI.Core.CoreDispatcher.HasThreadAccessOverride = dispatcher.CheckAccess;

Expand Down

0 comments on commit 28e6342

Please sign in to comment.