Quote:
Originally Posted by jfisher setStatus(myField); |
yeah ok, looks like that what i want to have
Now one little thing more:
I paint an Image in that status(bar). Now I want to update the Graphic. it looks like this:
Code:
private Bitmap surface; //= new Bitmap(200,15);
private BitmapField surfaceField; //= new BitmapField(surface);
private Graphics g; //= new Graphics(surface);
/*...*/
drawStatus();
setStatus(surfaceField);
/*...*/
public void drawStatus() {
int batFull = DeviceInfo.getBatteryLevel();
g.clear();
g.drawBitmap(0,0,12,12,Bitmap.getBitmapResource("batterie.png"),0,0);
g.drawRect(15,0,102,14);
g.fillRect(16,1,batFull,12);
g.drawText(batFull+" %",120,0);
System.out.println("Status updated "+batFull);
}
/*...*/
//let's update the status...
drawStatus() I can read the right value in the debugger, but on the Display nothing happens... so can you help me once again?
thanks hibbert