super("android.ui", android.os.Process.THREAD_PRIORITY_FOREGROUND, false /*allowIo*/);
if (sInstance == null) { sInstance = new UiThread(); sInstance.start(); sHandler = new Handler(sInstance.getLooper()); }
synchronized (UiThread.class) { ensureThreadLocked(); return sInstance; }
synchronized (UiThread.class) { ensureThreadLocked(); return sHandler; }