Example #1
0
 /** Creates a new instance of AlternateImageRenderer */
 public AlternateImageRenderer() {
   super("");
   images = new Image[2];
   try {
     Resources imageRes = UIDemoMIDlet.getResource("images");
     images[0] = imageRes.getImage("sady.png");
     images[1] = imageRes.getImage("smily.png");
   } catch (IOException ex) {
     ex.printStackTrace();
   }
 }
Example #2
0
    public FishEyeRenderer() {
      super("");
      Image smily = null;
      try {
        Resources imageRes = UIDemoMIDlet.getResource("images");
        smily = imageRes.getImage("smily.png");
      } catch (IOException ex) {
        ex.printStackTrace();
      }
      title = new Label("");
      title.getSelectedStyle().setBgTransparency(0);
      Label description = new Label(smily);
      description.setText("description...");
      description.getSelectedStyle().setBgTransparency(0);
      selected.addComponent(title);
      selected.addComponent(description);
      title.setFocus(true);
      description.setFocus(true);

      // selected.getStyle().setBgTransparency(0xFF);
    }