本文整理汇总了Java中com.google.gwt.dom.client.Style.clearWidth方法的典型用法代码示例。如果您正苦于以下问题:Java Style.clearWidth方法的具体用法?Java Style.clearWidth怎么用?Java Style.clearWidth使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类com.google.gwt.dom.client.Style
的用法示例。
在下文中一共展示了Style.clearWidth方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: setRatio
import com.google.gwt.dom.client.Style; //导入方法依赖的package包/类
public void setRatio() {
Style style = element.getStyle();
style.clearWidth();
style.clearHeight();
style.setPaddingTop(initialRatio, Style.Unit.PCT);
}
示例2: unclipImage
import com.google.gwt.dom.client.Style; //导入方法依赖的package包/类
private void unclipImage() {
Style style = image.getElement().getStyle();
style.clearLeft();
style.clearTop();
style.clearWidth();
style.clearHeight();
}
示例3: CubaSuggestPopup
import com.google.gwt.dom.client.Style; //导入方法依赖的package包/类
public CubaSuggestPopup() {
Style style = loadingImage.getElement().getStyle();
style.clearWidth();
style.clearHeight();
style.setDisplay(Style.Display.BLOCK);
}
示例4: setImageSize
import com.google.gwt.dom.client.Style; //导入方法依赖的package包/类
private void setImageSize() {
int width = isFullSize?attachmentWidth:thumbnailWidth;
int height = isFullSize?attachmentHeight:thumbnailHeight;
image.setPixelSize(width, height);
//TODO(user,danilatos): Whinge about how declarative UI doesn't let us avoid this hack:
Style pstyle = image.getElement().getParentElement().getParentElement().getStyle();
if (width == 0) {
image.setWidth("");
pstyle.clearWidth();
} else {
pstyle.setWidth(width, Unit.PX);
}
if (height == 0) {
image.setHeight("");
pstyle.clearHeight();
} else {
pstyle.setHeight(height, Unit.PX);
}
String url = isFullSize?attachmentUrl:thumbnailUrl;
if (url != null) {
if (doubleBufferLoader == null) {
doubleBufferLoader = new DoubleBufferImage(spin, errorLabel, image);
}
doubleBufferLoader.loadImage(url);
DOM.setStyleAttribute(image.getElement(), "visibility", "");
}
// NOTE(user): IE requires that the imageCaptionContainer element has a width
// in order to correctly center the caption.
if (DO_FRAME_WIDTH_UPDATE) {
captionPanel.getElement().getStyle().setWidth(width, Unit.PX);
}
}