Closed
Bug 1262391
Opened 9 years ago
Closed 9 years ago
Create a 'launch' method in order to open current chrome:// websites
Categories
(Firefox OS Graveyard :: Gaia::System, defect)
Tracking
(Not tracked)
RESOLVED
FIXED
People
(Reporter: apastor, Assigned: apastor)
References
Details
(Whiteboard: [Transition])
Attachments
(1 file)
Adding a launch method to the returned object in getByManifestURL will allow us to open current 'apps' as chrome
Assignee | ||
Updated•9 years ago
|
Assignee: nobody → apastor
Whiteboard: [transition]
Assignee | ||
Updated•9 years ago
|
Whiteboard: [transition] → [Transition]
Comment 1•9 years ago
|
||
Assignee | ||
Comment 2•9 years ago
|
||
Comment on attachment 8739030 [details] [review]
[gaia] albertopq:1262391-add-launch > mozilla-b2g:kanikani
This should allow to call app.lauch() and open the Settings app when clicking in the UtilityTray icon (although the frame is not loaded correctly yet, we'll need to wait for bug 1261030)
Attachment #8739030 -
Flags: review?(bfrancis)
Comment 3•9 years ago
|
||
Comment on attachment 8739030 [details] [review]
[gaia] albertopq:1262391-add-launch > mozilla-b2g:kanikani
Why do we need to get an "app" by its manifest URL and "launch" it to view the settings UI?
Why can't we just:
window.open('chrome://gaia/content/settings');
Or even:
window.open('about:settings');
There's not much point in removing the app registry and apps API from Gecko if we just re-implement it in Gaia is there?
Attachment #8739030 -
Flags: review?(bfrancis)
Assignee | ||
Comment 4•9 years ago
|
||
Thanks for your comments, Ben.
The main reason I'm keeping the launch method is for, as we talked before, touch the code as little as possible.
window.open never worked in the System domain (it replaces the system with the url that is being opened, so the phone breaks), it always was triggered from other apps (domains) and intercepted by the System. The work that will require changing all the code for working on that way is considerably bigger than this 3 liner patch. I would prefer to move to the new MozApps replacement from something that works.
We are not reimplementing the apps registry in Gaia, but finding a short term solution for making the current code work. If you have an alternative feasible on the time we have, I'll be happy to review it.
I agree that the final goal is to read the 'apps' from some places storage (we don't have that yet) and to launch those sites via window.open (doesn't work at the moment from the chrome://gaia domain), but if we can make things work and then iterate over it, we'll probably move faster (being able to configure wifi can help to others test stuff, for example) and at least we have plan B that works if we don't have time.
What do you think?
(In reply to Ben Francis [:benfrancis] from comment #3)
> Comment on attachment 8739030 [details] [review]
> [gaia] albertopq:1262391-add-launch > mozilla-b2g:kanikani
>
> Why do we need to get an "app" by its manifest URL and "launch" it to view
> the settings UI?
>
> Why can't we just:
>
> window.open('chrome://gaia/content/settings');
>
> Or even:
>
> window.open('about:settings');
>
> There's not much point in removing the app registry and apps API from Gecko
> if we just re-implement it in Gaia is there?
Flags: needinfo?(bfrancis)
Comment 5•9 years ago
|
||
Comment on attachment 8739030 [details] [review]
[gaia] albertopq:1262391-add-launch > mozilla-b2g:kanikani
OK, fair enough, if this enables us to configure WiFi then I guess it's worth a temporary hack to get things moving. I hope we get chance to do the real refactoring work to get rid of "apps" in the chrome altogether. I will try to make some more progress with Places.
Thanks Alberto.
Flags: needinfo?(bfrancis)
Attachment #8739030 -
Flags: review+
Assignee | ||
Comment 6•9 years ago
|
||
Thanks!
kanikani: https://github.com/mozilla-b2g/gaia/commit/eb05fa63b04363351663844906233dc063b14e11
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•