Closed Bug 1010174 Opened 11 years ago Closed 11 years ago

[appmgr v2] App is not launched again if manually deleted from the simulator

Categories

(DevTools Graveyard :: WebIDE, defect)

x86
macOS
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED
Firefox 32

People

(Reporter: sole, Assigned: paul)

References

Details

Attachments

(1 file, 2 obsolete files)

Using AppManager, I install an app. Then I delete it from the simulator (by holding down the icon, etc), and press play again in the AppManager. I get the "{app name} installed" message and the icon shows up in the home screen just fine. But the app won't be launched again, no matter how many times I press "play" on the app manager, or command+R, unless I close the simulator and launch it again.
Summary: App is not launched again if manually deleted from the simulator → [appmgr v2] App is not launched again if manually deleted from the simulator
Blocks: build-am2
No longer blocks: enable-webide
Attachment #8424433 - Flags: review?(jryans)
Attachment #8424433 - Flags: review?(jryans) → review?(janx)
Comment on attachment 8424433 [details] [diff] [review] [appmgr v2] update runningApps list on uninstall. r=jryans Review of attachment 8424433 [details] [diff] [review]: ----------------------------------------------------------------- ::: browser/devtools/webide/modules/app-manager.js @@ +116,5 @@ > this._runningApps.delete(manifestURL); > this.checkIfProjectIsRunning(); > }); > + > + client.addListener("appUninstall", (type, { manifestURL }) => { Reading the code, I'm under the impression that "appUninstall" is only triggered by http://dxr.mozilla.org/mozilla-central/source/toolkit/devtools/server/actors/webapps.js#921 upon "webapps-uninstall", which is in turn only triggered by http://dxr.mozilla.org/mozilla-central/source/dom/apps/src/Webapps.jsm#3525 when an app is uninstalled from the App Manager. I'm not sure this will be called when an app is manually uninstalled from the simulator. I'll have to test this.
(In reply to Jan Keromnes [:janx] from comment #2) > Comment on attachment 8424433 [details] [diff] [review] > [appmgr v2] update runningApps list on uninstall. r=jryans > > Review of attachment 8424433 [details] [diff] [review]: > ----------------------------------------------------------------- > > ::: browser/devtools/webide/modules/app-manager.js > @@ +116,5 @@ > > this._runningApps.delete(manifestURL); > > this.checkIfProjectIsRunning(); > > }); > > + > > + client.addListener("appUninstall", (type, { manifestURL }) => { > > Reading the code, I'm under the impression that "appUninstall" is only > triggered by > http://dxr.mozilla.org/mozilla-central/source/toolkit/devtools/server/actors/ > webapps.js#921 upon "webapps-uninstall", which is in turn only triggered by > http://dxr.mozilla.org/mozilla-central/source/dom/apps/src/Webapps.jsm#3525 > when an app is uninstalled from the App Manager. Why from the App Manager? Looks like it's triggered by dom/webapps, so it's global. > I'm not sure this will be > called when an app is manually uninstalled from the simulator. > > I'll have to test this. Works for me.
Attachment #8424433 - Attachment is obsolete: true
Attachment #8424433 - Flags: review?(janx)
Attachment #8424926 - Attachment is obsolete: true
Comment on attachment 8424962 [details] [diff] [review] [appmgr v2] update runningApps list on uninstall. Review of attachment 8424962 [details] [diff] [review]: ----------------------------------------------------------------- Works for me too now.
Attachment #8424962 - Flags: review+
Comment on attachment 8424962 [details] [diff] [review] [appmgr v2] update runningApps list on uninstall. My r+ is not authoritative here. Ryan, could you please rubberstamp this if you feel confident with my review?
Attachment #8424962 - Flags: review?(jryans)
Comment on attachment 8424962 [details] [diff] [review] [appmgr v2] update runningApps list on uninstall. Review of attachment 8424962 [details] [diff] [review]: ----------------------------------------------------------------- Looks good! Interesting that we didn't update the running list on uninstall in AMv1... seems pretty clear that you'd need to!
Attachment #8424962 - Flags: review?(jryans) → review+
However, why does "app-manager.js" maintain its own set of running apps if it also uses WebappsStore? It seems like you should refactor this (in a followup) to stop duplicating the list of running apps like this.
Flags: needinfo?(paul)
(In reply to J. Ryan Stinnett [:jryans] (on PTO May 23 - June 4) from comment #9) > However, why does "app-manager.js" maintain its own set of running apps if > it also uses WebappsStore? > > It seems like you should refactor this (in a followup) to stop duplicating > the list of running apps like this. Yeah, initially I tried to avoid using code from /app-manager/. But I think we'll just keep webapps-store.js. Filed bug 1012831
Flags: needinfo?(paul)
Note to sheriff: no try build as this code is not compiled yet.
Keywords: checkin-needed
Assignee: nobody → paul
Keywords: checkin-needed
Whiteboard: [fixed-in-fx-team]
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Whiteboard: [fixed-in-fx-team]
Target Milestone: --- → Firefox 32
Product: Firefox → DevTools
Product: DevTools → DevTools Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: