thanks a lot, it's work. As far as I can make out not enough just write in
manifest "display": "fullscreen". It need add in script code like below before
function screen.orientation.lock(type) :
var Fullscreen = {
launch: function(element) {
if(element.requestFullscreen) {
element.requestFullscreen();
} else if(element.mozRequestFullScreen) {
element.mozRequestFullScreen();
} else if(element.webkitRequestFullscreen) {
element.webkitRequestFullscreen();
} else if(element.msRequestFullscreen) {
element.msRequestFullscreen();
}
},
exit: function() {
if(document.exitFullscreen) {
document.exitFullscreen();
} else if(document.mozCancelFullScreen) {
document.mozCancelFullScreen();
} else if(document.webkitExitFullscreen) {
document.webkitExitFullscreen();
} else if (document.msExitFullscreen) {
document.msExitFullscreen();
}
}
};
Fullscreen.launch(document.documentElement);
Mb that information will be useful for somebody because in
https://crosswalk-project.org/documentation/screens.html nothing wrote about
this nicety
03.08.2015, 06:11, "Zhang, Belem" <[email protected]>:
> Hi,
>
> It seems that you modified some source code, and the Google Chrome Desktop -
> Developer Tool Bar indicates that there are "Uncaught TypeError" in your
> file, the fullscreen cannot work on Chrome Desktop browser so it blocks
> further screen orientation APIs.
>
> Please use the file as attached to test. If it still fails, please let me
> know. :)
>
> BR
> Belem
>
> -----Original Message-----
> From: Brezzy Cloud [mailto:[email protected]]
> Sent: Friday, July 31, 2015 11:04 PM
> To: Zhang, Belem <[email protected]>;
> [email protected]
> Subject: Re: [Crosswalk-help] help with sceen orientation api
>
> I attach builded app and source code and cam video with my steps
> https://www.youtube.com/watch?v=DN7djf26_Fc&feature=youtu.be
> mb i incorrectly build app?
>
> 31.07.2015, 04:21, "Zhang, Belem" <[email protected]>:
>> I've confirmed that it works when saving the
>> http://aurelio.audero.it/demo/screen-orientation-api-demo.html to local as
>> index.html and change the "start_url": "index.html" in manifest.json with
>> Stable build 14.43.343.17 on Android 4.4.2 device ASUS Memo Pad 8.
>>
>> Could you please double check if there is no encoding issue (ANSI, 866,
>> UTF-8 etc.) or source code change issue when you save it to local? Please
>> try to open the local page in browser (Chrome or Firefox) to see if it goes
>> to fullscreen when clicking "Lock!" button, or there might be some function
>> broken in local page.
>>
>> BR
>> Belem
>>
>> -----Original Message-----
>> From: Brezzy Cloud [mailto:[email protected]]
>> Sent: Thursday, July 30, 2015 4:50 PM
>> To: Zhang, Belem <[email protected]>;
>> [email protected]
>> Subject: Re: [Crosswalk-help] help with sceen orientation api
>>
>> i test it on android 4.0.4(api level 15) and 4.2.2(api level 17) . It
>> realy strange. I build project using your manifest and it works, but
>> if i download screen-orientation-api-demo.html (it doesn't have
>> external script) and change start_url to dowloaded(local) file nothing
>> works
>>
>> 30.07.2015, 08:01, "Zhang, Belem" <[email protected]>:
>>> Hi,
>>>
>>> By using the manifest.json below w/I or w/o "display":"fullscreen", the
>>> Lock and Unlock work well for all the values like "portrait", "landscape",
>>> "landscape-secondary" with Stable build 14.43.343.17 on Android 4.4.2
>>> device ASUS Memo Pad 8.
>>>
>>> {
>>> "name": "orientation api test",
>>> "xwalk_version": "1.00",
>>> "start_url":
>>> "http://aurelio.audero.it/demo/screen-orientation-api-demo.html",
>>> "icons": [
>>> {
>>> "src": "crosswalk.gif",
>>> "sizes": "128x128"
>>> }
>>> ]
>>> }
>>>
>>> What's the SDK version of your Android device?
>>>
>>> Relevant issues:
>>> https://crosswalk-project.org/jira/browse/XWALK-3300
>>> https://crosswalk-project.org/jira/browse/XWALK-2511
>>>
>>> 1. Use the Fullscreen API to make the application fullscreen at
>>> first
>>> 2. screen.orientation.lock()
>>>
>>> BR
>>> Belem
>>>
>>> -----Original Message-----
>>> From: Crosswalk-help
>>> [mailto:[email protected]] On
>>> Behalf
>>> Of Brezzy Cloud
>>> Sent: Thursday, July 30, 2015 5:49 AM
>>> To: [email protected]
>>> Subject: [Crosswalk-help] help with sceen orientation api
>>>
>>> firstly I try to use screen.lockOrientation(orientation) function in my
>>> project, but it dont work, after that I build app use this html:
>>> http://aurelio.audero.it/demo/screen-orientation-api-demo.html
>>> and manifest.json:
>>> {
>>> "name": "orientation api test",
>>>
>>> "xwalk_version": "1.00",
>>> "start_url": "index.html",
>>> "icons": [
>>> {
>>> "src": "icon/icon192.png",
>>> "sizes": "192x192",
>>> "type": "image/png",
>>> "density": "4.0"
>>> }
>>> ]
>>> }
>>> build it use crosswalk 14.43.343.17, but orientation to not want to
>>> change too. Any idea?
_______________________________________________
Crosswalk-help mailing list
[email protected]
https://lists.crosswalk-project.org/mailman/listinfo/crosswalk-help