fx-compat: Mostly fix About pane
Example of converting top-level XUL `<dialog/>` to `<window><dialog/></window>`, which uses a Mozilla-provided `<dialog>` Custom Element
This commit is contained in:
parent
9e9ecc7dcf
commit
b49b8ad140
3 changed files with 11 additions and 10 deletions
|
@ -5,14 +5,14 @@
|
||||||
<?xml-stylesheet href="chrome://zotero-platform/content/zotero-react-client.css" type="text/css"?>
|
<?xml-stylesheet href="chrome://zotero-platform/content/zotero-react-client.css" type="text/css"?>
|
||||||
<!DOCTYPE window SYSTEM "chrome://zotero/locale/about.dtd">
|
<!DOCTYPE window SYSTEM "chrome://zotero/locale/about.dtd">
|
||||||
|
|
||||||
<dialog
|
<window
|
||||||
id="zotero-about"
|
|
||||||
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
|
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
|
||||||
orient="vertical"
|
onload="moveToAlertPosition(); sizeToContent(); document.getElementById('zotero-about').getButton('accept').focus();">
|
||||||
buttons="accept"
|
<dialog
|
||||||
buttonlabelaccept="&zotero.about.close;"
|
id="zotero-about"
|
||||||
onload="moveToAlertPosition(); sizeToContent(); document.documentElement.getButton('accept').focus();"
|
buttons="accept"
|
||||||
ondialogaccept="return true;">
|
buttonlabelaccept="&zotero.about.close;"
|
||||||
|
ondialogaccept="return true;">
|
||||||
|
|
||||||
<script src="include.js"/>
|
<script src="include.js"/>
|
||||||
|
|
||||||
|
@ -83,4 +83,5 @@
|
||||||
</div>
|
</div>
|
||||||
</vbox>
|
</vbox>
|
||||||
</vbox>
|
</vbox>
|
||||||
</dialog>
|
</dialog>
|
||||||
|
</window>
|
|
@ -57,7 +57,7 @@
|
||||||
function openAbout() {
|
function openAbout() {
|
||||||
var ww = Components.classes['@mozilla.org/embedcomp/window-watcher;1']
|
var ww = Components.classes['@mozilla.org/embedcomp/window-watcher;1']
|
||||||
.getService(Components.interfaces.nsIWindowWatcher);
|
.getService(Components.interfaces.nsIWindowWatcher);
|
||||||
ww.openWindow(null, 'chrome://zotero/content/about.xul', 'about', 'chrome,dialog=yes', null);
|
ww.openWindow(null, 'chrome://zotero/content/about.xhtml', 'about', 'chrome,dialog=yes', null);
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
<commandset id="mainCommandSet">
|
<commandset id="mainCommandSet">
|
||||||
|
|
|
@ -5489,7 +5489,7 @@ var ZoteroPane = new function()
|
||||||
* Opens the about dialog
|
* Opens the about dialog
|
||||||
*/
|
*/
|
||||||
this.openAboutDialog = function() {
|
this.openAboutDialog = function() {
|
||||||
window.openDialog('chrome://zotero/content/about.xul', 'about', 'chrome,centerscreen');
|
window.openDialog('chrome://zotero/content/about.xhtml', 'about', 'chrome,centerscreen');
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Reference in a new issue