Commit 0e6a05c4 authored by Colm Bennett's avatar Colm Bennett Committed by Gerrit Review System

Change style changes to camelCase, fixes Button mock component issue

where Shape changes don't work in Firefox. Also gets past an asset in
GWT dev mode.

Change-Id: I324de1d62f4a91c5c2d29ad7fb675aafaf426314
parent 661145e4
......@@ -123,7 +123,7 @@ abstract class MockButtonBase extends MockVisibleComponent {
switch(shape) {
case 0:
// Default Button
DOM.setStyleAttribute(buttonWidget.getElement(), "border-radius", "0px");
DOM.setStyleAttribute(buttonWidget.getElement(), "borderRadius", "0px");
break;
case 1:
// Rounded Button.
......@@ -131,16 +131,16 @@ abstract class MockButtonBase extends MockVisibleComponent {
// The value 10 px was chosen strictly for style.
// 10 px is the same as ROUNDED_CORNERS_RADIUS defined in
// com.google.appinventor.components.runtime.ButtonBase.
DOM.setStyleAttribute(buttonWidget.getElement(), "border-radius", "10px");
DOM.setStyleAttribute(buttonWidget.getElement(), "borderRadius", "10px");
break;
case 2:
// Rectangular Button
DOM.setStyleAttribute(buttonWidget.getElement(), "border-radius", "0px");
DOM.setStyleAttribute(buttonWidget.getElement(), "borderRadius", "0px");
break;
case 3:
// Oval Button
String height = DOM.getStyleAttribute(buttonWidget.getElement(), "height");
DOM.setStyleAttribute(buttonWidget.getElement(), "border-radius", height);
DOM.setStyleAttribute(buttonWidget.getElement(), "borderRadius", height);
break;
default:
// This should never happen
......@@ -222,7 +222,7 @@ abstract class MockButtonBase extends MockVisibleComponent {
// setting the widget's background color to COLOR_NONE.
MockComponentsUtil.setWidgetBackgroundColor(buttonWidget,
"&H" + COLOR_NONE);
DOM.setStyleAttribute(buttonWidget.getElement(), "border-radius", "0px");
DOM.setStyleAttribute(buttonWidget.getElement(), "borderRadius", "0px");
}
MockComponentsUtil.setWidgetBackgroundImage(buttonWidget, url);
image.setUrl(url);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment