Closed
Bug 1200426
Opened 6 years ago
Closed 6 years ago
Convert PROCESS_OBJECT event to native call
Categories
(Core :: Widget: Android, defect)
Tracking
()
RESOLVED
FIXED
mozilla44
Tracking | Status | |
---|---|---|
firefox44 | --- | fixed |
People
(Reporter: jchen, Assigned: jchen)
References
Details
Attachments
(2 files)
5.66 KB,
patch
|
snorp
:
review+
|
Details | Diff | Splinter Review |
12.58 KB,
patch
|
snorp
:
review+
|
Details | Diff | Splinter Review |
PROCESS_OBJECT event in GeckoEvent is used to set the GeckoLayerClient object in Gecko. We can convert it to a native call in GeckoView.
Assignee | ||
Comment 1•6 years ago
|
||
When we queue native calls in GeckoThread, we try to deduce the types of the arguments through Object.getClass(). However, there are cases where this could fail. For example, the argument could be null, or could be a String instance but the parameter type is really CharSequence. This patch introduces a way to optionally include parameter types for the queued call. When a passed-in argument is a Class instance, it is treated as the type for the next queued parameter, and the next argument is treated as the value for the queued parameter. For example, > // Queue a call with CharSequence parameter, using a String argument. > GeckoThread.queueNativeCall(..., CharSequence.class, "123"); > // Queue a call with String parameter, using a null argument. > GeckoThread.queueNativeCall(..., String.class, null); Deduction is still performed when the type is missing: > // Queue a call with int, String, and boolean parameter. > GeckoThread.queueNativeCall(..., 42, "123", true); > // Queue the same call but with a null argument. > GeckoThread.queueNativeCall(..., 42, String.class, null, true);
Attachment #8666779 -
Flags: review?(snorp)
Assignee | ||
Comment 2•6 years ago
|
||
The PROCESS_OBJECT GeckoEvent is used to set the layer client object in Gecko once Gecko is done loading. This patch converts it to a native call in GeckoView.Window. Because the native method has an Object parameter, we need the first patch in order to queue a call to it using GeckoThread.
Attachment #8666781 -
Flags: review?(snorp)
Attachment #8666779 -
Flags: review?(snorp) → review+
Attachment #8666781 -
Flags: review?(snorp) → review+
https://hg.mozilla.org/integration/mozilla-inbound/rev/2dea192c7f33 https://hg.mozilla.org/integration/mozilla-inbound/rev/4dcc2fb45208
Backed out for tpn bustage: https://treeherder.mozilla.org/logviewer.html#?job_id=15307384&repo=mozilla-inbound https://hg.mozilla.org/integration/mozilla-inbound/rev/f698df326e81
Flags: needinfo?(nchen)
https://hg.mozilla.org/integration/mozilla-inbound/rev/6dbb76e6a3a4 https://hg.mozilla.org/integration/mozilla-inbound/rev/2e8206d7352e
Comment 6•6 years ago
|
||
sorry had to back this out since this or the other checkin caused https://treeherder.mozilla.org/logviewer.html#?job_id=15360927&repo=mozilla-inbound
Backout: https://hg.mozilla.org/integration/mozilla-inbound/rev/a29c00eefd15 https://hg.mozilla.org/integration/mozilla-inbound/rev/600b7550c0ca
https://hg.mozilla.org/integration/mozilla-inbound/rev/8ca3465da606 https://hg.mozilla.org/integration/mozilla-inbound/rev/dee668cc4bb8
Comment 9•6 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/8ca3465da606 https://hg.mozilla.org/mozilla-central/rev/dee668cc4bb8
Status: ASSIGNED → RESOLVED
Closed: 6 years ago
status-firefox44:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla44
Assignee | ||
Updated•6 years ago
|
Flags: needinfo?(nchen)
You need to log in
before you can comment on or make changes to this bug.
Description
•