Examples of WindowState


Examples of javax.portlet.WindowState

            portalURL.setActionWindow(decodeControlParameter(token)[0]);
          }
          // Window state definition: portalURL.setWindowState().
          else if (token.startsWith(PREFIX + WINDOW_STATE)) {
            String[] decoded = decodeControlParameter(token);
            portalURL.setWindowState(decoded[0], new WindowState(decoded[1]));
          }
          // Portlet mode definition: portalURL.setPortletMode().
          else if (token.startsWith(PREFIX + PORTLET_MODE)) {
            String[] decoded = decodeControlParameter(token);
            portalURL.setPortletMode(decoded[0], new PortletMode(decoded[1]));
View Full Code Here

Examples of javax.portlet.WindowState

     * @return The WindowState
     */
    public WindowState getState() {
        String state = (String) urlData.get(getStateKey());
        if (state != null) {
            return new WindowState(state);
        }
        else {
            return WindowState.NORMAL;
        }
    }
View Full Code Here

Examples of javax.portlet.WindowState

            pap = dynProv.getPortletActionProvider(event.getPortletWindow());
            final PortletMode mode = event.getPortletMode();
            if ( mode != null ) {
                pap.changePortletMode(mode);
            }
            final WindowState state = event.getWindowState();
            if ( state != null ) {
                pap.changePortletWindowState(state);
            }
        }
    }
View Full Code Here

