Closed
Bug 1002345
Opened 11 years ago
Closed 11 years ago
[Stingray] widget life-cycle management
Categories
(Firefox OS Graveyard :: Gaia::Homescreen, defect)
Tracking
(Not tracked)
RESOLVED
FIXED
People
(Reporter: johnhu, Assigned: rexboy)
References
Details
(Whiteboard: [FT:Stream3])
Attachments
(1 file)
The widget iframe should be created at homescreen instead of system app, unlike 2-layered approach. This issue may handles:
1. widget creation
2. widget deletion
3. iframe management
4. widget show/hide
Assignee | ||
Updated•11 years ago
|
Assignee: nobody → rexboy
Assignee | ||
Comment 1•11 years ago
|
||
WIP
https://github.com/rexboy7/gaia/tree/widget_factory.js
Added classes:
* Widget factory
* Widget manager
* Widget window
I copied several files from system app. Let me explain some detail:
* application.js: Manage installed apps.
* browser_config_helper.js: Manage application manifest.
* browser_frame.js: Manage application iframe.
* I also tried to copy only required codes from AppWindow of system app so that we can remove dependency of AppWindow and related stuff.
Comment 2•11 years ago
|
||
(In reply to KM Lee [:rexboy][:蠟蠟蠟蠟] from comment #1)
> * application.js: Manage installed apps.
I guess it may be replaced with ours and depend on Bug 1002355.
WIP version is here: https://github.com/luke-chang/gaia/blob/TV_arch1/test_apps/homescreen-tv-arch1/js/applications.js
Reporter | ||
Comment 3•11 years ago
|
||
Agree with Luke's opinion.
Since this is newly added to homescreen, we may discuss and leverage the existing modules and redesign the API to support widget manager.
Assignee | ||
Comment 4•11 years ago
|
||
First workable patch.
I'll put it into reviewing after making some confirmation.
Reporter | ||
Comment 5•11 years ago
|
||
You application may be conflicted with Luke's bug 1002355.
Assignee | ||
Comment 6•11 years ago
|
||
Comment on attachment 8419975 [details]
Patch
Ok, I come up a version based on the latest code base. Here are some details for the patch:
* Add widget_manager, widget_window, widget_factory to manage widgets. widget_window no longer depends on appWindow of system app.
* But I still make use of browser_frame.js and browser_config_helper.js of system app, and made appropriate modification to apply them on our new Application.js.
John and Evelyn, would you help review the patch?
Attachment #8419975 -
Flags: review?(johu)
Attachment #8419975 -
Flags: review?(ehung)
Assignee | ||
Comment 7•11 years ago
|
||
Comment on attachment 8419975 [details]
Patch
Adding Tzu-lin.
Attachment #8419975 -
Flags: review?(tzhuang)
Reporter | ||
Comment 8•11 years ago
|
||
Comment on attachment 8419975 [details]
Patch
Please find my comments at PR.
Attachment #8419975 -
Flags: review?(johu)
Assignee | ||
Comment 9•11 years ago
|
||
Comment on attachment 8419975 [details]
Patch
Updated.
Thanks a lot for the suggestions.
Attachment #8419975 -
Flags: review?(johu)
Reporter | ||
Comment 10•11 years ago
|
||
Comment on attachment 8419975 [details]
Patch
No important issues here, I think.
There are few thing needing to check:
1. the staff about system message should be reconsidered. It can be kept here or removed, I think.
2. the testing code should be removed.
3. few nits.
Please update the PR before merge.
Attachment #8419975 -
Flags: review?(johu) → review+
Comment 11•11 years ago
|
||
Comment on attachment 8419975 [details]
Patch
r+ with nits, thanks for the patch
Attachment #8419975 -
Flags: review?(tzhuang) → review+
Reporter | ||
Comment 12•11 years ago
|
||
already landed to master: https://github.com/mozilla-b2g/gaia/commit/995bc8a785411871aaef261de58a1479f68dd811
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Updated•11 years ago
|
Whiteboard: [FT:Stream3]
Updated•11 years ago
|
Attachment #8419975 -
Flags: review?(ehung)
You need to log in
before you can comment on or make changes to this bug.
Description
•