Why my protocol handler registered cannot trigger chrome app's url_handlers directly?

95 views
Skip to first unread message

lisongl...@gmail.com

unread,
Jun 27, 2014, 3:49:22 AM6/27/14
to google-chrome-...@googlegroups.com

To launch my chrome app, I set a url_handlers in the manifest.json as below:

  "url_handlers": {
    "view": {
      "matches": [
        "http://test.view.com/start.html*"
      ],
      "title": "view"
    }
  }

So now when I open the link "http://test.view.com/start.html*", the chrome app can be started successfully. Then I register protocol handler to create my own url schema as below:

var url = "http://test.songli.com/start.html?data=%s";
window.navigator.registerProtocolHandler("web+view", url, "Test");

Here comes the question. When I open the link "web+view:data", the browser can open "http://test.view.com/start.html?data=blahblah". However, my chrome app cannot be started this time. Only after refreshing the page, app can be opened. In fact, what I want is to open my chrome app directly by open the link "web+view:data". Is there something wrong in this way?

PhistucK

unread,
Jun 27, 2014, 7:11:59 AM6/27/14
to Google Chrome Developer Tools
This is unrelated to the Developer Tools feature of Chrome.
You can either ask this at chromium-apps, or find an existing issue at crbug.com and if you cannot find one, create one, as it seems like a forgotten edge case.


PhistucK


--
You received this message because you are subscribed to the Google Groups "Google Chrome Developer Tools" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-chrome-develo...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-chrome-developer-tools/27108184-b17b-4e39-8107-740e187fedee%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

lisongl...@gmail.com

unread,
Jun 29, 2014, 10:34:17 PM6/29/14
to google-chrome-...@googlegroups.com
Thanks for your advise!


On Friday, June 27, 2014 7:11:59 PM UTC+8, PhistucK wrote:
This is unrelated to the Developer Tools feature of Chrome.
You can either ask this at chromium-apps, or find an existing issue at crbug.com and if you cannot find one, create one, as it seems like a forgotten edge case.


PhistucK


On Fri, Jun 27, 2014 at 10:49 AM, <lisongl...@gmail.com> wrote:

To launch my chrome app, I set a url_handlers in the manifest.json as below:

  "url_handlers": {
    "view": {
      "matches": [
        "http://test.view.com/start.html*"
      ],
      "title": "view"
    }
  }

So now when I open the link "http://test.view.com/start.html*", the chrome app can be started successfully. Then I register protocol handler to create my own url schema as below:

var url = "http://test.songli.com/start.html?data=%s";
window.navigator.registerProtocolHandler("web+view", url, "Test");

Here comes the question. When I open the link "web+view:data", the browser can open "http://test.view.com/start.html?data=blahblah". However, my chrome app cannot be started this time. Only after refreshing the page, app can be opened. In fact, what I want is to open my chrome app directly by open the link "web+view:data". Is there something wrong in this way?

--
You received this message because you are subscribed to the Google Groups "Google Chrome Developer Tools" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-chrome-developer-tools+unsub...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages