android - Best way to freeze and application while the database is doing some heavy background work? -
i have background service heavy lifting within transaction once day. if user happens start app @ time, want them sit tight till finishes (around 10 secs or so). what's best way across activities? check if service running in "onresume" function of each activity? , how know when it's done? local broadcasts i'm guessing...
best practices anyone?
update: i've managed stall "onresume" till service done. problem user sees blank screen till then. i've tried progressdialogs , regular dialogs while onresume paused. display when onresume returns , defeats purpose. in other words, progress dialog doesn't "show" after "show()" called :(
local broadcasts good.
have activities question service if busy or not, , display appropriate message user before finishing activity.
once service done, have send intent finished.
Comments
Post a Comment