This is an automated email from the ASF dual-hosted git repository.

yishayw pushed a commit to branch inject_script
in repository https://gitbox.apache.org/repos/asf/royale-asjs.git

commit 14322f16c3ce44e7a4bdd2f3dc80f60e30842bd0
Author: DESKTOP-RH4S838\Yishay <yishayj...@hotmail.com>
AuthorDate: Thu May 14 17:26:47 2020 +0300

    <inject_html> is no longer supported, use inject_script instead
    
    Reference #826
---
 .../src/main/royale/hljs.as                        | 17 +++++++++++-----
 examples/jewel/TourDeJewel/src/main/royale/hljs.as | 16 ++++++++++-----
 .../jewel/royale-website/src/main/royale/hljs.as   | 22 +++++++++++++++------
 .../royale-website/src/main/royale/markdownit.as   |  8 +++++---
 .../main/royale/org/apache/royale/ace/ACEEditor.as |  8 +++++---
 .../org/apache/royale/utils/CompressionUtils.as    | 12 ++++++-----
 .../org/apache/royale/createjs/Application.as      | 16 +++++++++------
 .../royale/org/apache/royale/fa/FontAwesomeIcon.as | 10 +++++++---
 .../org/apache/royale/icons/FontAwesomeIcon.as     | 10 +++++++---
 .../royale/org/apache/royale/icons/MaterialIcon.as | 10 +++++++---
 .../royale/org/apache/royale/jquery/Application.as | 23 ++++++++++++++--------
 .../Jewel/src/main/royale/dialogPolyfill.as        | 14 +++++++++----
 .../apache/royale/jewel/beads/views/TabBarView.as  |  8 +++++---
 .../mx/rpc/remoting/CompressedRemoteObject.as      |  8 +++++---
 .../mx/rpc/remoting/mxml/CompressedRemoteObject.as |  8 +++++---
 .../main/royale/org/apache/royale/mdl/Dialog.as    | 14 +++++++++----
 .../org/apache/royale/cordova/Application.as       | 17 ++++++++++------
 .../apache/royale/net/CompressedRemoteObject.as    |  8 +++++---
 18 files changed, 153 insertions(+), 76 deletions(-)

diff --git 
a/examples/blog/BE0012_Using_external_javascript_libraries_in_Apache_Royale/src/main/royale/hljs.as
 
b/examples/blog/BE0012_Using_external_javascript_libraries_in_Apache_Royale/src/main/royale/hljs.as
index 131a897..1a045c7 100644
--- 
a/examples/blog/BE0012_Using_external_javascript_libraries_in_Apache_Royale/src/main/royale/hljs.as
+++ 
b/examples/blog/BE0012_Using_external_javascript_libraries_in_Apache_Royale/src/main/royale/hljs.as
@@ -25,13 +25,20 @@ package
        public class hljs
        {
                /** 
-         * <inject_html>
-                * <script 
src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.12.0/highlight.min.js";></script>
-         * <link rel="stylesheet" title="Atom One Dark" 
href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.12.0/styles/atom-one-dark.min.css";>
-                * </inject_html>
+         * <inject_script>
+                * var script = document.createElement("script");
+                * script.setAttribute("src", 
"https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.12.0/highlight.min.js";);
+                * document.head.appendChild(script);
+         * var link = document.createElement("link");
+         * link.setAttribute("rel", "stylesheet");
+         * link.setAttribute("title", "Atom One Dark");
+         * link.setAttribute("type", "text/css");
+         * link.setAttribute("href", 
"https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.12.0/styles/atom-one-dark.min.css";);
+         * document.head.appendChild(link);
+                * </inject_script>
                 */
                public function hljs(){}
 
                public static function highlightBlock(block:Element):void {}
        }
-}
\ No newline at end of file
+}
diff --git a/examples/jewel/TourDeJewel/src/main/royale/hljs.as 
b/examples/jewel/TourDeJewel/src/main/royale/hljs.as
index 131a897..92d4c98 100644
--- a/examples/jewel/TourDeJewel/src/main/royale/hljs.as
+++ b/examples/jewel/TourDeJewel/src/main/royale/hljs.as
@@ -25,13 +25,19 @@ package
        public class hljs
        {
                /** 
-         * <inject_html>
-                * <script 
src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.12.0/highlight.min.js";></script>
-         * <link rel="stylesheet" title="Atom One Dark" 
href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.12.0/styles/atom-one-dark.min.css";>
-                * </inject_html>
+         * <inject_script>
+                * var script = document.createElement("script");
+                * script.setAttribute("src", 
"https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.12.0/highlight.min.js";);
+                * document.head.appendChild(script);
+         * var link = document.createElement("link");
+         * link.setAttribute("rel", "stylesheet");
+         * link.setAttribute("type", "text/css");
+         * link.setAttribute("href", 
"https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.12.0/styles/atom-one-dark.min.css";);
+         * document.head.appendChild(link);
+                * </inject_script>
                 */
                public function hljs(){}
 
                public static function highlightBlock(block:Element):void {}
        }
