当前位置: 首页>>代码示例>>Java>>正文


Java ResizeEvent类代码示例

本文整理汇总了Java中com.google.gwt.event.logical.shared.ResizeEvent的典型用法代码示例。如果您正苦于以下问题:Java ResizeEvent类的具体用法?Java ResizeEvent怎么用?Java ResizeEvent使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


ResizeEvent类属于com.google.gwt.event.logical.shared包,在下文中一共展示了ResizeEvent类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: prev

import com.google.gwt.event.logical.shared.ResizeEvent; //导入依赖的package包/类
public void prev() {
	iPanel.remove(iAssignmentDock);
	iPanel.insert(iCourseRequests, 0);
	iRequests.setVisible(false); iRequests.setEnabled(false);
	iReset.setVisible(false); iReset.setEnabled(false);
	iQuickAdd.setVisible(false); iQuickAdd.setEnabled(false);
	iEnroll.setVisible(false); iEnroll.setEnabled(false);
	if (iCustomCheckbox != null) {
		iCustomCheckbox.setVisible(false); iCustomCheckbox.setEnabled(false);
	}
	iPrint.setVisible(false); iPrint.setEnabled(false);
	if (iExport != null) {
		iExport.setVisible(false); iExport.setEnabled(false);
	}
	iSchedule.setVisible(iMode.isSectioning()); iSchedule.setEnabled(iMode.isSectioning());
	iSave.setVisible(!iMode.isSectioning()); iSave.setEnabled(!iMode.isSectioning() && iEligibilityCheck != null && iEligibilityCheck.hasFlag(EligibilityFlag.CAN_REGISTER));
	if (iEligibilityCheck != null && iEligibilityCheck.hasFlag(EligibilityFlag.DEGREE_PLANS)) {
		iDegreePlan.setVisible(true); iDegreePlan.setEnabled(true);
	}
	clearMessage();
	ResizeEvent.fire(this, getOffsetWidth(), getOffsetHeight());
	AriaStatus.getInstance().setHTML(ARIA.courseRequests());
	updateScheduleChangedNoteIfNeeded();
}
 
开发者ID:Jenner4S,项目名称:unitimes,代码行数:25,代码来源:StudentSectioningWidget.java

示例2: createView

import com.google.gwt.event.logical.shared.ResizeEvent; //导入依赖的package包/类
public void createView() {
  shell = new ResizeLayoutPanel();
  shell.setSize("100%", "100%");
  shell.addResizeHandler(new ResizeHandler() {
    @Override
    public void onResize(ResizeEvent event) {
      forceLayout();
    }
  });

  panel = new DockLayoutPanel(Style.Unit.PX);
  panel.setSize("100%", "100%");
  shell.add(panel);

  Widget header = createNorth();
  panel.addNorth(header, 128);

  Widget footer = createSouth();
  panel.addSouth(footer, 42);
}
 
开发者ID:mvp4g,项目名称:mvp4g2-examples,代码行数:21,代码来源:ShellView.java

示例3: createWidget

import com.google.gwt.event.logical.shared.ResizeEvent; //导入依赖的package包/类
private void createWidget() {
  widgetPanel = new ResizeLayoutPanel();
  widgetPanel.addStyleName(style.widgetPanel());
  widgetPanel.addResizeHandler(new ResizeHandler() {
    @Override
    public void onResize(ResizeEvent event) {
      forceLayout();
    }
  });

  panel = new FlowPanel();
  panel.addStyleName(style.panel());
  widgetPanel.add(panel);

  label = new Label();
  label.addStyleName(style.label());
  panel.add(label);

  textBox = new TextBox();
  textBox.addStyleName(style.textBox());
  panel.add(textBox);

  initWidget(widgetPanel);
}
 
开发者ID:mvp4g,项目名称:mvp4g2-examples,代码行数:25,代码来源:TextField.java

示例4: initWindow

import com.google.gwt.event.logical.shared.ResizeEvent; //导入依赖的package包/类
public static void initWindow() {
//			consoleContainer = new AbsolutePanel();
//			consoleContainer.setWidth("3000px");
//			consoleContainer.setHeight("3000px");
//			RootPanel.get().add(consoleContainer, 0, 0);
//			//consoleContainer.getElement().getStyle().setPosition(Position.FIXED);
			updateWindowInfo();
			
			if (isMobile) {
				initMobile();
			} else {
				// Prevent scrollbars from being shown
				Window.enableScrolling(false);
			}
			
			// Add window resize handler
			Window.addResizeHandler(new ResizeHandler() {
				@Override
				public void onResize(ResizeEvent event) {
					doResizeAndRotate();
				}
			});
		}
 
开发者ID:openremote,项目名称:WebConsole,代码行数:24,代码来源:BrowserUtils.java

示例5: setResizeCheckingEnabled

