作者magic704226 (magic)
看板AndroidDev
標題[問題] Android 安裝完後,觸發本身的Event
時間Thu Dec 11 15:58:42 2014
目前做一個Ap
要在被Install完畢後
收到一個Broadcast
如果單安裝完AP
尤其他AP收一般是用
android.intent.action.PACKAGE_ADDED
android.intent.action.PACKAGE_INSTALL
但要讓自己起來
目前Survey到是
android.intent.action.USER_PRESENT
但這要在螢幕解鎖
有沒有其他更好的方法?
p.s.
AP是一個System Service 只有init一個BroadcastReceiver
補充 目前找到 FLAG_INCLUDE_STOPPED_PACKAGES flag
可是要怎麼加在System Intent
--
※ 發信站: 批踢踢實業坊(ptt.cc), 來自: 39.9.31.252
※ 文章網址: http://webptt.com/m.aspx?n=bbs/AndroidDev/M.1418284725.A.89B.html
※ 編輯: magic704226 (39.9.31.252), 12/11/2014 16:12:07
1F:→ freesamael: 沒辦法,要有ui的trigger point 12/11 23:02
2F:→ freesamael: android刻意讓剛裝好的app是stopped收不到一般的broad 12/11 23:03
3F:→ freesamael: cast 12/11 23:03