Current Web Page not working for Google Chrome Canary

83 views
Skip to first unread message

David Rees

unread,
May 5, 2013, 1:46:37 PM5/5/13
to blacktree-...@googlegroups.com
Current Web Page doesn't seem to be working when Google Chrome Canary is active, instead it gives me the URL from the last Google Chrome window. Is there a trick I am missing?

d

Andreas Johansson

unread,
May 6, 2013, 4:38:02 AM5/6/13
to blacktree-...@googlegroups.com
2013/5/5 David Rees <da...@ubiqsoft.com>
Current Web Page doesn't seem to be working when Google Chrome Canary is active, instead it gives me the URL from the last Google Chrome window. Is there a trick I am missing?

Chrome and Chrome Canary are two different applications, and the Chrome plugin is only compatible with Chrome as it is now. It's on my todo list to fix something for Chrome Canary, but I haven't had time to look at it.

Technically speaking, the Chrome plugin talks to Chrome using Scripting Bridge, which is a low-level equivalent of AppleScript. To talk to Canary, I need to set up a separate interface for Canary, and I think I'll have to essentially build a separate plugin for Canary to make it work properly.

// Andreas 

Rob McBroom

unread,
May 6, 2013, 2:09:31 PM5/6/13
to blacktree-...@googlegroups.com
This is a comment with no research behind it.

I’m assuming the scripting interfaces are identical. I wonder if it’s as simple as calling

[SBApplication applicationWithBundleIdentifier:kQSGoogleChromeBundle]

with Canary’s bundle ID instead. If so, you could add a preference for which to use, or see which one is running, or some combination of the two.

-- 
Rob McBroom
<http://www.skurfer.com/>

Andreas Johansson

unread,
May 7, 2013, 2:51:38 AM5/7/13
to blacktree-...@googlegroups.com
That might be possible, but I figured that since I import the Chrome app specifically I would have to do the same to make it work with Canary. But I guess the Scripting Bridge interface is more dynamic than I thought. 

Anyway, I need to do more changes in the plugin to make it work properly with Canary. The plugin won't be recommended in QS if only Canary is installed (can you set that a plugin depends on app A or app B or both?), and I need to enable right arrow children for Canary.

// Andreas

Rob McBroom

unread,
May 7, 2013, 9:26:19 AM5/7/13
to blacktree-...@googlegroups.com
On May 7, 2013, at 2:51 AM, Andreas Johansson <and...@stdin.se> wrote:

That might be possible, but I figured that since I import the Chrome app specifically I would have to do the same to make it work with Canary. But I guess the Scripting Bridge interface is more dynamic than I thought.

The purpose of importing Chrome is just so you can auto-generate the header file on build. So if that header works for Canary, that should be all you need. (Lately, I’ve taken to just generating the header manually and adding it to the project because having entire applications in there makes “Find in Project” awful. The downside is that you have to manually keep up with changes in the application’s scripting dictionary, but those are pretty rare.)

Anyway, I need to do more changes in the plugin to make it work properly with Canary. The plugin won't be recommended in QS if only Canary is installed (can you set that a plugin depends on app A or app B or both?), and I need to enable right arrow children for Canary.

You can have it recommended for either, but if you list both as a requirement, the plug-in won’t load unless both are present. Maybe a separate fork is the way to go after all. :-)

Andreas Johansson

unread,
May 7, 2013, 10:13:26 AM5/7/13
to blacktree-...@googlegroups.com
2013/5/7 Rob McBroom <mailin...@skurfer.com>
The purpose of importing Chrome is just so you can auto-generate the header file on build. So if that header works for Canary, that should be all you need. (Lately, I’ve taken to just generating the header manually and adding it to the project because having entire applications in there makes “Find in Project” awful. The downside is that you have to manually keep up with changes in the application’s scripting dictionary, but those are pretty rare.)

Good to know. I have just followed the plugin guide, focusing on the actual plugin functionality, so I haven't looked at the stuff surrounding the build process that much.
 
You can have it recommended for either, but if you list both as a requirement, the plug-in won’t load unless both are present. Maybe a separate fork is the way to go after all. :-)

I think I need to do some testing to see which way is the best to go. Having two plugins would be best, but I would like to minimize the amount of duplicated code. If that means splitting the shared functionality into a library or to just add different build targets with Chrome/Canary specific settings I can't really say without actually trying it out.

Anyway, all this talk puts me in problem solving mode :) I have a few days off work this week so I might actually have some time to look at this.

// Andreas

David Rees

unread,
May 7, 2013, 5:51:56 PM5/7/13
to blacktree-...@googlegroups.com
I think the chances of someone having only Canary installed and not Chrome are very slim since Canary is the alpha build. So if you just test for Chrome to install the plugin then use applicationWithBundleIdentifier at runtime to see if Canary is also around then I think you would be good.

d

On 5/6/13 11:51 PM, Andreas Johansson wrote:
That might be possible, but I figured that since I import the Chrome app specifically I would have to do the same to make it work with Canary. But I guess the Scripting Bridge interface is more dynamic than I thought.�

Anyway, I need to do more changes in the plugin to make it work properly with Canary. The plugin won't be recommended in QS if only Canary is installed (can you set that a plugin depends on app A or app B or both?), and I need to enable right arrow children for Canary.

// Andreas
--
You received this message because you are subscribed to a topic in the Google Groups "Quicksilver" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/blacktree-quicksilver/A125UgiLkL8/unsubscribe?hl=en.
To unsubscribe from this group and all its topics, send an email to blacktree-quicks...@googlegroups.com.
To post to this group, send email to blacktree-...@googlegroups.com.
Visit this group at http://groups.google.com/group/blacktree-quicksilver?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
�
�

Andreas Johansson

unread,
May 9, 2013, 4:16:56 AM5/9/13
to blacktree-...@googlegroups.com
It turned out to be easier than I thought to shim in support for Canary. Canary works great with Chrome's SB interface, as Rob suggested.

David, if you want to help me test a version with full support for Canary, you can download a debug version of the plugin here: http://cl.ly/3f043W1Q1f0X. Extract the zip file and open the extracted GoogleChrome.qsplugin file. Please report any bugs in this issue: https://github.com/ndreas/GoogleChrome-qsplugin/issues/4

If everything works (which it seems to do) I'll build a release version for inclusion in QS.

 // Andreas

David Rees

unread,
May 10, 2013, 1:17:39 AM5/10/13
to blacktree-...@googlegroups.com
Very cool! I put comments in the issue.


--
Reply all
Reply to author
Forward
0 new messages