mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 1254960 - Back out bug 1219804. r=mak a=ritu l10n=ritu
This commit is contained in:
parent
052d9ab0c1
commit
9c5b19c948
@ -451,10 +451,6 @@
|
||||
class="show-only-for-keyboard"
|
||||
command="Browser:BookmarkAllTabs"
|
||||
key="bookmarkAllTabsKb"/>
|
||||
<menuseparator/>
|
||||
<menuitem label="&recentBookmarks.label;"
|
||||
id="menu_recentBookmarks"
|
||||
disabled="true"/>
|
||||
<menuseparator id="bookmarksToolbarSeparator"/>
|
||||
<menu id="bookmarksToolbarFolderMenu"
|
||||
class="menu-iconic bookmark-item"
|
||||
|
@ -1328,9 +1328,6 @@ var BookmarkingUI = {
|
||||
return;
|
||||
}
|
||||
|
||||
this._updateRecentBookmarks(document.getElementById("BMB_recentBookmarks"),
|
||||
"subviewbutton");
|
||||
|
||||
if (!this._popupNeedsUpdate)
|
||||
return;
|
||||
this._popupNeedsUpdate = false;
|
||||
@ -1364,54 +1361,6 @@ var BookmarkingUI = {
|
||||
});
|
||||
},
|
||||
|
||||
_updateRecentBookmarks: function(aHeaderItem, extraCSSClass = "") {
|
||||
const kMaxResults = 5;
|
||||
|
||||
let options = PlacesUtils.history.getNewQueryOptions();
|
||||
options.excludeQueries = true;
|
||||
options.queryType = options.QUERY_TYPE_BOOKMARKS;
|
||||
options.sortingMode = options.SORT_BY_DATEADDED_DESCENDING;
|
||||
options.maxResults = kMaxResults;
|
||||
let query = PlacesUtils.history.getNewQuery();
|
||||
|
||||
while (aHeaderItem.nextSibling &&
|
||||
aHeaderItem.nextSibling.localName == "menuitem") {
|
||||
aHeaderItem.nextSibling.remove();
|
||||
}
|
||||
|
||||
let onItemCommand = function (aEvent) {
|
||||
let item = aEvent.target;
|
||||
openUILink(item.getAttribute("targetURI"), aEvent);
|
||||
CustomizableUI.hidePanelForNode(item);
|
||||
};
|
||||
|
||||
let fragment = document.createDocumentFragment();
|
||||
let root = PlacesUtils.history.executeQuery(query, options).root;
|
||||
root.containerOpen = true;
|
||||
for (let i = 0; i < root.childCount; i++) {
|
||||
let node = root.getChild(i);
|
||||
let uri = node.uri;
|
||||
let title = node.title;
|
||||
let icon = node.icon;
|
||||
|
||||
let item =
|
||||
document.createElementNS("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul",
|
||||
"menuitem");
|
||||
item.setAttribute("label", title || uri);
|
||||
item.setAttribute("targetURI", uri);
|
||||
item.setAttribute("class", "menuitem-iconic menuitem-with-favicon bookmark-item " +
|
||||
extraCSSClass);
|
||||
item.addEventListener("command", onItemCommand);
|
||||
if (icon) {
|
||||
let iconURL = "moz-anno:favicon:" + icon;
|
||||
item.setAttribute("image", iconURL);
|
||||
}
|
||||
fragment.appendChild(item);
|
||||
}
|
||||
root.containerOpen = false;
|
||||
aHeaderItem.parentNode.insertBefore(fragment, aHeaderItem.nextSibling);
|
||||
},
|
||||
|
||||
/**
|
||||
* Handles star styling based on page proxy state changes.
|
||||
*/
|
||||
@ -1628,7 +1577,6 @@ var BookmarkingUI = {
|
||||
|
||||
this._updateBookmarkPageMenuItem();
|
||||
PlacesCommandHook.updateBookmarkAllTabsCommand();
|
||||
this._updateRecentBookmarks(document.getElementById("menu_recentBookmarks"));
|
||||
},
|
||||
|
||||
_showBookmarkedNotification: function BUI_showBookmarkedNotification() {
|
||||
|
@ -808,11 +808,6 @@
|
||||
command="Browser:ShowAllBookmarks"
|
||||
key="manBookmarkKb"/>
|
||||
<menuseparator/>
|
||||
<menuitem label="&recentBookmarks.label;"
|
||||
id="BMB_recentBookmarks"
|
||||
disabled="true"
|
||||
class="subviewbutton"/>
|
||||
<menuseparator/>
|
||||
<menu id="BMB_bookmarksToolbar"
|
||||
class="menu-iconic bookmark-item subviewbutton"
|
||||
label="&personalbarCmd.label;"
|
||||
|
@ -168,7 +168,6 @@ These should match what Safari and other Apple applications use on OS X Lion. --
|
||||
<!ENTITY subscribeToPageMenuitem.label "Subscribe to This Page…">
|
||||
<!ENTITY addCurPagesCmd.label "Bookmark All Tabs…">
|
||||
<!ENTITY showAllBookmarks2.label "Show All Bookmarks">
|
||||
<!ENTITY recentBookmarks.label "Recently Bookmarked">
|
||||
<!ENTITY unsortedBookmarksCmd.label "Unsorted Bookmarks">
|
||||
<!ENTITY bookmarksToolbarChevron.tooltip "Show more bookmarks">
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user