import com.google.gwt.event.logical.shared.ResizeEvent; //导入依赖的package包/类
/**
 * Set whether or not resize checking is enabled. If disabled, elements will
 * still be resized on window events, but the timer will not check their
 * dimensions periodically.
 *
 * @param enabled true to enable the resize checking timer
 */
public void setResizeCheckingEnabled(boolean enabled) {
  if (enabled && !resizeCheckingEnabled) {
    resizeCheckingEnabled = true;
    if (windowHandler == null) {
      windowHandler = Window.addResizeHandler(new ResizeHandler() {
        public void onResize(ResizeEvent event) {
          onWindowResized(event.getWidth(), event.getHeight());
        }
      });
    }
    resizeCheckTimer.schedule(resizeCheckDelay);
  } else if (!enabled && resizeCheckingEnabled) {
    resizeCheckingEnabled = false;
    if (windowHandler != null) {
      windowHandler.removeHandler();
      windowHandler = null;
    }
    resizeCheckTimer.cancel();
  }
}
 
开发者ID:jiakuan,项目名称:gwt-uploader,代码行数:28,代码来源:ResizableWidgetCollection.java

示例6: onResize

import com.google.gwt.event.logical.shared.ResizeEvent; //导入依赖的package包/类
/**
 * Called when the window is resized.
 * The algorithm uses is increase/decrease the chart size according with 
 * the new window size.
 */
public void onResize(ResizeEvent resize) {
  if (!autoResize) {
    return;
  }
  int nwheight = Window.getClientHeight();
  int nwwidth = Window.getClientWidth();
  double wfact = 1;
  double hfact = 1;
  if (nwheight != wheight) {
    hfact = (double) nwheight / (double) wheight;
    wheight = nwheight;
  }
  if (nwwidth != wwidth) {
    wfact = (double) nwwidth / (double) wwidth;
    wwidth = nwwidth;
  }
  if (wfact != 1 || hfact != 1) {
    resize((int) (width * wfact), (int) (height * hfact));
  }
}
 
开发者ID:codeaudit,项目名称:gwt-chronoscope,代码行数:26,代码来源:ChartPanel.java

示例7: BasicImageGrid

import com.google.gwt.event.logical.shared.ResizeEvent; //导入依赖的package包/类
public BasicImageGrid(AbstractPreviewData previewData) {
    super.setSize("100%", "100%");
    _previewData = (PreviewImageGridCreator.ImageGridPreviewData)previewData;
    mainPanel.setSize("100%", "100%");
    super.add(mainPanel);
    GwtUtil.setStyle(mainPanel, "backgroundColor", GRID_BACKGROUND_DEFAULT_COLOR);
    GwtUtil.setStyle(this, "backgroundColor", GRID_BACKGROUND_DEFAULT_COLOR);

    setPlotWidgetGroupValue(_previewData.getPlotWidgetGroup());

    for (int i = 0; i < INIT_SIZE; i++) {
        createAndAddMiniPlotWidget();
    }

    getPlotWidgetGroup().setImageGrid(this);
    getPlotWidgetGroup().setGridPopoutColumns(_previewData.getGridPopoutCols());
    getPlotWidgetGroup().setGridPopoutZoomType(_previewData.getGridPopoutZoomtype());

    Window.addResizeHandler(new ResizeHandler() {
        public void onResize(ResizeEvent event) {
            resize();
        }
    });
    plotError = new MiniPlotWidget.PlotError() {
        public void onError(WebPlot wp, String briefDesc, String desc, String details, Exception e) {

        }
    };
}
 
开发者ID:lsst,项目名称:firefly,代码行数:30,代码来源:BasicImageGrid.java

示例8: addXYPlot

import com.google.gwt.event.logical.shared.ResizeEvent; //导入依赖的package包/类
public static void addXYPlot(JscriptRequest jspr, String div) {
    Map<String,String> paramMap= jspr.asMap();
    WidgetFactory factory= Application.getInstance().getWidgetFactory();
    TablePreview xyPrev= factory.createObserverUI(WidgetFactory.XYPLOT,paramMap);
    xyPrev.bind(FFToolEnv.getHub());

    SimplePanel panel= makeCenter();
    panel.add(xyPrev.getDisplay());
    FFToolEnv.addToPanel(div, panel, "XY Plot");

    if (xyPrev.getDisplay() instanceof RequiresResize) {
        final RequiresResize resizer= (RequiresResize)xyPrev.getDisplay();
        Window.addResizeHandler(new ResizeHandler() {
            public void onResize(ResizeEvent event) {
                resizer.onResize();
            }
        });
    }
}
 
开发者ID:lsst,项目名称:firefly,代码行数:20,代码来源:XYPlotJSInterface.java

示例9: resize

