зеркало из https://github.com/mozilla/pjs.git
Quick fix for bug 199619. Cannot create new bookmark folders in "Manage Bookmarks"
r=pch, sr=jag, a=asa
This commit is contained in:
Родитель
fa0d045479
Коммит
b43c5c6180
|
@ -755,6 +755,9 @@ var BookmarksController = {
|
|||
|
||||
isCommandEnabled: function (aCommand, aSelection, aTarget)
|
||||
{
|
||||
if (aTarget.parent.Value == "NC:BookmarksTopRoot")
|
||||
return false;
|
||||
|
||||
var item0, type0;
|
||||
var length = aSelection.length;
|
||||
if (length != 0) {
|
||||
|
|
|
@ -28,8 +28,8 @@ function Startup()
|
|||
{
|
||||
const windowNode = document.getElementById("bookmark-window");
|
||||
const bookmarksView = document.getElementById("bookmarks-view");
|
||||
bookmarksView.treeBoxObject.selection.select(0);
|
||||
|
||||
var rowIndex = 0;
|
||||
var titleString;
|
||||
|
||||
// If we've been opened with a parameter, root the tree on it.
|
||||
|
@ -54,8 +54,13 @@ function Startup()
|
|||
// always open the bookmark top root folder
|
||||
if (!bookmarksView.treeBoxObject.view.isContainerOpen(0))
|
||||
bookmarksView.treeBoxObject.view.toggleOpenState(0);
|
||||
if (!bookmarksView.treeBoxObject.view.isContainerEmpty(0))
|
||||
rowIndex = 1;
|
||||
}
|
||||
|
||||
bookmarksView.treeBoxObject.scrollToRow(rowIndex);
|
||||
bookmarksView.treeBoxObject.selection.select(rowIndex);
|
||||
|
||||
windowNode.setAttribute("title", titleString);
|
||||
|
||||
gBMtxmgr = BookmarksUtils.getTransactionManager();
|
||||
|
|
|
@ -321,8 +321,6 @@
|
|||
<body><![CDATA[
|
||||
var tree = document.getAnonymousElementByAttribute(this, "anonid", "bookmarks-tree");
|
||||
var rootURI = tree.ref;
|
||||
if (rootURI == "NC:BookmarksTopRoot")
|
||||
rootURI = "NC:BookmarksRoot";
|
||||
return RDF.GetResource(rootURI);
|
||||
]]></body>
|
||||
</method>
|
||||
|
|
Загрузка…
Ссылка в новой задаче