Permalink
Browse files

Issue #19 - about:facebooktoolbar can now be used if we load the html…

… in a XUL page container. The images and CSS load fine in this context, no security restrictions
  • Loading branch information...
1 parent c385059 commit c8d6e932cbed1d0cdafdb1f2c8d3ba225da6cded @brianking brianking committed Dec 12, 2011
Showing with 17 additions and 6 deletions.
  1. +14 −0 chrome/content/about.xul
  2. +1 −4 chrome/content/toolbar.js
  3. +2 −2 components/about.js
View
@@ -0,0 +1,14 @@
+<?xml version="1.0"?>
+
+<?xml-stylesheet href="chrome://global/skin/" type="text/css"?>
+
+<!DOCTYPE page>
+
+<page id="facebook-about"
+ xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
+
+ <vbox flex="1">
+ <browser src="chrome://facebook/locale/about.html" flex="1"/>
+ </vbox>
+
+</page>
@@ -696,10 +696,7 @@ var facebook = {
aboutpage: function()
{
- // If we load about, the images and styles are not allowed because of security restrictions.
- // Continue to load the chrome url for now.
- //var aPage = "about:facebooktoolbar";
- var aPage = "chrome://facebook/locale/about.html";
+ var aPage = "about:facebooktoolbar";
getBrowser().loadOneTab(aPage, null, null, null, false, false);
},
View
@@ -14,12 +14,12 @@ AboutFBToolbar.prototype = {
QueryInterface: XPCOMUtils.generateQI( [Ci.nsIAboutModule] ),
getURIFlags: function(aURI) {
- return Ci.nsIAboutModule.HIDE_FROM_ABOUTABOUT;
+ return 0;
},
newChannel: function(aURI) {
var ios = Cc["@mozilla.org/network/io-service;1"].getService( Ci.nsIIOService );
- var channel = ios.newChannel( 'chrome://facebook/locale/about.html', null, null );
+ var channel = ios.newChannel( 'chrome://facebook/content/about.xul', null, null );
channel.originalURI = aURI;
return channel;

0 comments on commit c8d6e93

Please sign in to comment.