mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 905107: Fix options in RIL.setScreenState, r=vicamo
The method RIL.setScreenState parses its arguments incorrectly. The RIL worker methods usually receive an object that contain their arguments, but setScreenState expects a boolean. Because objects are interpreted as 'true', setScreenState always signals enabled screen state to the RIL daemon. This patch changes RIL.setScreenState to expect an object as its argument and read the screen state from the object.
This commit is contained in:
parent
ae94c4f3f2
commit
9c99c5c991
@ -1065,10 +1065,10 @@ let RIL = {
|
||||
* @param on
|
||||
* Boolean indicating whether the screen should be on or off.
|
||||
*/
|
||||
setScreenState: function setScreenState(on) {
|
||||
setScreenState: function setScreenState(options) {
|
||||
Buf.newParcel(REQUEST_SCREEN_STATE);
|
||||
Buf.writeInt32(1);
|
||||
Buf.writeInt32(on ? 1 : 0);
|
||||
Buf.writeInt32(options.on ? 1 : 0);
|
||||
Buf.sendParcel();
|
||||
},
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user