Closed Bug 796698 Opened 13 years ago Closed 13 years ago

[keyboard] forms.js is loaded too many times

Categories

(Firefox OS Graveyard :: Gaia, defect)

x86
macOS
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: djf, Unassigned)

References

Details

(Whiteboard: QARegressExclude)

If I'm understanding it all correctly, it looks like both the system app and the keyboard app use the mozKeyboard API. This means that both of them (through that API) listen for new frames, and load the forms.js content script into it. This means that new frames will have duplicate event listeners registered for focus events, and will broadcast duplicate events to both mozKeyboard objects, which will result in the keyboard app getting duplicate focuschange events. I'm trying to work around this in my patch for #796080, and am filing this bug now so that I have a bug number I can reference in that workaround.
attempted workaround is attached to https://bugzilla.mozilla.org/show_bug.cgi?id=796080
Adding Fabrice to the cc list since he's reviewing the patch for the related bug.
So, here's what's happening in MozKeyboard.js at gaia startup: init href=app://system.gaiamobile.org/index.html loading by in-process-browser-frame-shown for app://system.gaiamobile.org/index.html init href=app://keyboard.gaiamobile.org/index.html loading by in-process-browser-frame-shown for app://keyboard.gaiamobile.org/index.html loading by in-process-browser-frame-shown for app://system.gaiamobile.org/index.html loading by in-process-browser-frame-shown for app://keyboard.gaiamobile.org/index.html loading by in-process-browser-frame-shown for app://system.gaiamobile.org/index.html loading by remote-browser-frame-shown for app://keyboard.gaiamobile.org/index.html loading by remote-browser-frame-shown for app://system.gaiamobile.org/index.html And afterwards, when launching the browser app: loading by in-process-browser-frame-shown for app://keyboard.gaiamobile.org/index.html loading by in-process-browser-frame-shown for app://system.gaiamobile.org/index.html loading by remote-browser-frame-shown for app://keyboard.gaiamobile.org/index.html loading by remote-browser-frame-shown for app://system.gaiamobile.org/index.html I'd really like to understand 1) why we get all these frame-shown messages and 2) how to filter out those that should not lead to injecting the frame script.
Seems to be fixed by bug 802073. Another issue has been fixed too: focus made to the system app weren't catched by the keyboard API, except when browser or communication app were launched (non oop one?)
Status: NEW → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
Whiteboard: QARegressExclude
You need to log in before you can comment on or make changes to this bug.