WIP (do not review): panel support3

This is a branch which gets things working on a panel for Firefox 28, but leaves things in a sidebar for 27. 

Once <https://bugzilla.mozilla.org/show_bug.cgi?id=935640> lands in nightly, there's a good chance this patch will be ready to land, though it's possible that that fix will surface new problems in our code.

Alternately, it's conceivable that <https://bugzilla.mozilla.org/show_bug.cgi?id=940494> will land in 27 (or even 28?) first, in which case this might also be able to land, with some logic tweaks.