Hello,
I made some additional tests with following testclass using
"org.gwt.mosaic.ui.client.datepicker.DateComboBox" in a WindowPanel:
----------------------------------------------------------------------------------------------------------------
import org.gwt.mosaic.ui.client.WindowPanel;
import org.gwt.mosaic.ui.client.datepicker.DateComboBox;
import com.google.gwt.core.client.EntryPoint;
import com.google.gwt.user.client.ui.HorizontalPanel;
public class Test_GWT_Mosaic implements EntryPoint {
public void onModuleLoad() {
WindowPanel wp = new WindowPanel();
wp.setPixelSize(300, 300);
DateComboBox dcb = new DateComboBox();
HorizontalPanel hp = new HorizontalPanel();
hp.add(dcb);
wp.add(hp);
wp.center();
wp.show();
}
}
----------------------------------------------------------------------------------------------------------------
its the same problem, the DatePicker is "under" the WindowPanel
having no z-index in its div tag, whereas the WindowPanel div tag is
having a z-index of 10000.
Looking further in WindowPanel class I found the following method
which is called during the initialisation of WindowPanel:
--------------------------
void setZIndex(int zIndexOffset) {
int zIndex = (zIndexOffset + Z_INDEX_BASE);
if (modal) {
zIndex += Z_INDEX_MODAL_OFFSET;
}
DOM.setStyleAttribute(getElement(), "zIndex",
Integer.toString(zIndex));
if (glassPanel != null && glassPanel.isAttached()) {
DOM.setStyleAttribute(glassPanel.getElement(), "zIndex",
Integer.toString(zIndex));
}
}
-----------------------------
Z_INDEX_BASE is defined is int 10000.
When I replace the code with:
void setZIndex(int zIndexOffset) {
//Do nothing
}
the DatePicker popup is displayed correctly, but I would not like to
replace the WindowPanel class with my owm class only for this purpose.
Question: Why is z-index set to 10000 by default.
Is there any other solution to make the DateComboBox DatePicker popup
correctly visible.
Is this a possible bug?
Kind regards
Bernhard