function checkThemeablebrowser()
{
cordova.ThemeableBrowser.open('http://yourdomain', '_blank',
{
statusbar:
{
color: '#000'
},
toolbar:
{
height: 44,
color: '#f0f0f0ff',
//image: ''
},
title:
{
color: '#003264ff',
//staticText: 'a text',
showPageTitle: true
},
closeButton:
{
wwwImage: 'images/close.png',
wwwImagePressed: 'images/close_pressed.png',
wwwImageDensity: 2,
align: 'left',
event: 'closePressed'
},
backButton:
{
wwwImage: 'images/back.png',
wwwImagePressed: 'images/back_pressed.png',
wwwImageDensity: 2,
align: 'left',
event: 'backPressed'
},
backButtonCanClose: false,
forwardButton:
{
wwwImage: 'images/forward.png',
wwwImagePressed: 'images/forward_pressed.png',
wwwImageDensity: 2,
align: 'left',
event: 'forwardPressed'
},
customButtons:
[
{
wwwImage: 'images/share.png',
wwwImagePressed: 'images/share_pressed.png',
wwwImageDensity: 2,
align: 'right',
event: 'sharePressed'
}
],
menu:
{
title: 'title',
cancel: 'cancel',
wwwImage: 'images/menu.png',
wwwImagePressed: 'images/menu_pressed.png',
wwwImageDensity: 2,
align: 'right',
items:
[
{
event: 'helloPressed',
label: 'helloWorld!'
},
{
event: 'testPressed',
label: 'test!'
}
]
}
})
.addEventListener('closePressed', function(e)
{
alert('closePressed!');
navigator.notification.alert("closePressed!", null, 'title', 'ok');
})
.addEventListener('backPressed', function(e)
{
alert('backPressed!');
navigator.notification.alert("backPressed!", null, 'title', 'ok');
})
.addEventListener('forwardPressed', function(e)
{
alert('forwardPressed!');
navigator.notification.alert("forwardPressed!", null, 'title', 'ok');
})
.addEventListener('sharePressed', function(e)
{
alert(e.url);
navigator.notification.alert(e.url, null, 'title', 'ok');
})
.addEventListener('helloPressed', function(e)
{
alert('helloPressed!');
navigator.notification.alert("helloPressed!", null, 'title', 'ok');
})
.addEventListener(cordova.ThemeableBrowser.EVT_ERR, function(e)
{
alert('EVT_ERR:' + e.message);
navigator.notification.alert(e.message, null, endMessage_title, 'title', 'ok');
})
.addEventListener(cordova.ThemeableBrowser.EVT_WRN, function(e)
{
alert('EVT_WRN:' + e.message);
navigator.notification.alert(e.message, null, endMessage_title, 'title', 'ok');
});
}
when the "closePressed" trigger
in iOS:the "alert" and the "navigator.notification.alert" can also trigger
in Android:never trigger One of them
when the "backPressed" trigger
in iOS:only "alert" can be trigger
in Android:never trigger One of them
when the "forwardPressed" trigger
in iOS:only "alert" can be trigger
in Android:never trigger One of them
when the "sharePressed" trigger
in iOS:only "alert" can be trigger
in Android:the "alert" and the "navigator.notification.alert" can also trigger
when I click the "menu" icon,the "menu" will show,at the moment...
in iOS:only the "alert" with "EVT_WRN" can be trigger
in Android:never trigger One of them
when the "menu" shown,for example that I click the "hello world" item
in iOS:only "alert" can be trigger
in Android:the "alert" and the "navigator.notification.alert" can also trigger
when the "menu" shown
the menu will in the screen bottom position (ipad mini)
is it normal ? (iphone not try yet)
maybe the center position is more a correct "default position" ?