MCPcopy Create free account
hub / github.com/cinit/TMoe / runOnUiThread

Method runOnUiThread

app/src/main/java/cc/ioctl/tmoe/util/SyncUtils.java:18–24  ·  view source on GitHub ↗
(@NonNull Runnable r)

Source from the content-addressed store, hash-verified

16 private static Handler sHandler;
17
18 public static void runOnUiThread(@NonNull Runnable r) {
19 if (Looper.myLooper() == Looper.getMainLooper()) {
20 r.run();
21 } else {
22 post(r);
23 }
24 }
25
26 @SuppressLint("LambdaLast")
27 public static void postDelayed(@NonNull Runnable r, long ms) {

Callers 4

showMethod · 0.95
runMethod · 0.80
initOnceMethod · 0.80

Calls 2

postMethod · 0.95
runMethod · 0.65

Tested by

no test coverage detected