-}
\ No newline at end of file
+}
diff --git a/examples/jewel/royale-website/src/main/royale/hljs.as 
b/examples/jewel/royale-website/src/main/royale/hljs.as
index 06bbdff..3b6c39a 100644
--- a/examples/jewel/royale-website/src/main/royale/hljs.as
+++ b/examples/jewel/royale-website/src/main/royale/hljs.as
@@ -25,12 +25,22 @@ package
        public class hljs
        {
                /** 
-         * <inject_html>
-                * <script 
src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.18.1/highlight.min.js";></script>
-                * <script 
src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.18.1/languages/actionscript.min.js";></script>
-                * <script 
src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.18.1/languages/xml.min.js";></script>
-         * <link rel="stylesheet" title="Atom One Dark" 
href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.12.0/styles/atom-one-dark.min.css";>
-                * </inject_html>
+         * <inject_script>
+                * var script = document.createElement("script");
+                * script.setAttribute("src", 
"https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.18.1/highlight.min.js";);
+                * document.head.appendChild(script);
+                * script = document.createElement("script");
+                * script.setAttribute("src", 
"https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.18.1/languages/actionscript.min.js";);
+                * document.head.appendChild(script);
+                * script = document.createElement("script");
+                * script.setAttribute("src", 
"https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.18.1/languages/xml.min.js";);
+                * document.head.appendChild(script);
+         * var link = document.createElement("link");
+         * link.setAttribute("rel", "stylesheet");
+         * link.setAttribute("type", "text/css");
+         * link.setAttribute("href", 
"https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.12.0/styles/atom-one-dark.min.css";);
+         * document.head.appendChild(link);
+                * </inject_script>
                 */
                public function hljs(){}
 
diff --git a/examples/jewel/royale-website/src/main/royale/markdownit.as 
b/examples/jewel/royale-website/src/main/royale/markdownit.as
index 22aa676..306a6c2 100644
--- a/examples/jewel/royale-website/src/main/royale/markdownit.as
+++ b/examples/jewel/royale-website/src/main/royale/markdownit.as
@@ -28,9 +28,11 @@ package
        {
                /**
                 * 
-         * <inject_html>
-                * <script 
src="https://cdnjs.cloudflare.com/ajax/libs/markdown-it/10.0.0/markdown-it.min.js";></script>
-                * </inject_html>
+         * <inject_script>
+                * var script = document.createElement("script");
+                * script.setAttribute("src", 
"https://cdnjs.cloudflare.com/ajax/libs/markdown-it/10.0.0/markdown-it.min.js";);
+                * document.head.appendChild(script);
+                * </inject_script>
                 * 
                 * @param presetName String, MarkdownIt provides named presets 
as a convenience to quickly enable/disable active syntax rules and options for 
common use cases.
                 * 
diff --git 
a/frameworks/projects/Ace/src/main/royale/org/apache/royale/ace/ACEEditor.as 
b/frameworks/projects/Ace/src/main/royale/org/apache/royale/ace/ACEEditor.as
index 3f42ad2..3aab373 100644
--- a/frameworks/projects/Ace/src/main/royale/org/apache/royale/ace/ACEEditor.as
+++ b/frameworks/projects/Ace/src/main/royale/org/apache/royale/ace/ACEEditor.as
@@ -34,9 +34,11 @@ package org.apache.royale.ace
        public class ACEEditor extends org.apache.royale.core.UIBase
        {
                /**
-                * <inject_html>
-                * <script 
src="https://cdnjs.cloudflare.com/ajax/libs/ace/1.4.6/ace.js";></script>
-                * </inject_html>
+                * <inject_script>
+                * var script = document.createElement("script");
+                * script.setAttribute("src", 
"https://cdnjs.cloudflare.com/ajax/libs/ace/1.4.6/ace.js";);
+                * document.head.appendChild(script);
+                * </inject_script>
                 */
                public function ACEEditor()
                {
diff --git 
a/frameworks/projects/Core/src/main/royale/org/apache/royale/utils/CompressionUtils.as
 
b/frameworks/projects/Core/src/main/royale/org/apache/royale/utils/CompressionUtils.as
index ab5e319..943bcc5 100644
--- 
a/frameworks/projects/Core/src/main/royale/org/apache/royale/utils/CompressionUtils.as
+++ 
b/frameworks/projects/Core/src/main/royale/org/apache/royale/utils/CompressionUtils.as
@@ -27,12 +27,14 @@ package org.apache.royale.utils
        public class CompressionUtils
        {
         /**
-         * The Royale Compiler will inject html into the index.html file.  
Surround with
-         * "inject_html" tag as follows:
+         * The Royale Compiler will inject a script into the index.html file.  
Surround with
+         * "inject_script" tag as follows:
          *
-         * <inject_html>
-         * <script 
src="https://cdnjs.cloudflare.com/ajax/libs/pako/1.0.3/pako.min.js";></script>
-         * </inject_html>
+         * <inject_script>
+         * var script = document.createElement("script");
+         * script.setAttribute("src", 
"https://cdnjs.cloudflare.com/ajax/libs/pako/1.0.3/pako.min.js";);
+         * document.head.appendChild(script);
+         * </inject_script>
                 * 
          *  Constructor.
          *  
diff --git 
a/frameworks/projects/CreateJS/src/main/royale/org/apache/royale/createjs/Application.as
 
b/frameworks/projects/CreateJS/src/main/royale/org/apache/royale/createjs/Application.as
index 9c20159..8990499 100644
--- 
a/frameworks/projects/CreateJS/src/main/royale/org/apache/royale/createjs/Application.as
+++ 
b/frameworks/projects/CreateJS/src/main/royale/org/apache/royale/createjs/Application.as
@@ -101,7 +101,7 @@ package org.apache.royale.createjs
         * 
      * This is the CreateJS Application class which must be used in place of 
the normal
         * Royale Application. CreateJS uses the HTML5 &lt;canvas&gt;, rather 
than the HTML DOM. This
-        * class sets up the canvas and injects the necessary HTML elements 
into the index.html
+        * class sets up the canvas and injects the necessary script elements 
into the index.html
         * file to bootstrap CreateJS.
         *
         *  @see ViewBase
@@ -172,12 +172,16 @@ package org.apache.royale.createjs
        {
         /**
          * The Royale Compiler will inject html into the index.html file.  
Surround with
-         * "inject_html" tag as follows:
+         * "inject_script" tag as follows:
          *
-         * <inject_html>
-         * <script 
src="https://code.createjs.com/easeljs-0.8.1.min.js";></script>
-                * <script 
src="https://code.createjs.com/tweenjs-0.6.2.min.js";></script>
-         * </inject_html>
+         * <inject_script>
+         * var script = document.createElement("script");
+         * script.setAttribute("src", 
"https://code.createjs.com/easeljs-0.8.1.min.js";);
+         * document.head.appendChild(script);
+        * script = document.createElement("script");
+        * script.setAttribute("src", 
"https://code.createjs.com/tweenjs-0.6.2.min.js";);
+        * document.head.appendChild(script);
+         * </inject_script>
          */
                public function Application()
                {
diff --git 
a/frameworks/projects/FontAwesome/src/main/royale/org/apache/royale/fa/FontAwesomeIcon.as
 
b/frameworks/projects/FontAwesome/src/main/royale/org/apache/royale/fa/FontAwesomeIcon.as
index e886f33..9edc9b7 100644
--- 
a/frameworks/projects/FontAwesome/src/main/royale/org/apache/royale/fa/FontAwesomeIcon.as
+++ 
b/frameworks/projects/FontAwesome/src/main/royale/org/apache/royale/fa/FontAwesomeIcon.as
@@ -48,9 +48,13 @@ package org.apache.royale.fa
          *  @productversion Royale 0.0
          *
          *  @royaleignorecoercion HTMLElement
-                * <inject_html>
-                *     <link rel="stylesheet" 
href="http://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css";>
-                * </inject_html>                
+                * <inject_script>
+                *     var link = document.createElement("link");
+                *     link.setAttribute("rel", "stylesheet");
+                *     link.setAttribute("type", "text/css");
+                *     link.setAttribute("href", 
"http://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css";);
+                *     document.head.appendChild(link);
+                * </inject_script>              
          */
         public function FontAwesomeIcon()
         {
diff --git 
a/frameworks/projects/Icons/src/main/royale/org/apache/royale/icons/FontAwesomeIcon.as
 
b/frameworks/projects/Icons/src/main/royale/org/apache/royale/icons/FontAwesomeIcon.as
index da6d4b9..74cba36 100644
--- 
a/frameworks/projects/Icons/src/main/royale/org/apache/royale/icons/FontAwesomeIcon.as
+++ 
b/frameworks/projects/Icons/src/main/royale/org/apache/royale/icons/FontAwesomeIcon.as
@@ -51,9 +51,13 @@ package org.apache.royale.icons
         /**
          *  constructor.
          * 
-         *  <inject_html>
-         *   <link rel="stylesheet" 
href="https://pro.fontawesome.com/releases/v5.13.0/css/all.css"; 
crossorigin="anonymous"/>
-            *  </inject_html>
+         *  <inject_script>
+         *   var link = document.createElement("link");
+         *   link.setAttribute("rel", "stylesheet");
+         *   link.setAttribute("type", "text/css");
+         *   link.setAttribute("href", 
"https://pro.fontawesome.com/releases/v5.13.0/css/all.css";);
+         *   document.head.appendChild(link);
+            *  </inject_script>
          *
          *  @langversion 3.0
          *  @playerversion Flash 10.2
diff --git 
a/frameworks/projects/Icons/src/main/royale/org/apache/royale/icons/MaterialIcon.as
 
b/frameworks/projects/Icons/src/main/royale/org/apache/royale/icons/MaterialIcon.as
index 03debea..24f949f 100644
--- 
a/frameworks/projects/Icons/src/main/royale/org/apache/royale/icons/MaterialIcon.as
+++ 
b/frameworks/projects/Icons/src/main/royale/org/apache/royale/icons/MaterialIcon.as
@@ -33,9 +33,13 @@ package org.apache.royale.icons
         /**
          *  constructor.
          * 
-         *  <inject_html>
-         *  <link rel="stylesheet" 
href="https://fonts.googleapis.com/icon?family=Material+Icons";>
-         *  </inject_html>
+         *  <inject_script>
+         *  var link = document.createElement("link");
+         *  link.setAttribute("rel", "stylesheet");
+         *  link.setAttribute("type", "text/css");
+         *  link.setAttribute("href", 
"https://fonts.googleapis.com/icon?family=Material+Icons";);
+         *  document.head.appendChild(link);
+         *  </inject_script>
          *
          *  @langversion 3.0
          *  @playerversion Flash 10.2
diff --git 
a/frameworks/projects/JQuery/src/main/royale/org/apache/royale/jquery/Application.as
 
b/frameworks/projects/JQuery/src/main/royale/org/apache/royale/jquery/Application.as
index 023ed08..16c1f3c 100644
--- 
a/frameworks/projects/JQuery/src/main/royale/org/apache/royale/jquery/Application.as
+++ 
b/frameworks/projects/JQuery/src/main/royale/org/apache/royale/jquery/Application.as
@@ -25,15 +25,22 @@ package org.apache.royale.jquery
        public class Application extends org.apache.royale.core.Application 
implements IFlexInfo
        {
                /**
-                * The Royale Compiler will inject html into the index.html 
file.  Surround with
-                * "inject_html" tag as follows:
+                * The Royale Compiler will inject script elements into the 
index.html file.  Surround with
+                * "inject_script" tag as follows:
                 *
-                * <inject_html>
-                * <link rel="stylesheet"
-                * 
href="http://code.jquery.com/ui/1.10.2/themes/smoothness/jquery-ui.css"; />
-                * <script 
src="http://code.jquery.com/jquery-1.9.1.js";></script>
-                * <script 
src="http://code.jquery.com/ui/1.10.2/jquery-ui.js";></script>
-                * </inject_html>
+                * <inject_script>
+                * var link = document.createElement("link");
+                * link.setAttribute("rel", "stylesheet");
+                * link.setAttribute("type", "text/css");
+                * link.setAttribute("href", 
"http://code.jquery.com/ui/1.10.2/themes/smoothness/jquery-ui.css";);
+                * document.head.appendChild(link);
+                * var script = document.createElement("script");
+                * script.setAttribute("src", 
"http://code.jquery.com/jquery-1.9.1.js";);
+                * document.head.appendChild(script);
+                * script = document.createElement("script");
+                * script.setAttribute("src", 
"http://code.jquery.com/ui/1.10.2/jquery-ui.js";);
+                * document.head.appendChild(script);
+                * </inject_script>
                 */
                public function Application()
                {
diff --git a/frameworks/projects/Jewel/src/main/royale/dialogPolyfill.as 
b/frameworks/projects/Jewel/src/main/royale/dialogPolyfill.as
index c1c9408..190f9f2 100644
--- a/frameworks/projects/Jewel/src/main/royale/dialogPolyfill.as
+++ b/frameworks/projects/Jewel/src/main/royale/dialogPolyfill.as
@@ -25,10 +25,16 @@ package
        public class dialogPolyfill
        {
                /** 
-         * <inject_html>
-         * <script 
src="https://cdnjs.cloudflare.com/ajax/libs/dialog-polyfill/0.4.9/dialog-polyfill.min.js";></script>
-         * <link rel="stylesheet" type="text/css" 
href="https://cdnjs.cloudflare.com/ajax/libs/dialog-polyfill/0.4.9/dialog-polyfill.min.css";>
-         * </inject_html>
+         * <inject_script>
+         * var script = document.createElement("script");
+         * script.setAttribute("src", 
"https://cdnjs.cloudflare.com/ajax/libs/dialog-polyfill/0.4.9/dialog-polyfill.min.js";);
+         * document.head.appendChild(script)
+         *  var link = document.createElement("link");
+         *  link.setAttribute("rel", "stylesheet");
+         *  link.setAttribute("type", "text/css");
+         *  link.setAttribute("href", 
"https://cdnjs.cloudflare.com/ajax/libs/dialog-polyfill/0.4.9/dialog-polyfill.min.css";);
+         *  document.head.appendChild(link);
+         * </inject_script>
                 */
                public function dialogPolyfill(){}
                 
diff --git 
a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/beads/views/TabBarView.as
 
b/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/beads/views/TabBarView.as
index 2173162..a2b0834 100644
--- 
a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/beads/views/TabBarView.as
+++ 
b/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/beads/views/TabBarView.as
@@ -42,9 +42,11 @@ package org.apache.royale.jewel.beads.views
                /**
                 *  constructor.
                 *
-                *  <inject_html>
-                *  <script 
src="https://cdnjs.cloudflare.com/ajax/libs/web-animations/2.3.1/web-animations.min.js";></script>
-                *  </inject_html>
+                *  <inject_script>
+                *  var script = document.createElement("script");
+                *  script.setAttribute("src", 
"https://cdnjs.cloudflare.com/ajax/libs/web-animations/2.3.1/web-animations.min.js";);
+                *  document.head.appendChild(script);
+                *  </inject_script>
                 * 
                 *  @langversion 3.0
                 *  @playerversion Flash 10.2
diff --git 
a/frameworks/projects/MXRoyale/src/main/royale/mx/rpc/remoting/CompressedRemoteObject.as
 
b/frameworks/projects/MXRoyale/src/main/royale/mx/rpc/remoting/CompressedRemoteObject.as
index 55ffe1b..05415a8 100644
--- 
a/frameworks/projects/MXRoyale/src/main/royale/mx/rpc/remoting/CompressedRemoteObject.as
+++ 
b/frameworks/projects/MXRoyale/src/main/royale/mx/rpc/remoting/CompressedRemoteObject.as
@@ -85,9 +85,11 @@ package mx.rpc.remoting
         /**
          * Uses the pako library for the zlib compression algorithm
          *
-         * <inject_html>
-         * <script 
src="https://cdnjs.cloudflare.com/ajax/libs/pako/1.0.6/pako.min.js";></script>
-         * </inject_html>
+         * <inject_script>
+         * var script = document.createElement("script");
+         * script.setAttribute("src", 
"https://cdnjs.cloudflare.com/ajax/libs/pako/1.0.6/pako.min.js";);
+         * document.head.appendChild(script);
+         * </inject_script>
          */
         public function CompressedRemoteObject(destination:String = null)
         {
diff --git 
a/frameworks/projects/MXRoyale/src/main/royale/mx/rpc/remoting/mxml/CompressedRemoteObject.as
 
b/frameworks/projects/MXRoyale/src/main/royale/mx/rpc/remoting/mxml/CompressedRemoteObject.as
index 07c9923..5c50636 100644
--- 
a/frameworks/projects/MXRoyale/src/main/royale/mx/rpc/remoting/mxml/CompressedRemoteObject.as
+++ 
b/frameworks/projects/MXRoyale/src/main/royale/mx/rpc/remoting/mxml/CompressedRemoteObject.as
@@ -85,9 +85,11 @@ package mx.rpc.remoting.mxml
         /**
          * Uses the pako library for the zlib compression algorithm
          *
-         * <inject_html>
-         * <script 
src="https://cdnjs.cloudflare.com/ajax/libs/pako/1.0.6/pako.min.js";></script>
-         * </inject_html>
+         * <inject_script>
+         * var script = document.createElement("script");
+         * script.setAttribute("src", 
"https://cdnjs.cloudflare.com/ajax/libs/pako/1.0.6/pako.min.js";);
+         * document.head.appendChild(script);
+         * </inject_script>
          */
         public function CompressedRemoteObject(destination:String = null)
         {
diff --git 
a/frameworks/projects/MaterialDesignLite/src/main/royale/org/apache/royale/mdl/Dialog.as
 
b/frameworks/projects/MaterialDesignLite/src/main/royale/org/apache/royale/mdl/Dialog.as
index 5e9f1e1..4b537c8 100644
--- 
a/frameworks/projects/MaterialDesignLite/src/main/royale/org/apache/royale/mdl/Dialog.as
+++ 
b/frameworks/projects/MaterialDesignLite/src/main/royale/org/apache/royale/mdl/Dialog.as
@@ -52,10 +52,16 @@ package org.apache.royale.mdl
                /**
                 *  constructor.
          *
-         *  <inject_html>
-         *  <link rel="stylesheet" type="text/css" 
href="https://cdnjs.cloudflare.com/ajax/libs/dialog-polyfill/0.4.9/dialog-polyfill.min.css";>
-         *  <script 
src="https://cdnjs.cloudflare.com/ajax/libs/dialog-polyfill/0.4.9/dialog-polyfill.min.js";></script>
-         *  </inject_html>
+         *  <inject_script>
+         *  var link = document.createElement("link");
+         *  link.setAttribute("rel", "stylesheet");
+         *  link.setAttribute("type", "text/css");
+         *  link.setAttribute("href", 
"https://cdnjs.cloudflare.com/ajax/libs/dialog-polyfill/0.4.9/dialog-polyfill.min.css";);
+         *  document.head.appendChild(link);
+         *  var script = document.createElement("script");
+         *  script.setAttribute("src", 
"https://cdnjs.cloudflare.com/ajax/libs/dialog-polyfill/0.4.9/dialog-polyfill.min.js";);
+         *  document.head.appendChild(script);
+         *  </inject_script>
                 *
                 *  @langversion 3.0
                 *  @playerversion Flash 10.2
diff --git 
a/frameworks/projects/Mobile/src/main/royale/org/apache/royale/cordova/Application.as
 
b/frameworks/projects/Mobile/src/main/royale/org/apache/royale/cordova/Application.as
index 708f668..2cd6abd 100644
--- 
a/frameworks/projects/Mobile/src/main/royale/org/apache/royale/cordova/Application.as
+++ 
b/frameworks/projects/Mobile/src/main/royale/org/apache/royale/cordova/Application.as
@@ -33,13 +33,18 @@ package org.apache.royale.cordova
        public class Application extends org.apache.royale.core.AirApplication 
implements IFlexInfo
        {
                /**
-                * The Royale Compiler will inject html into the index.html 
file.  Surround with
-                * "inject_html" tag as follows:
+                * The Royale Compiler will inject script elements into the 
index.html file.  Surround with
+                * "inject_script" tag as follows:
                 *
-                * <inject_html>
-                * <meta name="viewport" content="width=device-width, 
initial-scale=1.0, maximum-scale=1.0, user-scalable=0">
-                * <script type="text/javascript" src="cordova.js"></script>
-                * </inject_html>
+                * <inject_script>
+                * var meta = document.createElement("meta");
+                * meta.setAttribute("name", "viewport");
+                * meta.setAttribute("content", "width=device-width, 
initial-scale=1.0, maximum-scale=1.0, user-scalable=0");
+                * document.head.appendChild(meta);
+                * var script = document.createElement("script");
+                * script.setAttribute("src", "cordova.js");
+                * document.head.appendChild(script);
+                * </inject_script>
                 */
                public function Application()
                {
diff --git 
a/frameworks/projects/Network/src/main/royale/org/apache/royale/net/CompressedRemoteObject.as
 
b/frameworks/projects/Network/src/main/royale/org/apache/royale/net/CompressedRemoteObject.as
index 64a5313..c0d2f3f 100644
--- 
a/frameworks/projects/Network/src/main/royale/org/apache/royale/net/CompressedRemoteObject.as
+++ 
b/frameworks/projects/Network/src/main/royale/org/apache/royale/net/CompressedRemoteObject.as
@@ -38,9 +38,11 @@ package org.apache.royale.net
         /**
          * Uses the pako library for the zlib compression algorithm
          *
-         * <inject_html>
-         * <script 
src="https://cdnjs.cloudflare.com/ajax/libs/pako/1.0.6/pako.min.js";></script>
-         * </inject_html>
+         * <inject_script>
+         * var script = document.createElement("script");
+         * script.setAttribute("src", 
"https://cdnjs.cloudflare.com/ajax/libs/pako/1.0.6/pako.min.js";);
+         * document.head.appendChild(script);
+         * </inject_script>
          */
         public function CompressedRemoteObject()
         {

Reply via email to