Reputation: 119
I am new to blackberry development. I want a Custom Tab bar at the Bottom of the screen for blackberry application in my project, same as the image given below.I tried the sample code given by blackberry.
But now I want to use customised UI.I have searched it on Google and didn't get any productive information on what I want ,for custom fields. Please tell me how to do it in blackberry.
Has anyone done this previously?
Please reply Anything link/code/snippet.
Upvotes: 0
Views: 833
Reputation: 53
you forgot something. create new class within constructor which pushscreen the other class which extends main screen
example:
public class MyApp extends UiApplication{
public MyApp(){
pushScreen(new LoadingScreen());
} }
Upvotes: 0
Reputation: 4158
Try this code -
EncodedImage e2 = EncodedImage.getEncodedImageResource("map.png");
EncodedImage e3 = EncodedImage.getEncodedImageResource("members.png");
EncodedImage e4 = EncodedImage.getEncodedImageResource("message.png");
EncodedImage e5 = EncodedImage.getEncodedImageResource("settings.png");
EncodedImage e6 = EncodedImage.getEncodedImageResource("logout.png");
EyelidFieldManager manager = new EyelidFieldManager();
HorizontalFieldManager buttonPanel = new HorizontalFieldManager(Field.FIELD_TOP | Field.USE_ALL_WIDTH);
VerticalFieldManager vfm=new VerticalFieldManager();
vfm.add(new BitmapField(e2.getBitmap(),FOCUSABLE){
protected boolean navigationClick(int status, int time){
Dialog.alert("MAP");
return true;
}
});
buttonPanel.add(vfm);
buttonPanel.add(new LabelField(" "));
VerticalFieldManager vfm1=new VerticalFieldManager();
vfm1.add(new BitmapField(e3.getBitmap(),FOCUSABLE){
protected boolean navigationClick(int status, int time){
Dialog.alert("Members");
return true;
}
});
buttonPanel.add(vfm1);
VerticalFieldManager vfm2=new VerticalFieldManager();
vfm2.add(new BitmapField(e4.getBitmap(),FOCUSABLE){
protected boolean navigationClick(int status, int time){
Dialog.alert("Message");
return true;
}
});
buttonPanel.add(vfm2);
VerticalFieldManager vfm3=new VerticalFieldManager();
vfm3.add(new BitmapField(e5.getBitmap(),FOCUSABLE){
protected boolean navigationClick(int status, int time){
Dialog.alert("Settings");
return true;
}
});
buttonPanel.add(vfm3);
VerticalFieldManager vfm4=new VerticalFieldManager();
vfm4.add(new BitmapField(e6.getBitmap(),FOCUSABLE){
protected boolean navigationClick(int status, int time){
Dialog.alert("Logout");
return true;
}
});
buttonPanel.add(vfm4);
manager.add(buttonPanel);
setTitle(manager);
Upvotes: 1