import com.google.gwt.event.logical.shared.ResizeEvent; //导入依赖的package包/类
public void resize() {
    if (getLayoutManager() != null) {
        try {
            getLayoutManager().resize();
            WebEventManager.getAppEvManager().fireEvent(new WebEvent(this, Name.WINDOW_RESIZE,
                                                                     new ResizeEvent(Window.getClientWidth(), Window.getClientHeight()) {
                                                                     }));
        } catch (Exception e) {
            GWT.log("unexpected exception", e);
        }
    }
}
 
开发者ID:lsst,项目名称:firefly,代码行数:13,代码来源:Application.java

示例10: ResizableLayoutManager

import com.google.gwt.event.logical.shared.ResizeEvent; //导入依赖的package包/类
public ResizableLayoutManager(int minWidth, int minHeight) {
        super(minWidth, minHeight);
        mainPanel = new DockPanel();
//        resizer = new Resizer();

        Window.addResizeHandler(new ResizeHandler(){
                public void onResize(ResizeEvent event) {
                    Application.getInstance().resize();
                }
            });

//        WebEventManager.getAppEvManager().addListener(Name.REGION_SHOW,
//                            new WebEventListener(){
//                                public void eventNotify(WebEvent ev) {
//                                    resizer.setVisible(Application.getInstance().hasSearchResult());
//                                }
//                            });
        setupStatusRegion(this);

    }
 
开发者ID:lsst,项目名称:firefly,代码行数:21,代码来源:ResizableLayoutManager.java

示例11: show

import com.google.gwt.event.logical.shared.ResizeEvent; //导入依赖的package包/类
@Override
public void show() {
  if (recenter == null) {
    recenter =
        Window.addResizeHandler(
            new ResizeHandler() {
              @Override
              public void onResize(ResizeEvent event) {
                final int w = event.getWidth();
                final int h = event.getHeight();
                AutoCenterDialogBox.this.onResize(w, h);
              }
            });
  }
  super.show();
}
 
开发者ID:gerrit-review,项目名称:gerrit,代码行数:17,代码来源:AutoCenterDialogBox.java

示例12: onShowView

import com.google.gwt.event.logical.shared.ResizeEvent; //导入依赖的package包/类
@Override
public void onShowView() {
  super.onShowView();

  Window.enableScrolling(false);
  if (prefs.hideTopMenu()) {
    Gerrit.setHeaderVisible(false);
  }
  resizeHandler =
      Window.addResizeHandler(
          new ResizeHandler() {
            @Override
            public void onResize(ResizeEvent event) {
              resizeCodeMirror();
            }
          });
}
 
开发者ID:gerrit-review,项目名称:gerrit,代码行数:18,代码来源:DiffScreen.java

示例13: resize

import com.google.gwt.event.logical.shared.ResizeEvent; //导入依赖的package包/类
private void resize(ResizeEvent event) {
	secondResizeRequested = false;
	lastResizeEvent = event;

	if (lastShownFrame != null) {
		lastShownFrame.resize(event);
		centerHeader.setHeader(lastShownFrame.getLongTitle());

		if (secondResizeRequested) {
			// lastShownFrame.resize(event);
			frameSpace.fireEvent(event);
			// Window.resizeBy(0, 0);
		}
	}

	history.resize(event);
	clipboard.resize(event);
}
 
开发者ID:fhcampuswien,项目名称:atom,代码行数:19,代码来源:App.java

示例14: setComponentResized

import com.google.gwt.event.logical.shared.ResizeEvent; //导入依赖的package包/类
public void setComponentResized(JavaScriptObject aValue) {
	if (componentResized != aValue) {
		if (componentResizedReg != null) {
			componentResizedReg.removeHandler();
			componentResizedReg = null;
		}
		componentResized = aValue;
		if (componentResized != null && component instanceof HasResizeHandlers)
			componentResizedReg = ((HasResizeHandlers) component).addResizeHandler(new ResizeHandler() {
				@Override
				public void onResize(ResizeEvent event) {
					if (componentResized != null) {
						executeEvent(componentResized, EventsPublisher.publish(event));
					}
				}
			});
	}
}
 
开发者ID:marat-gainullin,项目名称:platypus-js,代码行数:19,代码来源:EventsExecutor.java

示例15: AbstractView

import com.google.gwt.event.logical.shared.ResizeEvent; //导入依赖的package包/类
public AbstractView() {
    super(Style.Unit.PX);
    setWidth(Window.getClientWidth() + "px");
    setHeight(Window.getClientHeight() + "px");
    Window.addResizeHandler(new ResizeHandler() {

        @Override
        public void onResize(ResizeEvent event) {
            int height = event.getHeight();
            setHeight(height + "px");
            int width = event.getWidth();
            setWidth(width + "px");
            parentResized(height, width, "px");
        }
    });
}
 
开发者ID:languageininteraction,项目名称:GraphemeColourSynaesthesiaApp,代码行数:17,代码来源:AbstractView.java


注:本文中的com.google.gwt.event.logical.shared.ResizeEvent类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。