>But I think you are in a good idea to explore this avenue. May be
someone >more experienced can explain us SIMPLY what has to be done
>and if this can be done what we need to get as information to start
with.

Well I think it's not so much what needs to get done, as in what people
would like done. Some things, like using Rebol to get a window by name,
would of course require command, and I don't think I could do that. But
most of the browser interaction, whether IE or Mozilla I could handle. 

So here are a list of things:

Click on a link in windows - link can be in IE, link can be in a word
document, excel, open office documents, could be in a htt template for a
folder in the local filesystem found via explorer, etc. This link call
rebol and passes it commands, what kinds of commands should rebol be
able to accept? 
I figure to make this powerful it has to pass info about what
environment the link was clicked in. The window name, the process id,
etc. 

Extending the right click menu in IE and Mozilla:

This is basically a registry hack in IE and if I recall correctly an XUL
hack in mozilla. In IE clicking a right context menu calls a modal
dialogue window, which can be a local html file, depending on registry
settings the  particular page is visible or invisible. If invisible the
page should just be a script. 

I don't have any of the ones I was working on at home so I'll just use
an example extension from google:

If you have the googletoolbar installed you also have a registry entry
something like this:
[HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\MenuExt\&Google
Search]
@="res://c:\\winnt\\downloaded program
files\\GoogleToolbar_en_2.0.95-deleon.dll/cmsearch.html"
"Contexts"=hex:10,00,00,00

res: refers to a html page found as a resource inside of the
GoogleToolbar_en_2.0.95-deleon.dll but it could in fact be a local file,
if instead of the res protocol file: was used

here's a copy of that file:

<html>
<object id=gg align=top
classid="clsid:00EF2092-6AC5-47c0-BD25-CF2D5D657FEB" width=1 height=1
border=0 vspace=0></object>
<script language="JavaScript" defer>
  var parentwin = external.menuArguments;
  var doc = parentwin.document;
  var sel = doc.selection;
  var rng = sel.createRange();
  var strhtml = new String(rng.htmlText);
  var str = strhtml.replace(/<[^>]*>/g," ");
  str = str.replace(/\s+/g, " ");
  str = str.replace(/^\s*/,"");
  str = str.replace(/\s*$/,"");
  if (str.indexOf(" ") != -1)
    str = '"' + str + '"';
  var bnewwindow = external.menuArguments.event.shiftKey;
  var url = "http://www.google.com/search?sourceid=navclient-menuext&q=";
+ escape(str);

  try {
    url = gg.Search(String(str));
    bnewwindow = gg.OpenNewWindow();
  } catch (ex) { }

  if(bnewwindow)
    parentwin.open(url);
  else
    parentwin.navigate(url);
        </script>
</html>

so if we wanted to add in right click on explorer that called rebol and
passed it some info, all we would have to do is to write a javascript
that built up the info we wanted to send and then used location.replace
to call the reb:// protocol and pass the info. 

The technology is pretty simple, what I'm wondering is - what would
people want of such a protocol?




----- Original Message -----
From: "bryan" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, January 06, 2004 5:38 AM
Subject: [REBOL] extending IE with Rebol was RE: Re: Easy-Vid


>
>
>
> >It might just be a question of patents.  Maybe MS has patented
loading
> of >scripts on web pages or something else obscenely vague.
>
> Well no actually Microsoft got sued by eolas:
> http://www.betanews.com/article.php3?sid=1065601616
>
> The desire to have some sort of way of plugging rebol more closely
into
> Windows, especially the protocol architecture as handled via IE, was
the
> reason for the asynchronous pluggable protocol article:
> http://www.devx.com/webdev/Article/17120
> The rebol example in there is pretty trivial (not to mention being
> spaghetti code), but I was hoping that others would have some ideas as
> to how such a protocol should actually work.
>
> If one of the things one wants is to just load .r files the protocol
can
> be used to pass info as to the location of that .r file and then load
> it.
>
> Last night I actually started doing a useful script to run when I call
> reb:// 'addresses', I decided to have it have the structure
>
Reb://password=skjuiquig&gobject=window&oid=1576&oname=IEXPLORE.EXE&load
> =myscript.r&exec=loadwindow http://www.rebol.com
>
> A password would be obligatory, this way the script can keep track of
> links authored locally, and those passed external to the system.
> Depending on what the password and security settings are it would
allow
> one to do specific things.
>
> The gobject parameter refers to various objects recognized by the
script
> that allows it to lock into the system. An object referencing window
> tells you that the script wants to do something to a specific window.
>
> Oid tells you the pid of the object passed (not necessary for each
> object)
> Oname tells you the image name of the object passed.
> Load tells you what scripts to load, probably should be a list.
> And exec tells you what code to execute.
>
> In the example link above I'm thinking that the link tells the script
to
> get the window from which it was called, and to load that window with
> the address www.rebol.com to be able to do stuff like pass an actual
> windows id from IE, I'm extending the right click context menu, so
> unfortunately it can't be 100% rebol.
>
> Anyway, the scenario given above might not be the best way to do
things,
> and it may not be what people want. So other suggestions would be
> welcome.
>
>
>
>
>
>
>
>
> --
> To unsubscribe from this list, just send an email to
> [EMAIL PROTECTED] with unsubscribe as the subject.
>

-- 
To unsubscribe from this list, just send an email to
[EMAIL PROTECTED] with unsubscribe as the subject.


-- 
To unsubscribe from this list, just send an email to
[EMAIL PROTECTED] with unsubscribe as the subject.

Reply via email to