The NativeMenubar API lets you customize the Windows Mobile/CE native menu buttons.
This API is part of the coreapi
extension that is included automatically.
extensions: ["coreapi"]
Be sure to review the JavaScript API Usage guide for important information about using this API in JavaScript
Be sure to review the Ruby API Usage guide for important information about using this API in Ruby
Property Access:
Rho::NativeMenubar.defaultMainMenu
Property Access:
Rho.NativeMenubar.extraButton
Rho::NativeMenubar.extraButton
Same values as for mainMenu.
Property Access:
Rho.NativeMenubar.extraMenu
Rho::NativeMenubar.extraMenu
Property Access:
Rho.NativeMenubar.mainButton
Rho::NativeMenubar.mainButton
Visible label.
URL to page which will be loaded into tab. It may be path to Ruby controller action; i.e. '/app/Account' would load the Account index action. For ruby callback use 'callback:/app/Account' Or JavaScript method to call: 'javascript: methodOnTab();'. Or path to html page to load.
Menu item will be displayed as disabled. Platforms:WM
Property Access:
Rho.NativeMenubar.mainMenu
Rho::NativeMenubar.mainMenu
Rho.NativeMenubar.extraButton = { label: "Extra" }; Rho.NativeMenubar.extraMenu = [ { label: "Show alert 1", action: JavaScript:show_alert_1();, }, { label: "Show alert 2", action: JavaScript:show_alert_2();, }, { label: "Win the lottery", disabled: true } ];
Rho::NativeMenubar.extraButton = { :label => "Extra" } Rho::NativeMenubar.extraMenu = [ { :label => "Show alert 1", :action => url_for(:action => :show_alert_1) }, { :label => "Show alert 2", :action => url_for(:action => :show_alert_2) }, { :label => "Win the lottery", :disabled => true } ]
function remove_menuitems() { Rho.NativeMenubar.mainMenu = []; }
def remove_menuitems Rho::NativeMenubar.mainMenu = [] end