hoping to get around new chrome versus remote xul restrictions
authorphasefx <phasefx@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Wed, 12 May 2010 17:48:34 +0000 (17:48 +0000)
committerphasefx <phasefx@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Wed, 12 May 2010 17:48:34 +0000 (17:48 +0000)
git-svn-id: svn://svn.open-ils.org/ILS/trunk@16420 dcc99617-32d9-48b4-a31d-7c20da2025e4

Open-ILS/xul/staff_client/chrome/content/util/browser.js

index e540d56..8a11792 100644 (file)
@@ -281,7 +281,17 @@ util.browser.prototype = {
                                 if (typeof obj.on_url_load == 'function') {
                                     try {
                                         obj.error.sdump('D_TRACE','calling on_url_load');
-                                        obj.on_url_load( obj.controller.view.browser_browser );
+                                        var helpers = {
+                                            'doc_write' : function(html) {
+                                                netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect");
+                                                obj.get_content().document.write(html);
+                                            },
+                                            'doc_close' : function() {
+                                                netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect");
+                                                obj.get_content().document.close();
+                                            }
+                                        }
+                                        obj.on_url_load( obj.controller.view.browser_browser, obj, helpers );
                                     } catch(E) {
                                         obj.error.sdump('D_ERROR','on_url_load: ' + E );
                                     }