Tag

ActivityLifecycle

1 views collected around this technical thread.

Top Architect
Top Architect
Feb 25, 2021 · Mobile Development

Why Android Activity onStop/onDestroy Is Delayed by 10 Seconds When an Infinite Animation Is Running

The article explains that an infinite View animation continuously posts invalidate messages to the MessageQueue, preventing the idle handler from running and causing the Activity's onStop and onDestroy callbacks, scheduled with a 10‑second idle timeout, to be delayed until the queue becomes idle.

ActivityLifecycleIdleHandlerMessageQueue
0 likes · 28 min read
Why Android Activity onStop/onDestroy Is Delayed by 10 Seconds When an Infinite Animation Is Running
Beike Product & Technology
Beike Product & Technology
Oct 26, 2018 · Mobile Development

Adding a Persistent Floating Button to Every Android Screen via DecorView Instead of WindowManager

The article explains why using WindowManager for floating buttons on Android is problematic across versions, demonstrates how the JD.com app adds a floating view directly to the Activity's DecorView, and provides a complete lifecycle‑aware implementation for Beike's app using ActivityLifecycleCallbacks and view injection.

ActivityLifecycleDecorViewFloatingButton
0 likes · 6 min read
Adding a Persistent Floating Button to Every Android Screen via DecorView Instead of WindowManager