if (!this.isInitialised) { init(); }
	public final void paint(Graphics g) {		//#if polish.useFullScreen && polish.api.nokia-ui 			this.isInPaintMethod = true;		//#endif		try {			if (!this.isInitialised) {				init();			}			// paint background:			if (this.background != null) {				//#ifdef tmp.menuFullScreen					this.background.paint(0, 0, this.screenWidth, this.fullScreenHeight, g);				//#else					this.background.paint(0, 0, this.screenWidth, this.screenHeight, g);				//#endif			} else {				g.setColor( 0xFFFFFF );				//#ifdef tmp.menuFullScreen					g.fillRect( 0, 0, this.screenWidth, this.fullScreenHeight );				//#else					g.fillRect( 0, 0, this.screenWidth, this.screenHeight );				//#endif			}						//#ifdef tmp.usingTitle				// paint title:				if (this.title != null) {					this.title.paint(0, 0, 0, this.screenWidth, g);				}				int tHeight = this.titleHeight;			//#else				//# int tHeight = 0;			//#endif			// protect the title, ticker and the full-screen-menu area:			g.setClip(0, tHeight, this.screenWidth, this.screenHeight - tHeight );			g.translate( 0, tHeight );			// paint content:			//System.out.println("starting to paint content of screen");			paintScreen( g);			//System.out.println("done painting content of screen");						g.translate( 0, - tHeight );			// allow painting outside of the screen again:			//#ifdef tmp.menuFullScreen			 	g.setClip(0, 0, this.screenWidth, this.fullScreenHeight );			//#else			 	g.setClip(0, 0, this.screenWidth, this.originalScreenHeight );			//#endif			 			//#ifndef polish.skipTicker			if (this.ticker != null) {				this.ticker.paint( 0, this.screenHeight, 0, this.screenWidth, g );			}			//#endif						// paint border:			if (this.border != null) {				this.border.paint(0, 0, this.screenWidth, this.screenHeight, g);			}						// paint menu in full-screen mode:			//#ifdef tmp.menuFullScreen				if (this.menuOpened) {					int menuHeight = this.menuContainer.getItemHeight(this.menuMaxWidth, this.menuMaxWidth);					int y = this.originalScreenHeight - menuHeight;					if (y < this.titleHeight) {						y = this.titleHeight; 						this.menuContainer.setVerticalDimensions(y, this.screenHeight);					}					this.menuContainer.paint(0, y, 0, this.menuMaxWidth, g);				} 				// clear menu-bar:				if (this.menuBarColor != Item.TRANSPARENT) {					g.setColor( this.menuBarColor );					g.fillRect(0, this.originalScreenHeight, this.screenWidth,  this.menuBarHeight );				}				if (this.menuContainer != null && this.menuContainer.size() > 0) {					String menuText = null;					if (this.menuOpened) {						//TODO rob internationalise cmd.selectMenu						menuText = "Select";					} else {						if (this.menuSingleLeftCommand != null) {							menuText = this.menuSingleLeftCommand.getLabel();						} else {							//TODO rob internationalise cmd.openMenu							menuText = "Options";										}					}					g.setColor( this.menuFontColor );					g.setFont( this.menuFont );					g.drawString(menuText, 2, this.originalScreenHeight + 2, Graphics.TOP | Graphics.LEFT );					if ( this.menuOpened ) {						// draw select string:						//TODO rob internationalise cmd.cancelMenu						menuText = "Cancel";						g.drawString(menuText, this.screenWidth - 2, this.originalScreenHeight + 2, Graphics.TOP | Graphics.RIGHT );					}				}				if (this.menuSingleRightCommand != null && !this.menuOpened) {					g.setColor( this.menuFontColor );					g.setFont( this.menuFont );					g.drawString(this.menuSingleRightCommand.getLabel(), this.screenWidth - 2, this.originalScreenHeight + 2, Graphics.TOP | Graphics.RIGHT );				}			//#endif		} catch (RuntimeException e) {			//#mdebug error				Debug.debug( "unable to paint screen", e );				if (true) {					return;				}			//#enddebug		}		//#if polish.useFullScreen && polish.api.nokia-ui 			this.lastPaintTime = System.currentTimeMillis();			this.isInPaintMethod = false;		//#endif		//TODO rob paint the ticker	}