문제

I am developing a LWUIT S40 app. The guidelines specify that when a dialog is on, the background, including status bar, header bar, category bar, must be dimmed – 60% black.

I think that this will happen automatically, but it doesn't.

Anybody knows a way to do that? To dim the header bar and the category bar, like this capture (which is an lcdui alert)

LCDUI ALERT.

도움이 되었습니까?

해결책

I prefer to use native Alert from nokia LCDUI. the LWUIT for Series 40 allow us to combine the LCDUI component along with LWUIT component.

For example, here's my code:

Alert loading = new Alert("MIG33", "Loading user", null, null);
loading.setIndicator(new Gauge(null, false, Gauge.INDEFINITE, Gauge.CONTINUOUS_RUNNING));
javax.microedition.lcdui.Display.getDisplay(this).setCurrent(loading);

Since LWUIT has its own Display class we use in the midlet. It has to be written like above. So it can be differenced with the Display from LCDUI.

다른 팁

You need to set the tint color of the parent form to something like 0xaa000000 (an ARGB value to paint the background).

I dont think LWUIT S40 gives access to the header bar and the category bar, you need to get app Nokia signed to edit category bar colors. For me i customized the loading dialog and set the title like this : dialogObj.setTitle(" "); so nothing appears in the dialog title.

Also for an app using the category bar, instead of this approach i refresh the form's contents with the loading GIF or APNG and any loading message as well.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top