Skip to content

Commit

Permalink
[Core] Rename local wrapper functions
Browse files Browse the repository at this point in the history
  • Loading branch information
dahlbyk committed Jul 6, 2019
1 parent 1ebefd2 commit f2c5feb
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions Xamarin.Forms.Core/Device.cs
Original file line number Diff line number Diff line change
Expand Up @@ -124,8 +124,8 @@ public static Task<T> InvokeOnMainThreadAsync<T>(Func<T> func)

public static Task InvokeOnMainThreadAsync(Action action)
{
object dummyFunc() { action(); return null; }
return InvokeOnMainThreadAsync(dummyFunc);
object wrapAction() { action(); return null; }
return InvokeOnMainThreadAsync(wrapAction);
}

public static Task<T> InvokeOnMainThreadAsync<T>(Func<Task<T>> funcTask)
Expand All @@ -151,8 +151,8 @@ public static Task<T> InvokeOnMainThreadAsync<T>(Func<Task<T>> funcTask)

public static Task InvokeOnMainThreadAsync(Func<Task> funcTask)
{
async Task<object> dummyFunc() { await funcTask().ConfigureAwait(false); return null; }
return InvokeOnMainThreadAsync(dummyFunc);
async Task<object> wrapFunction() { await funcTask().ConfigureAwait(false); return null; }
return InvokeOnMainThreadAsync(wrapFunction);
}

public static async Task<SynchronizationContext> GetMainThreadSynchronizationContextAsync()
Expand Down

0 comments on commit f2c5feb

Please sign in to comment.