new Handler(Looper.getMainLooper()){ @Override public void handleMessage(Message msg){ Toast.makeText(getApplicationContext(), "服务已启动", Toast.LENGTH_SHORT).show(); } }.obtainMessage().sendToTarget();
安卓后台呈现 Toast
最新推荐文章于 2024-09-02 18:19:21 发布
new Handler(Looper.getMainLooper()){ @Override public void handleMessage(Message msg){ Toast.makeText(getApplicationContext(), "服务已启动", Toast.LENGTH_SHORT).show(); } }.obtainMessage().sendToTarget();