Search in sources :

Example 1 with ScreenWrapper

use of com.haulmont.cuba.gui.screen.compatibility.ScreenWrapper in project jmix by jmix-framework.

the class CubaScreens method openWindow.

@Override
public com.haulmont.cuba.gui.components.Window openWindow(WindowInfo windowInfo, OpenType openType, Map<String, Object> params) {
    params = createParametersMap(windowInfo, params);
    MapScreenOptions options = new MapScreenOptions(params);
    Screen screen = createScreen(windowInfo, openType.getOpenMode(), options);
    applyOpenTypeParameters(screen.getWindow(), openType);
    show(screen);
    return screen instanceof com.haulmont.cuba.gui.components.Window ? (com.haulmont.cuba.gui.components.Window) screen : new ScreenWrapper(screen);
}
Also used : ScreenWrapper(com.haulmont.cuba.gui.screen.compatibility.ScreenWrapper) LookupScreen(io.jmix.ui.screen.LookupScreen) EditorScreen(io.jmix.ui.screen.EditorScreen) Screen(io.jmix.ui.screen.Screen) MapScreenOptions(io.jmix.ui.screen.MapScreenOptions)

Example 2 with ScreenWrapper

use of com.haulmont.cuba.gui.screen.compatibility.ScreenWrapper in project jmix by jmix-framework.

the class CubaScreens method openWindow.

@Override
public com.haulmont.cuba.gui.components.Window openWindow(WindowInfo windowInfo, OpenType openType) {
    Map<String, Object> params = createParametersMap(windowInfo, Collections.emptyMap());
    MapScreenOptions options = new MapScreenOptions(params);
    Screen screen = createScreen(windowInfo, openType.getOpenMode(), options);
    applyOpenTypeParameters(screen.getWindow(), openType);
    show(screen);
    return screen instanceof com.haulmont.cuba.gui.components.Window ? (com.haulmont.cuba.gui.components.Window) screen : new ScreenWrapper(screen);
}
Also used : ScreenWrapper(com.haulmont.cuba.gui.screen.compatibility.ScreenWrapper) LookupScreen(io.jmix.ui.screen.LookupScreen) EditorScreen(io.jmix.ui.screen.EditorScreen) Screen(io.jmix.ui.screen.Screen) MapScreenOptions(io.jmix.ui.screen.MapScreenOptions)

Aggregations

ScreenWrapper (com.haulmont.cuba.gui.screen.compatibility.ScreenWrapper)2 EditorScreen (io.jmix.ui.screen.EditorScreen)2 LookupScreen (io.jmix.ui.screen.LookupScreen)2 MapScreenOptions (io.jmix.ui.screen.MapScreenOptions)2 Screen (io.jmix.ui.screen.Screen)2