上天要保佑!!!
2007-05-02 04:12:11 UTC
我有寫了一個j2me程式,在sony的手機上跑,我的數字鍵會亂掉,
請幫我看看,謝謝。
image1~9,就是數字1~9的圖片,我只是要貼數字圖,在sony手機上,1379會有問題,
是那個GAME_A~D的問題嗎。
public void keyPressed(int keyCode)
{
gameaction=getGameAction(keyCode);
switch(gameaction)
{
x = image2;
repaint();
break;
x = image8;
repaint();
break;
x = image4;
repaint();
break;
x = image6;
repaint();
break;
x = image5;
repaint();
break;
x = image1;
repaint();
break;
x = image3;
repaint();
break;
x = image7;
repaint();
break;
x = image9;
repaint();
break;
}
repaint();
}
g.drawImage(x, 5 , 3, Graphics.LEFT | Graphics.TOP);
這個是把圖片輸出,X我已經宣告成圖片格式了。
請各位幫我看一下吧,謝謝各位。
按鍵值1,3,9 ,7 用 KEY_NUM1 KEY_NUM3 KEY_NUM9 KEY_NUM7 去抓就好了請幫我看看,謝謝。
image1~9,就是數字1~9的圖片,我只是要貼數字圖,在sony手機上,1379會有問題,
是那個GAME_A~D的問題嗎。
public void keyPressed(int keyCode)
{
gameaction=getGameAction(keyCode);
switch(gameaction)
{
x = image2;
repaint();
break;
x = image8;
repaint();
break;
x = image4;
repaint();
break;
x = image6;
repaint();
break;
x = image5;
repaint();
break;
x = image1;
repaint();
break;
x = image3;
repaint();
break;
x = image7;
repaint();
break;
x = image9;
repaint();
break;
}
repaint();
}
g.drawImage(x, 5 , 3, Graphics.LEFT | Graphics.TOP);
這個是把圖片輸出,X我已經宣告成圖片格式了。
請各位幫我看一下吧,謝謝各位。
--
[;1;33;47m ◣[;35;47m ███ ███ [1;31m☆ [34m Post by[;36;47m airboy [m
[1;33;47m ◢█[;35;47m ▉▉█ █▇█ [1;33m★ [34mFrom [35m61-62-85-74-adsl-tpe.STATIC.so-net. [m
[1;33;44m◥█◤ [36m﹉ ﹍ ﹋ [32m月光海洋BBS [37m《mobbs.stut.edu.tw》 163.26.220.130 [m