我想更改我的黑莓屏幕GUI当我从纵向转到横向模式时。如何更改方向更改时的布局
protected void sublayout(int width, int height) {
// TODO Auto-generated method stub
if(Display.getOrientation()==Display.DIRECTION_PORTRAIT)
{
label.setText("Portrait");
}
else
{
label.setText("Landscape");
}
super.sublayout(width, height);
}
任何帮助,将不胜感激
我已经做了这件事,看代码更新..但它给非法stateexception –
尝试在设置文本之前在事件线程上同步。 http://www.youtube.com/watch?v=BiHZrkNIbXA&feature=player_embedded –