|
@@ -94,7 +94,7 @@ class Component extends Sprite {
|
|
needRebuild = true;
|
|
needRebuild = true;
|
|
return this;
|
|
return this;
|
|
}
|
|
}
|
|
-
|
|
|
|
|
|
+
|
|
public function addStyle(s) {
|
|
public function addStyle(s) {
|
|
if( customStyle == null )
|
|
if( customStyle == null )
|
|
customStyle = new h2d.css.Style();
|
|
customStyle = new h2d.css.Style();
|
|
@@ -102,6 +102,14 @@ class Component extends Sprite {
|
|
needRebuild = true;
|
|
needRebuild = true;
|
|
return this;
|
|
return this;
|
|
}
|
|
}
|
|
|
|
+
|
|
|
|
+ public function addStyleString(s) {
|
|
|
|
+ if( customStyle == null )
|
|
|
|
+ customStyle = new h2d.css.Style();
|
|
|
|
+ new h2d.css.Parser().parse(s, customStyle);
|
|
|
|
+ needRebuild = true;
|
|
|
|
+ return this;
|
|
|
|
+ }
|
|
|
|
|
|
public function getClasses() : Iterable<String> {
|
|
public function getClasses() : Iterable<String> {
|
|
return classes;
|
|
return classes;
|