Results 1 to 7 of 7
  1.    #1  
    I'm looking at making an app and would like to use the round 'plus' button used in many apps. (see attached image bottom right)
    I just can't seem to find it anywhere in the Palm documentation. Style matters doesn't show the HTML.
    Anybody know how to call it with HTML?
    Thanks!
    Attached Images Attached Images
    < M105 - M130 - M515 - T|T3 - Clié UX50 - T|x - Pré - Pré 2 - TouchPad 16GB>
    [url]
  2. #2  
    you are looking at a command menu. if you search palm for 'commandMenu' it should come up.

    here's the code you can put in the setup function:

    Code:
    this.controller.setupWidget(Mojo.Menu.commandMenu,
    	this.attributes = {
    		spacerHeight: 0,
    		menuClass: 'no-fade'
    	 },
    	 this.cmdMenuModel = {
    		 visible: true,
    		 items: [ {items:[
    			 { icon: "back", command: 'do-Add'}
    		 ]
    	 }
    );
    then setup a handleCommand function to do whatever you want when the plus is pushed:

    Code:
    YourAssistant.prototype.handleCommand = function(event) {
    	if (event.type == Mojo.Event.command) {
    		switch (event.command) {
    			case 'do-Add':
    				this.add(); //calls function to add something
    				break;}
             }
            //this will toggle the menu on and off if you do a forward gesture
             else if(event.type == Mojo.Event.forward){
    		this.commandOn();
    	}
    }
    then that should point to your 'add' function:

    Code:
    YourAssistant.prototype.add= function(event) {
    	<whatever code you want here>
    }
    you can also toggle the command menu on and off programmatically:

    Code:
    YourAssistant.prototype.commandOn = function(event) {
            //NOTE: cmdMenuModel is what we defined in the commandMenu setup in our setup function above
    	if(this.cmdMenuModel.visible == false){
    		this.cmdMenuModel.visible = true;
    		this.controller.modelChanged(this.cmdMenuModel, this);
    	}
    	else{
    		this.cmdMenuModel.visible = false;
    		this.controller.modelChanged(this.cmdMenuModel, this);
    	}
    	
    	
    }
    My site: Shanerooni, LLC
    Follow me on Twitter
    My apps: GuessWhat? | MazeHunter3D | Small Wonders | PhakePhoney | AutismAware | PicSketcher | Cubix | QuickSolve | QuickSpell | QuickTrace | QuickWhack | QuickSuite | Soccer Shots | Ballooning |
    Cubix
  3. #3  
    just to add the command menu doesn't have HTML it's solely jsjsjs
  4. #4  
    just to add the command menu doesn't have dev input html it's dynamically built using jsjsjs
  5.    #5  
    Thanks for the quick and extensive reply!
    There's more to it then I thought. I thought it was just another button shape. But it seems to do what I want it to do, be able to add items to a list in a database.
    < M105 - M130 - M515 - T|T3 - Clié UX50 - T|x - Pré - Pré 2 - TouchPad 16GB>
    [url]
  6. #6  
    Quote Originally Posted by Hz-R View Post
    But it seems to do what I want it to do
    it'll do whatever you tell it to do, as if it were the perfect wife! good luck
    My site: Shanerooni, LLC
    Follow me on Twitter
    My apps: GuessWhat? | MazeHunter3D | Small Wonders | PhakePhoney | AutismAware | PicSketcher | Cubix | QuickSolve | QuickSpell | QuickTrace | QuickWhack | QuickSuite | Soccer Shots | Ballooning |
    Cubix
  7.    #7  
    Quote Originally Posted by shanerooni View Post
    it'll do whatever you tell it to do, as if it were the perfect wife! good luck
    :-) Sure looks like it! Reading all the info at Palm Dev now. Thanks again!
    < M105 - M130 - M515 - T|T3 - Clié UX50 - T|x - Pré - Pré 2 - TouchPad 16GB>
    [url]

Posting Permissions