You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@royale.apache.org by ca...@apache.org on 2019/06/26 16:18:05 UTC
[royale-asjs] branch develop updated: this moves the load of CSS to
the module,
but not solve the problem of use a MaterialIconType and load the css
implicitly
This is an automated email from the ASF dual-hosted git repository.
carlosrovira pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/royale-asjs.git
The following commit(s) were added to refs/heads/develop by this push:
new 1b1fa4c this moves the load of CSS to the module, but not solve the problem of use a MaterialIconType and load the css implicitly
1b1fa4c is described below
commit 1b1fa4c5d7120c746653837585cdfabade9c8915
Author: Carlos Rovira <ca...@apache.org>
AuthorDate: Wed Jun 26 18:17:58 2019 +0200
this moves the load of CSS to the module, but not solve the problem of use a MaterialIconType and load the css implicitly
---
.../JewelModule/src/main/royale/JewelModule.mxml | 14 +++++++++++++-
.../MainJewelApp/src/main/royale/MainJewelApp.mxml | 3 ---
.../main/royale/org/apache/royale/icons/FontIconBase.as | 2 +-
3 files changed, 14 insertions(+), 5 deletions(-)
diff --git a/examples/blog/BE0013_Dividing_an_Apache_Royale_application_with_modules/JewelModule/src/main/royale/JewelModule.mxml b/examples/blog/BE0013_Dividing_an_Apache_Royale_application_with_modules/JewelModule/src/main/royale/JewelModule.mxml
index 8577766..7214759 100644
--- a/examples/blog/BE0013_Dividing_an_Apache_Royale_application_with_modules/JewelModule/src/main/royale/JewelModule.mxml
+++ b/examples/blog/BE0013_Dividing_an_Apache_Royale_application_with_modules/JewelModule/src/main/royale/JewelModule.mxml
@@ -19,8 +19,20 @@ limitations under the License.
-->
<j:Module xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:j="library://ns.apache.org/royale/jewel"
- xmlns:js="library://ns.apache.org/royale/basic">
+ xmlns:js="library://ns.apache.org/royale/basic"
+ initComplete="initModule()">
+ <fx:Script>
+ <![CDATA[
+ import org.apache.royale.utils.css.loadCSS;
+
+ private function initModule():void
+ {
+ loadCSS('https://fonts.googleapis.com/icon?family=Material+Icons');
+ }
+ ]]>
+ </fx:Script>
+
<j:beads>
<js:ContainerDataBinding/>
<j:VerticalLayout/>
diff --git a/examples/blog/BE0013_Dividing_an_Apache_Royale_application_with_modules/MainJewelApp/src/main/royale/MainJewelApp.mxml b/examples/blog/BE0013_Dividing_an_Apache_Royale_application_with_modules/MainJewelApp/src/main/royale/MainJewelApp.mxml
index 61e7b94..878aa62 100644
--- a/examples/blog/BE0013_Dividing_an_Apache_Royale_application_with_modules/MainJewelApp/src/main/royale/MainJewelApp.mxml
+++ b/examples/blog/BE0013_Dividing_an_Apache_Royale_application_with_modules/MainJewelApp/src/main/royale/MainJewelApp.mxml
@@ -24,9 +24,6 @@
<fx:Script>
<![CDATA[
- // inject_html does not wotk in modules
- import MaterialIconType; MaterialIconType;
-
public function loadModule():void
{
moduleLoader.loadModule();
diff --git a/frameworks/projects/Icons/src/main/royale/org/apache/royale/icons/FontIconBase.as b/frameworks/projects/Icons/src/main/royale/org/apache/royale/icons/FontIconBase.as
index b91a1c0..7bcbfb8 100644
--- a/frameworks/projects/Icons/src/main/royale/org/apache/royale/icons/FontIconBase.as
+++ b/frameworks/projects/Icons/src/main/royale/org/apache/royale/icons/FontIconBase.as
@@ -18,8 +18,8 @@
////////////////////////////////////////////////////////////////////////////////
package org.apache.royale.icons
{
- import org.apache.royale.core.StyledUIBase;
import org.apache.royale.core.IIcon;
+ import org.apache.royale.core.StyledUIBase;
import org.apache.royale.utils.StringUtil;
COMPILE::JS