Closed Bug 374417 Opened 18 years ago Closed 18 years ago

Disable "Use as Dock menu" CM item for the History collection

Categories

(Camino Graveyard :: Bookmarks, defect)

PowerPC
macOS
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED
Camino1.5

People

(Reporter: alqahira, Assigned: froodian)

Details

(Keywords: fixed1.8.1.4, polish)

Attachments

(1 file, 1 obsolete file)

The collection context menu includes a "Use as Dock menu" item, which is valid for every collection except History (since History items aren't bookmarks). We should disable this context menu item in the collection context menu when the History collection is selected.
...or maybe we should enable users to get at their history through the Dock menu instead? Either way, we need to do something about it.
Attached patch Patch 1 (obsolete) — Splinter Review
This does comment 0.
Assignee: nobody → stridey
Status: NEW → ASSIGNED
Attachment #258972 - Flags: review?(murph)
cl, you should probably file another history/bookmarks parity bug on comment 1, because it'll be more than re-arranging a few lines of code ;) Rearranging lines now gets us to stop misbehaving immediately.
Comment on attachment 258972 [details] [diff] [review] Patch 1 Looks good, r=me with two details to consider (neither of them really necessary, though): > + if (!(aFolder == [[BookmarkManager sharedBookmarkManager] historyFolder])) { This could be expressed as… if (aFolder != [[BookmarkManager sharedBookmarkManager] historyFolder]) { …which seems to make the condition slightly more obvious at first glance. No big deal though, especially if other code in the project tends to follow the first approach; either way evaluates correctly. In the collections contextual menu, a separator item is added whenever there are more items underneath "New Collection." In the patch, this separator is added within the "if aFolder != historyFolder" block of code. This causes no trouble now, since the only other candidate for addition is the "Delete" item, which is also left out for history. My point here is that if we ever decide to introduce another contextual menu item, one that is applicable to the history collection, there won't be a separator item above it.
Attachment #258972 - Flags: review?(murph) → review+
Attached patch r=murph patchSplinter Review
(In reply to comment #4) > This could be expressed as… > > if (aFolder != [[BookmarkManager sharedBookmarkManager] historyFolder]) { Yes, that's far less insane. > In the collections contextual menu, a separator item is added whenever there > are more items underneath "New Collection." In the patch, this separator is > added within the "if aFolder != historyFolder" block of code. This causes no > trouble now, since the only other candidate for addition is the "Delete" item, > which is also left out for history. My point here is that if we ever decide to > introduce another contextual menu item, one that is applicable to the history > collection, there won't be a separator item above it. I personally don't think this is really a concern at this point - if other options are added at a later point, new logic for adding the separator will make itself apparent (and relevant). There's also plenty of precedent for adding separators programatically in this way. I've left that logic as it is for now.
Attachment #258972 - Attachment is obsolete: true
Attachment #259016 - Flags: superreview?(stuart.morgan)
Comment on attachment 259016 [details] [diff] [review] r=murph patch sr=smorgan
Attachment #259016 - Flags: superreview?(stuart.morgan) → superreview+
Checked in on trunk and MOZILLA_1_8_BRANCH.
Status: ASSIGNED → RESOLVED
Closed: 18 years ago
Keywords: fixed1.8.1.4
Resolution: --- → FIXED
Target Milestone: --- → Camino1.1
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: