Device:Android KitKat 4.4.2
hi,
i have something like this class for callback native interface
package com.mycompany;
public class NativeCallback {
public static void callback() {
// do stuff
}
}
and need to show as this Dialog in my static method, without crash my app
Dialog.show("Title", "body", "Ok", null);
note: i try to write like this
package com.mycompany;
///...
public class NativeCallback {
public static void callback() {
Dialog dlg = new Dialog("At Bottom");
dlg.setLayout(new BorderLayout());
dlg.add(new SpanLabel("Dialog Body text", "DialogBody"));
int h = Display.getInstance().getDisplayHeight();
dlg.setDisposeWhenPointerOutOfBounds(true);
dlg.show(h /8 * 7, 0, 0, 0);
}
}
but that does not work and led to crash my app
how i can do it?