Examples of javax.portlet.WindowState

            final PortletWindowImpl impl = (PortletWindowImpl)this.portletWindow;
            final CopletLayout cl = impl.getLayout();
            Event sizingEvent = null;
            if ( cl != null ) {
                final CopletInstanceData cid = cl.getCopletInstanceData();
                WindowState oldState = (WindowState)cid.getTemporaryAttribute("window-state");
                if ( oldState == null ) {
                    oldState = WindowState.NORMAL;
                }
                if ( this.state != null && !this.state.equals(oldState) ) {
                    if ( oldState.equals(WindowState.MAXIMIZED) ) {
                        sizingEvent = new FullScreenCopletEvent( cid, null );                   
                    } else {
                        if ( this.state.equals(WindowState.MAXIMIZED) ) {
                            sizingEvent = new FullScreenCopletEvent( cid, cl );                                           
                        }
View Full Code Here

Examples of javax.portlet.WindowState

            if ( this.environment != null ) {
                InformationProviderService ips = (InformationProviderService) this.environment.getContainerService(InformationProviderService.class);
                DynamicInformationProvider dip = ips.getDynamicProvider((HttpServletRequest) context.getObjectModel().get("portlet-request"));
               
                // Sizing
                WindowState ws = (WindowState)copletInstanceData.getTemporaryAttribute("window-state");
                if ( ws == null ) {
                    ws = WindowState.NORMAL;
                }
               
                if ( !ws.equals(WindowState.MINIMIZED) && !ws.equals(WindowState.MAXIMIZED)) {
                    PortletURLProviderImpl url = (PortletURLProviderImpl)dip.getPortletURLProvider(window);
                    url.clearParameters();
                    url.setWindowState(WindowState.MINIMIZED);
                   
                    XMLUtils.createElement(contenthandler, "minimize-uri", url.toString());
                }

                if ( !ws.equals(WindowState.NORMAL)) {
                    PortletURLProviderImpl url = (PortletURLProviderImpl)dip.getPortletURLProvider(window);
                    url.clearParameters();
                    url.setWindowState(WindowState.NORMAL);
                    XMLUtils.createElement(contenthandler, "maximize-uri", url.toString());
                }

                if ( !ws.equals(WindowState.MAXIMIZED)) {
                    PortletURLProviderImpl url = (PortletURLProviderImpl)dip.getPortletURLProvider(window);
                    url.clearParameters();
                    url.setWindowState(WindowState.MAXIMIZED);
                    XMLUtils.createElement(contenthandler, "fullscreen-uri", url.toString());
                }
View Full Code Here

Examples of javax.portlet.WindowState

            throw new IllegalArgumentException(msg);
        }
       
        // We can short-circut the registry lookup if the window state is
        // one from PLT.9
        if ( JSR168_WINDOW_STATES.contains(new WindowState(state)) )
        {
            return true;
        }
       
        // If the supplied window state isn't a JSR 168 window state,
View Full Code Here

Examples of javax.portlet.WindowState

        // Check if someone else is maximized. If yes, don't show content.
        Map windowStates = portalURL.getWindowStates();
        for (Iterator it = windowStates.keySet().iterator(); it.hasNext();) {
            String windowId = (String) it.next();
            WindowState windowState = (WindowState) windowStates.get(windowId);
            if (WindowState.MAXIMIZED.equals(windowState)
                    && !window.getId().getStringId().equals(windowId)) {
                return "";
            }
        }
View Full Code Here

Examples of net.sourceforge.marathon.action.WindowState

            return;
        List<Window> windows = windowMonitor.getAllWindows();
        if (!windows.contains(window))
            return;

        WindowState windowState = new WindowState(window);
        if (windowState.isEmpty())
            return;

        WindowId id = WindowIdCreator.createWindowId(window, windowMonitor);
        WindowStateAction action = new WindowStateAction(id, windowState, scriptModel, windowMonitor);
View Full Code Here

Examples of net.sourceforge.squirrel_sql.fw.gui.WindowState

  private void refresh()
  {
    if (_aliasesWindowState == null)
    {
      _aliasesWindowState = new WindowState();
    }
    if (_driversWindowState == null)
    {
      _driversWindowState = new WindowState();
    }

    if (_mgr != null)
    {
      _aliasesWindowState.copyFrom(_mgr.getAliasesWindowState());
View Full Code Here

Examples of org.gatein.pc.api.WindowState

            state = actionURL.getNavigationalState();
            if (state != null && !state.getStringValue().equals(StateString.JBPNS_PREFIX)) {
                url.setQueryParameterValue(NAVIGATIONAL_STATE_PARAM_NAME, state.getStringValue());
            }

            WindowState windowState = actionURL.getWindowState();
            if (windowState != null) {
                url.setQueryParameterValue(Constants.WINDOW_STATE_PARAMETER, windowState.toString());
            }

            Mode mode = actionURL.getMode();
            if (mode != null) {
                url.setQueryParameterValue(Constants.PORTLET_MODE_PARAMETER, mode.toString());
            }
        } else if (containerURL instanceof ResourceURL) {
            ResourceURL resourceURL = (ResourceURL) containerURL;

            url.setQueryParameterValue(Constants.RESOURCE_ID_PARAMETER, resourceURL.getResourceId());

            CacheLevel cachability = resourceURL.getCacheability();
            if (cachability != null) {
                url.setQueryParameterValue(Constants.CACHELEVEL_PARAMETER, cachability.name());
            }

            StateString resourceState = resourceURL.getResourceState();
            if (resourceState != null && !resourceState.getStringValue().equals(StateString.JBPNS_PREFIX)) {
                url.setQueryParameterValue(RESOURCE_STATE_PARAM_NAME, resourceState.getStringValue());
            }

            resourceState = resourceURL.getNavigationalState();
            if (resourceState != null && !resourceState.getStringValue().equals(StateString.JBPNS_PREFIX)) {
                url.setQueryParameterValue(NAVIGATIONAL_STATE_PARAM_NAME, resourceState.getStringValue());
            }

            WindowState windowState = resourceURL.getWindowState();
            if (windowState != null) {
                url.setQueryParameterValue(Constants.WINDOW_STATE_PARAMETER, windowState.toString());
            }

            Mode mode = resourceURL.getMode();
            if (mode != null) {
                url.setQueryParameterValue(Constants.PORTLET_MODE_PARAMETER, mode.toString());
            }
        } else {
            RenderURL renderURL = (RenderURL) containerURL;

            WindowState windowState = renderURL.getWindowState();
            if (windowState != null)// && !windowState.equals(WindowState.NORMAL))
            {
                url.setQueryParameterValue(Constants.WINDOW_STATE_PARAMETER, windowState.toString());
            }

            Mode mode = renderURL.getMode();
            if (mode != null) {
                url.setQueryParameterValue(Constants.PORTLET_MODE_PARAMETER, mode.toString());
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.