summaryrefslogtreecommitdiff
path: root/toolkit/content/widgets
diff options
context:
space:
mode:
authorMoonchild <moonchild@palemoon.org>2021-05-06 09:24:03 +0000
committerMoonchild <moonchild@palemoon.org>2021-05-06 09:24:03 +0000
commit6f707bde95dab6998ac204f9ee6c925ee230c740 (patch)
tree859f6cf99f2e026b76dcc40b27b211154310d16e /toolkit/content/widgets
parentaa0fd3d68c856504646e1d7eb499bc890ef44101 (diff)
downloaduxp-6f707bde95dab6998ac204f9ee6c925ee230c740.tar.gz
Issue #1751 -- Remove XP_MACOSX conditionals from the rest of the tree.
This also removes some PP abuse and takes file entries out of PP when no longer needed without XP_MACOSX conditionals.
Diffstat (limited to 'toolkit/content/widgets')
-rw-r--r--toolkit/content/widgets/dialog.xml4
-rw-r--r--toolkit/content/widgets/findbar.xml33
-rw-r--r--toolkit/content/widgets/optionsDialog.xml11
-rw-r--r--toolkit/content/widgets/preferences.xml4
-rw-r--r--toolkit/content/widgets/tree.xml6
-rw-r--r--toolkit/content/widgets/wizard.xml49
6 files changed, 2 insertions, 105 deletions
diff --git a/toolkit/content/widgets/dialog.xml b/toolkit/content/widgets/dialog.xml
index d83570ac0f..aff1621965 100644
--- a/toolkit/content/widgets/dialog.xml
+++ b/toolkit/content/widgets/dialog.xml
@@ -422,15 +422,11 @@
if (!event.defaultPrevented)
this.cancelDialog();
</handler>
-#ifdef XP_MACOSX
- <handler event="keypress" key="." modifiers="meta" phase="capturing" action="this.cancelDialog();"/>
-#else
<handler event="focus" phase="capturing">
var btn = this.getButton(this.defaultButton);
if (btn)
btn.setAttribute("default", event.originalTarget == btn || !(event.originalTarget instanceof Components.interfaces.nsIDOMXULButtonElement));
</handler>
-#endif
</handlers>
</binding>
diff --git a/toolkit/content/widgets/findbar.xml b/toolkit/content/widgets/findbar.xml
index c312a6a25a..aae799554d 100644
--- a/toolkit/content/widgets/findbar.xml
+++ b/toolkit/content/widgets/findbar.xml
@@ -1232,39 +1232,6 @@
]]></body>
</method>
-#ifdef XP_MACOSX
- <!--
- - Fetches the currently selected text and sets that as the text to search
- - next. This is a MacOS specific feature.
- -->
- <method name="onFindSelectionCommand">
- <body><![CDATA[
- let searchString = this.browser.finder.setSearchStringToSelection();
- if (searchString)
- this._findField.value = searchString;
- ]]></body>
- </method>
-
- <method name="_onFindFieldFocus">
- <body><![CDATA[
- let prefsvc = this._prefsvc;
- const kPref = "accessibility.typeaheadfind.prefillwithselection";
- if (this.prefillWithSelection && prefsvc.getBoolPref(kPref))
- return;
-
- let clipboardSearchString = this._browser.finder.clipboardSearchString;
- if (clipboardSearchString && this._findField.value != clipboardSearchString &&
- !this._findField._willfullyDeleted) {
- this._findField.value = clipboardSearchString;
- this._findField._hadValue = true;
- // Changing the search string makes the previous status invalid, so
- // we better clear it here.
- this._updateStatusUI();
- }
- ]]></body>
- </method>
-#endif
-
<!--
- This handles all the result changes for both
- type-ahead-find and highlighting.
diff --git a/toolkit/content/widgets/optionsDialog.xml b/toolkit/content/widgets/optionsDialog.xml
index f0cdba62f2..efd20663e5 100644
--- a/toolkit/content/widgets/optionsDialog.xml
+++ b/toolkit/content/widgets/optionsDialog.xml
@@ -11,7 +11,6 @@
<binding id="optionsDialog"
extends="chrome://global/content/bindings/dialog.xml#dialog">
<content>
-#ifndef XP_MACOSX
<xul:hbox flex="1">
<xul:categoryBox anonid="prefsCategories">
<children/>
@@ -21,16 +20,6 @@
<xul:iframe anonid="panelFrame" name="panelFrame" style="width: 0px;" flex="1"/>
</xul:vbox>
</xul:hbox>
-#else
- <xul:vbox flex="1">
- <xul:categoryBox anonid="prefsCategories">
- <children/>
- </xul:categoryBox>
- <xul:vbox flex="1">
- <xul:iframe anonid="panelFrame" name="panelFrame" style="width: 0px;" flex="1"/>
- </xul:vbox>
- </xul:vbox>
-#endif
</content>
<implementation>
diff --git a/toolkit/content/widgets/preferences.xml b/toolkit/content/widgets/preferences.xml
index 11de032462..f7cb109488 100644
--- a/toolkit/content/widgets/preferences.xml
+++ b/toolkit/content/widgets/preferences.xml
@@ -1146,11 +1146,7 @@
</handler>
<handler event="keypress"
-#ifdef XP_MACOSX
- key="&openHelpMac.commandkey;" modifiers="accel"
-#else
keycode="&openHelp.commandkey;"
-#endif
phase="capturing">
<![CDATA[
var helpButton = this.getButton("help");
diff --git a/toolkit/content/widgets/tree.xml b/toolkit/content/widgets/tree.xml
index aa17172575..19a1fa7727 100644
--- a/toolkit/content/widgets/tree.xml
+++ b/toolkit/content/widgets/tree.xml
@@ -79,11 +79,11 @@
<property name="treeBoxObject"
onget="return this.boxObject;"
readonly="true"/>
-# contentView is obsolete (see bug 202391)
+<!-- contentView is obsolete (see bug 202391) -->
<property name="contentView"
onget="return this.view; /*.QueryInterface(Components.interfaces.nsITreeContentView)*/"
readonly="true"/>
-# builderView is obsolete (see bug 202393)
+<!-- builderView is obsolete (see bug 202393) -->
<property name="builderView"
onget="return this.view; /*.QueryInterface(Components.interfaces.nsIXULTreeBuilder)*/"
readonly="true"/>
@@ -774,7 +774,6 @@
event.preventDefault();
}
</handler>
-#ifndef XP_MACOSX
<!-- Use F2 key to enter text editing. -->
<handler event="keydown" keycode="VK_F2">
<![CDATA[
@@ -786,7 +785,6 @@
event.preventDefault();
]]>
</handler>
-#endif // XP_MACOSX
<handler event="keydown" keycode="VK_ESCAPE">
<![CDATA[
diff --git a/toolkit/content/widgets/wizard.xml b/toolkit/content/widgets/wizard.xml
index 3a8ec2cfef..eb812f0652 100644
--- a/toolkit/content/widgets/wizard.xml
+++ b/toolkit/content/widgets/wizard.xml
@@ -465,54 +465,6 @@
</implementation>
</binding>
-#ifdef XP_MACOSX
- <binding id="wizard-header" extends="chrome://global/content/bindings/wizard.xml#wizard-base">
- <content>
- <xul:stack class="wizard-header-stack" flex="1">
- <xul:vbox class="wizard-header-box-1">
- <xul:vbox class="wizard-header-box-text">
- <xul:label class="wizard-header-label" xbl:inherits="xbl:text=label"/>
- </xul:vbox>
- </xul:vbox>
- <xul:hbox class="wizard-header-box-icon">
- <xul:spacer flex="1"/>
- <xul:image class="wizard-header-icon" xbl:inherits="src=iconsrc"/>
- </xul:hbox>
- </xul:stack>
- </content>
- </binding>
-
- <binding id="wizard-buttons" extends="chrome://global/content/bindings/wizard.xml#wizard-base">
- <content>
- <xul:vbox flex="1">
- <xul:hbox class="wizard-buttons-btm">
- <xul:button class="wizard-button" dlgtype="extra1" hidden="true"/>
- <xul:button class="wizard-button" dlgtype="extra2" hidden="true"/>
- <xul:button label="&button-cancel-mac.label;" class="wizard-button" dlgtype="cancel"/>
- <xul:spacer flex="1"/>
- <xul:button label="&button-back-mac.label;" accesskey="&button-back-mac.accesskey;"
- class="wizard-button wizard-nav-button" dlgtype="back"/>
- <xul:button label="&button-next-mac.label;" accesskey="&button-next-mac.accesskey;"
- class="wizard-button wizard-nav-button" dlgtype="next"
- default="true" xbl:inherits="hidden=lastpage" />
- <xul:button label="&button-finish-mac.label;" class="wizard-button"
- dlgtype="finish" default="true" xbl:inherits="hidden=hidefinishbutton" />
- </xul:hbox>
- </xul:vbox>
- </content>
-
- <implementation>
- <method name="onPageChange">
- <body><![CDATA[
- this.setAttribute("hidefinishbutton", !(this.getAttribute("lastpage") == "true"));
- ]]></body>
- </method>
- </implementation>
-
- </binding>
-
-#else
-
<binding id="wizard-header" extends="chrome://global/content/bindings/wizard.xml#wizard-base">
<content>
<xul:hbox class="wizard-header-box-1" flex="1">
@@ -602,6 +554,5 @@
</property>
</implementation>
</binding>
-#endif
</bindings>