BlackBerry Forums Support Community               

Closed Thread
 
LinkBack Thread Tools
Old 02-26-2010, 04:09 AM   #1 (permalink)
New Member
 
Join Date: Feb 2010
Model: 9700
PIN: N/A
Carrier: Vodafone
Posts: 2
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default Navigation class

Please Login to Remove!

Hello BlackBerry Developers,

I've got a question.

I would like to put this code in a different class:

Code:
HorizontalFieldManager navigation = new HorizontalFieldManager();

Bitmap bmpHomeNrm = Bitmap.getBitmapResource("images/Home_normal.png");
Bitmap bmpHomeFcs = Bitmap.getBitmapResource("images/Home_focused.png");
btnHome = new BitmapButtonField(bmpHomeNrm, bmpHomeFcs, bmpHomeFcs);
btnHome.setChangeListener(this);
navigation.add(btnHome);

Bitmap bmpAboutNrm = Bitmap.getBitmapResource("images/About_normal.png");
Bitmap bmpAboutFcs = Bitmap.getBitmapResource("images/About_focused.png");
btnAbout = new BitmapButtonField(bmpAboutNrm, bmpAboutFcs, bmpAboutFcs);
btnAbout.setChangeListener(this);
navigation.add(btnAbout);

Bitmap bmpProductNrm = Bitmap.getBitmapResource("images/Product_normal.png");
Bitmap bmpProductFcs = Bitmap.getBitmapResource("images/Product_focused.png");
btnProduct = new BitmapButtonField(bmpProductNrm, bmpProductFcs, bmpProductFcs);
btnProduct.setChangeListener(this);
navigation.add(btnProduct);

Bitmap bmpContactNrm = Bitmap.getBitmapResource("images/Contact_normal.png");
Bitmap bmpContactFcs = Bitmap.getBitmapResource("images/Contact_focused.png");
btnContact = new BitmapButtonField(bmpContactNrm, bmpContactFcs, bmpContactFcs);
btnContact.setChangeListener(this);
navigation.add(btnContact);

add(navigation);
To add it later to the MainScreen like:

Code:
Navigation nav = new Navigation();
add(nav);
Because i just started with Java for Blackberry, i don't know which code i can put in which class and which class extention i have to use!

So, i hope that somebody can help me

Thanks in advance!

Marlon

Last edited by marlonx : 02-26-2010 at 04:34 AM.
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

powerful piezoelectric transducer
$79.99
powerful piezoelectric transducer pictureHerrmann Type CCS 20-S-IP50-L-I 20 kHz Konverter Ultrasonic Welding Transducer w
$2105.26
Herrmann Type CCS 20-S-IP50-L-I 20 kHz Konverter Ultrasonic Welding Transducer w pictureSIEMENS L10-5 TRANSDUCER/PROBE FOR CV70 ULTRASOUND-MODEL# 7472660
$1200.0
SIEMENS L10-5 TRANSDUCER/PROBE FOR CV70 ULTRASOUND-MODEL# 7472660 pictureSIEMENS 3.5P14 TRANSDUCER/PROBE FOR CV70 ULTRASOUND-PN 4304478-L0850
$1200.0
SIEMENS 3.5P14 TRANSDUCER/PROBE FOR CV70 ULTRASOUND-PN 4304478-L0850 pictureSETRA 2651001WDACT1C TRANSDUCER
$49.0
SETRA 2651001WDACT1C TRANSDUCER picture






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