The default bug view has changed. See this FAQ.

Add some element IDs to navigator to assist porting of Firefox extensions.

RESOLVED FIXED in seamonkey2.1a1

Status

SeaMonkey
UI Design
--
enhancement
RESOLVED FIXED
7 years ago
7 years ago

People

(Reporter: Philip Chee, Assigned: Philip Chee)

Tracking

Trunk
seamonkey2.1a1

Firefox Tracking Flags

(Not tracked)

Details

(Whiteboard: compat-fx)

Attachments

(1 attachment, 1 obsolete attachment)

11.64 KB, patch
Philip Chee
: review+
Philip Chee
: superreview+
Details | Diff | Splinter Review
(Assignee)

Description

7 years ago
Sync some element IDs from browser.xul to make it easier for Firefox extensions to overlay SeaMonkey.
(Assignee)

Comment 1

7 years ago
Created attachment 419575 [details] [diff] [review]
Patch v1.0

+        <menuitem id="historyMenuUp" 
Firefox doesn't have this menu item, but for consistency I'm adding one to all the menu items in this area.

-        <menuitem label="&historyCmd.label;" accesskey="&historyCmd.accesskey;" oncommand="toHistory()" key="key_gotoHistory"/>
-        <menuseparator hidden="true"/>
+        <menuitem id="menu_showAllHistory"
+                  label="&historyCmd.label;"
+                  accesskey="&historyCmd.accesskey;"
+                  oncommand="toHistory()"
+                  key="key_gotoHistory"/>

+        <menuseparator id="startHistorySeparator" hidden="true"/>
+        <menuseparator id="endHistorySeparator" hidden="true"/>
Several Firefox extensions use insertbefore/insertafter these menuseparators in their overlays.

-          aParent.lastChild.hidden = (count == 0);
If an extension appends a menu item to the Go menu, this logic hides the wrong menu item.

+          var startHistory = document.getElementById("startHistorySeparator");
+          var endHistory = document.getElementById("endHistorySeparator");
+          startHistory.hidden = (count == 0);
+          endHistory.hidden = (endHistory == aParent.lastChild);
Attachment #419575 - Flags: superreview?(neil)
Attachment #419575 - Flags: review?(neil)
(Assignee)

Comment 2

7 years ago
-function createMenuItem( aParent, aIndex, aLabel)
+function createMenuItem(aParent, aIndex, aLabel)

-function createRadioMenuItem( aParent, aIndex, aLabel, aChecked)
+function createRadioMenuItem( aParent, aAnchor, aIndex, aLabel, aChecked)

Aargh. I'll fix these whitespace nits in the next patch after reviews.
(Assignee)

Updated

7 years ago
Duplicate of this bug: 528814

Comment 4

7 years ago
Comment on attachment 419575 [details] [diff] [review]
Patch v1.0

>+                createRadioMenuItem(aParent, endHistory, j, entry.title, j==index);
Speaking of spacing nits, might as well fix the spacing around the ==

>     if (aChecked==true)
And if you're fixing all the spacing anyway, then this can be improved!

Comment 5

7 years ago
Comment on attachment 419575 [details] [diff] [review]
Patch v1.0

Bah, after all that, I forgot to tick the boxes...
Attachment #419575 - Flags: superreview?(neil)
Attachment #419575 - Flags: superreview+
Attachment #419575 - Flags: review?(neil)
Attachment #419575 - Flags: review+
(Assignee)

Comment 6

7 years ago
Created attachment 419830 [details] [diff] [review]
Patch v1.1 Fix whitespace nits. r=neil sr=neil
[Checkin: Comment 8]

> (From update of attachment 419575 [details] [diff] [review])
>>+                createRadioMenuItem(aParent, endHistory, j, entry.title, j==index);
> Speaking of spacing nits, might as well fix the spacing around the ==
Fixed.

>>     if (aChecked==true)
> And if you're fixing all the spacing anyway, then this can be improved!
Fixed. Plus a few more whitespace nits around this line.
Attachment #419575 - Attachment is obsolete: true
Attachment #419830 - Flags: superreview+
Attachment #419830 - Flags: review+
(Assignee)

Comment 7

7 years ago
Interdiff:
<https://bugzilla.mozilla.org/attachment.cgi?oldid=419575&action=interdiff&newid=419830&headers=1>
Keywords: checkin-needed
Comment on attachment 419830 [details] [diff] [review]
Patch v1.1 Fix whitespace nits. r=neil sr=neil
[Checkin: Comment 8]


http://hg.mozilla.org/comm-central/rev/78e022d07edc
Attachment #419830 - Attachment description: [for checkin] Patch v1.1 Fix whitespace nits. r=neil sr=neil → Patch v1.1 Fix whitespace nits [Checkin: Comment 8]
Status: ASSIGNED → RESOLVED
Last Resolved: 7 years ago
Keywords: checkin-needed
Resolution: --- → FIXED
Target Milestone: --- → seamonkey2.1a1
(Assignee)

Updated

7 years ago
Attachment #419830 - Attachment description: Patch v1.1 Fix whitespace nits [Checkin: Comment 8] → Patch v1.1 Fix whitespace nits. r=neil sr=neil [Checkin: Comment 8]
You need to log in before you can comment on or make changes to this bug.