本文整理匯總了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);
}
}