example.payment.jbricks
Class Screen

java.lang.Object
  extended by javax.microedition.lcdui.Displayable
      extended by javax.microedition.lcdui.Canvas
          extended by example.payment.jbricks.Screen

public class Screen
extends javax.microedition.lcdui.Canvas

This class handles and coordinates most of the drawing for this game. It knows how to draw the splash and game over screen, as well as the actual games screen. It also forwards 'cooked' key events to the Engine class.


Field Summary
static int BACKGROUND
           
static javax.microedition.lcdui.Graphics GRAPHICS
           
static int height
           
static int width
           
 
Fields inherited from class javax.microedition.lcdui.Canvas
DOWN, FIRE, GAME_A, GAME_B, GAME_C, GAME_D, KEY_NUM0, KEY_NUM1, KEY_NUM2, KEY_NUM3, KEY_NUM4, KEY_NUM5, KEY_NUM6, KEY_NUM7, KEY_NUM8, KEY_NUM9, KEY_POUND, KEY_STAR, LEFT, RIGHT, UP
 
Constructor Summary
Screen(javax.microedition.midlet.MIDlet midlet)
           
 
Method Summary
 void keyPressed(int keycode)
           
 void keyReleased(int keycode)
           
 void paint(javax.microedition.lcdui.Graphics g)
           
 void paintMenu(javax.microedition.lcdui.Graphics g)
           
 void setEngine(Engine engine)
           
 
Methods inherited from class javax.microedition.lcdui.Canvas
getGameAction, getKeyCode, getKeyName, hasPointerEvents, hasPointerMotionEvents, hasRepeatEvents, hideNotify, isDoubleBuffered, keyRepeated, pointerDragged, pointerPressed, pointerReleased, repaint, repaint, serviceRepaints, setFullScreenMode, showNotify, sizeChanged
 
Methods inherited from class javax.microedition.lcdui.Displayable
addCommand, getHeight, getTicker, getTitle, getWidth, isShown, removeCommand, setCommandListener, setTicker, setTitle
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

width

public static int width

height

public static int height

GRAPHICS

public static javax.microedition.lcdui.Graphics GRAPHICS

BACKGROUND

public static final int BACKGROUND
Constructor Detail

Screen

public Screen(javax.microedition.midlet.MIDlet midlet)
Method Detail

setEngine

public void setEngine(Engine engine)

keyPressed

public void keyPressed(int keycode)
Overrides:
keyPressed in class javax.microedition.lcdui.Canvas

keyReleased

public void keyReleased(int keycode)
Overrides:
keyReleased in class javax.microedition.lcdui.Canvas

paintMenu

public void paintMenu(javax.microedition.lcdui.Graphics g)

paint

public void paint(javax.microedition.lcdui.Graphics g)
Specified by:
paint in class javax.microedition.lcdui.Canvas