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

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

commit ab4b08dd41d6c852029888bbdcd1c445c0f65e51
Author: Alex Harui <aha...@apache.org>
AuthorDate: Fri Feb 2 14:56:19 2018 -0800

    try HashBang
---
 examples/royale/ASDoc/src/main/royale/ASDocMainView.mxml              | 2 ++
 examples/royale/ASDoc/src/main/royale/HashAnchorStringItemRenderer.as | 2 +-
 2 files changed, 3 insertions(+), 1 deletion(-)

diff --git a/examples/royale/ASDoc/src/main/royale/ASDocMainView.mxml 
b/examples/royale/ASDoc/src/main/royale/ASDocMainView.mxml
index 0b7f84d..9c82fc3 100644
--- a/examples/royale/ASDoc/src/main/royale/ASDocMainView.mxml
+++ b/examples/royale/ASDoc/src/main/royale/ASDocMainView.mxml
@@ -72,6 +72,8 @@ limitations under the License.
             private function updateView():void
             {
                var hash:String = router.hash;
+               if (hash.substr(0,2) == "#!")
+                 hash = hash.substring(2);
                if (hash.charAt(0) == "#")
                  hash = hash.substring(1);
                if (!hash)
diff --git 
a/examples/royale/ASDoc/src/main/royale/HashAnchorStringItemRenderer.as 
b/examples/royale/ASDoc/src/main/royale/HashAnchorStringItemRenderer.as
index 274c215..6f6dc19 100644
--- a/examples/royale/ASDoc/src/main/royale/HashAnchorStringItemRenderer.as
+++ b/examples/royale/ASDoc/src/main/royale/HashAnchorStringItemRenderer.as
@@ -58,7 +58,7 @@ import  
org.apache.royale.html.supportClasses.StringItemRenderer;
                var href:String = data.href;
                if (!href) // assume package name
                        href = value;
-                this.element.innerHTML = "<a href='#" + href + "' 
class='HashAnchorAnchor'>" + value + "</a>";
+                this.element.innerHTML = "<a href='#!" + href + "' 
class='HashAnchorAnchor'>" + value + "</a>";
             }
                }
 

-- 
To stop receiving notification emails like this one, please contact
aha...@apache.org.

Reply via email to