Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import javax.microedition.lcdui.Command;
- import javax.microedition.lcdui.CommandListener;
- import javax.microedition.lcdui.Display;
- import javax.microedition.lcdui.Displayable;
- import javax.microedition.lcdui.Form;
- import javax.microedition.lcdui.Gauge;
- public class EkranWprDanych extends Form implements CommandListener {
- Command powrot;
- Display wyswietlacz;
- Displayable ekranP;
- Form form = new Form("Demo Form");
- Gauge aGauge = new Gauge("Score",true,10,1);
- public EkranWprDanych(Displayable ekranPowrotny){
- super("Okno Wpr Danych");
- wyswietlacz = MojMidlet2.mojDisplay();
- ekranP = ekranPowrotny;
- powrot = new Command("Powrot",Command.BACK,1);
- this.addCommand(powrot);
- form.append(aGauge);
- wyswietlacz.setCurrent(form);
- this.setCommandListener(this);
- }
- public void commandAction(Command komenda, Displayable ekranP) {
- if (komenda == powrot){
- wyswietlacz.setCurrent(ekranP);
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement