BlackBerry Forums Support Community               

Closed Thread
 
LinkBack Thread Tools
Old 09-10-2007, 04:33 AM   #1 (permalink)
Thumbs Must Hurt
 
Join Date: Jul 2007
Model: 8800
PIN: N/A
Carrier: TDC
Posts: 115
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default Override TrackwheelClick

Please Login to Remove!

Quote:
class SuperClassScreen extends MainScreen{

Evaka evakMain;
SuperClassScreen(Evaka evakMain) {

super();
this.evakMain=evakMain;
}


private MenuItem soegItem=new MenuItem("Menu 1",1,12){
public void run(){


evakMain.screenSearch();
}
};

private MenuItem evakueringItem=new MenuItem("Menu 2",1,12){
public void run(){


evakMain.screenChooseObjekt();
}
};


protected void makeMenu(Menu menu, int instance){

menu.add(evakueringItem);
menu.add(soegItem);

}

/* public boolean trackwheelClick(int status, int time){

Menu appMenu=new Menu();
makeMenu(appMenu,1);
appMenu.show();

return true;

}*/

public boolean onClose() {this.close();
return true;
}
}
Whenever i click the trackwheel i also get the menu which im not interested in... how do i override proper without getting the menu?
Offline  
Old 09-10-2007, 04:55 AM   #2 (permalink)
Thumbs Must Hurt
 
Join Date: Jun 2007
Location: Bangladesh
Model: 8800
PIN: N/A
Carrier: EDGE
Posts: 93
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default

Hi genvej,

Quote:
Originally Posted by genvej View Post
Code:
public boolean trackwheelClick(int status, int time){
Menu appMenu=new Menu();
makeMenu(appMenu,1);
appMenu.show();
return true;
}
Whenever i click the trackwheel i also get the menu which im not interested in... how do i override proper without getting the menu?
Here is a sample code to override the trackwheelClick method:
Code:
protected boolean trackwheelClick(int status, int time) {
    Dialog.alert("Trackwheel Click Events");
    return true;
}
Cheers,
ARIF
Offline  
Old 09-10-2007, 09:22 AM   #3 (permalink)
Thumbs Must Hurt
 
Join Date: Jul 2007
Model: 8800
PIN: N/A
Carrier: TDC
Posts: 115
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default

thx alot.. however overriding without doing anything is not good enough for me... i need the click functionality but without the menu popping up.

I solved with the CONSUME_CLICK attribute due to info in this thread.

Problem with Trackwheelclick and button
Offline  
Closed Thread


Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On





Copyright 2004-2014 BlackBerryForums.com.
The names RIM and BlackBerry are registered Trademarks of BlackBerry Inc.