Package com.google.gwt.user.client.ui

Examples of com.google.gwt.user.client.ui.Frame


   *
   * @param url the url
   * @return the new frame instance
   */
  public Frame setUrl(String url) {
    Frame f = new Frame(url);
    f.getElement().setPropertyInt("frameBorder", 0);
    f.setSize("100%", "100%");
    setLayout(new FlowLayout());
    removeAll();
    add(f);
    layout();
    return f;
View Full Code Here


   */
  public static void show(TextBox requestSampleTextBox, final RequestUriTree requestUriTree) {
    final DialogBox dialogBox = new DialogBox();
    dialogBox.setText(GuiFactory.strings.testRequestDialog());   
   
    final Frame frame = new Frame(requestSampleTextBox.getText());
    frame.setWidth(Math.floor(Window.getClientWidth() * 0.9) + "px");
    frame.setHeight(Math.floor(Window.getClientHeight() * 0.75) + "px");
   
    VerticalPanel iframePanel = new VerticalPanel();
    iframePanel.setVerticalAlignment(HasVerticalAlignment.ALIGN_TOP);

    HorizontalPanel iframeSampleBoxPanel = new HorizontalPanel();  
   
    final TextBox iframeSampleTextBox = new TextBox();
    iframeSampleTextBox.setText(requestSampleTextBox.getText());
    iframeSampleTextBox.setWidth(Math.floor(Window.getClientWidth() * 0.6) + "px");
    iframeSampleBoxPanel.add(iframeSampleTextBox);   
    iframeSampleBoxPanel.add(new HTML(" "));   
    
    Button iframeReTestButton = new Button(GuiFactory.strings.reTestRequest());
    iframeReTestButton.addClickListener(new ClickListener() {
      public void onClick(Widget sender) {
        frame.setUrl(iframeSampleTextBox.getText());
      }
    });
    iframeSampleBoxPanel.add(iframeReTestButton);
   
    iframeSampleBoxPanel.add(new HTML(" "));   
View Full Code Here

 
  public static class ScreenBlockerIE6_7 extends ScreenBlockerImpl
  {
    protected ScreenBlockerIE6_7()
    {
      Frame blockingFrame = new Frame();
      expandElementToScreen(blockingFrame);
      blockingFrame.getElement().getStyle().setProperty("opacity", "0.0");
      blockingFrame.getElement().getStyle().setProperty("filter", "alpha(opacity=0)");
      wrapper.add(blockingFrame);
    }
View Full Code Here

                tabbedPanel.add( constants.UserPermissionMappings(),
                                 new PermissionViewer() );
                break;
            case 6 :
                // TODO: Not a manager -Rikkola-
                Frame aboutInfoFrame = new Frame( "../AboutInfo.html" ); // NON-NLS

                FormStylePopup aboutPop = new FormStylePopup();
                aboutPop.setWidth( 600 + "px" );
                aboutPop.setTitle( constants.About() );
                String hhurl = GWT.getModuleBaseURL()
View Full Code Here

         } else {
             name = "/designer/editor";
         } **/

        name = "/"+ApplicationPreferences.getDesignerContext()+"/editor/?uuid=" + modelUUID + "&profile="+ApplicationPreferences.getDesignerProfile();
        frame = new Frame( name );
        frame.getElement().setAttribute( "domain",
                                         Document.get().getDomain() );
        frame.setWidth( "100%" );
        frame.setHeight( "100%" );
        initWidget( frame );
View Full Code Here

            setAutoHideEnabled(true);
            setModal(false);
           
            VerticalPanel panel = new VerticalPanel();
           
            frame = new Frame();
            frame.setPixelSize(400, 300);
            Button close = new Button("close");
            close.addClickHandler(new ClickHandler() {
                public void onClick(ClickEvent event) {
                    hide();
View Full Code Here

            // TODO multiple opens with the same target will in practice just
            // open the last one - should we fix that somehow?
            final String parsedUri = client.translateVaadinUri(childUidl
                    .getStringAttribute("src"));
            if (!childUidl.hasAttribute("name")) {
                final Frame frame = new Frame();
                DOM.setStyleAttribute(frame.getElement(), "width", "100%");
                DOM.setStyleAttribute(frame.getElement(), "height", "100%");
                DOM.setStyleAttribute(frame.getElement(), "border", "0px");
                frame.setUrl(parsedUri);
                contentPanel.setWidget(frame);
                showingUrl = true;
            } else {
                final String target = childUidl.getStringAttribute("name");
                Window.open(parsedUri, target, "");
View Full Code Here

            // TODO multiple opens with the same target will in practice just
            // open the last one - should we fix that somehow?
            final String parsedUri = client.translateVaadinUri(childUidl
                    .getStringAttribute("src"));
            if (!childUidl.hasAttribute("name")) {
                final Frame frame = new Frame();
                DOM.setStyleAttribute(frame.getElement(), "width", "100%");
                DOM.setStyleAttribute(frame.getElement(), "height", "100%");
                DOM.setStyleAttribute(frame.getElement(), "border", "0px");
                frame.setUrl(parsedUri);
                contentPanel.setWidget(frame);
                showingUrl = true;
            } else {
                final String target = childUidl.getStringAttribute("name");
                Window.open(parsedUri, target, "");
View Full Code Here

    @Test
    public void testCreateFrameElement() throws Exception {
        PowerMockito.mockStatic(Element.class);
        Element theElementMock = PowerMockito.mock(Element.class);

        Frame theFrameMock = mockInitFrame();
        when(theFrameMock.getElement()).thenReturn(theElementMock);

        PrivateMethodExecutor<GWTStreamingClientConnectorGecko> thePrivateMethodExecutor = new PrivateMethodExecutor<GWTStreamingClientConnectorGecko>(GWTStreamingClientConnectorGecko.class);
        thePrivateMethodExecutor.executePrivateMethod("createFrameElement");
    }
View Full Code Here

    }

    private static Frame mockInitFrame() throws Exception {
        GWTMockUtilities.disarm();

        Frame theFrameMock = mock(Frame.class);
        PowerMockito.whenNew(Frame.class).withNoArguments().thenReturn(theFrameMock);

        GWTMockUtilities.restore();

        return theFrameMock;
View Full Code Here

TOP

Related Classes of com.google.gwt.user.client.ui.Frame

Copyright © 2018 www.massapicom. 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.