ASPN ActiveState Programmer Network
ActiveState
/ Home / Perl / PHP / Python / Tcl / XSLT /
/ Safari / My ASPN /
Cookbooks | Documentation | Mailing Lists | Modules | News Feeds | Products | User Groups


Recent Messages
List Archives
About the List
List Leaders
Subscription Options

View Subscriptions
Help

View by Topic
ActiveState
.NET Framework
Open Source
Perl
PHP
Python
Tcl
Web Services
XML & XSLT

View by Category
Database
General
SOAP
System Administration
Tools
User Interfaces
Web Programming
XML Programming


MyASPN >> Mail Archive >> pyxpcom
pyxpcom
Re: [pyxpcom] Python ScriptingComponent/PyXPCOMInterprocessCommunication
by Mark Hammond other posts by this author
Jul 10 2007 10:17PM messages near this date
view in the new Beta List Site
Re: [pyxpcom] Python Scripting Component/PyXPCOMInterprocessCommunication | Re: [pyxpcom] Python ScriptingComponent/PyXPCOMInterprocessCommunication
>  Is there a mechanism by which I can selectively expose to him (via
>  the specification of specially crafted locals or globals to exec())
>  a means of accessing functionality in that parent javascript
>  environment.  An example might be, I'd like to allow my user code
>  to exercise the javascript alert() function, or say, change the
>  text of a button in my user interface, or change the window title, etc...

Not currently, no.  Although if the 'document' and 'window' objects are
available, many interesting things can still be done in Python via XPCOM.
Non-XPCOM variables can't be referenced, and even for the XPCOM interfaces,
some functions are implemented in a way that only make sense for JS, and
can't be called by Python.  IIRC, alert() is one example of that.

The work I recently did on 'nsdom' gets us a little closer to that goal -
you can use Python directly in XUL - but I don't think that will appear in
firefox releases for some time.

Mark

_______________________________________________
pyxpcom mailing list
pyxpcom@[...].com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
Thread:
Ryan Sturmer
Mark Hammond
Ryan Sturmer
Mark Hammond
Ryan Sturmer
Mark Hammond
Ryan Sturmer
Mark Hammond
Ryan Sturmer

Privacy Policy | Email Opt-out | Feedback | Syndication
© ActiveState Software Inc. All rights reserved