Bug 330807 - Places Organizer desn't show URL in its status bar. r=sspitzer.

This commit is contained in:
mozilla.mano%sent.com 2006-12-26 20:35:05 +00:00
Родитель 3bb82d5fd9
Коммит de398fc100
3 изменённых файлов: 24 добавлений и 2 удалений

Просмотреть файл

@ -272,6 +272,24 @@ var PlacesOrganizer = {
getService(Ci.nsINavBookmarksService);
bms.exportBookmarksHTML(fp.file);
}
},
updateStatusBarForView: function G_updateStatusBarForView(aView) {
var statusText = "";
var selectedNode = aView.selectedNode;
if (selectedNode) {
if (PlacesUtils.nodeIsFolder(selectedNode)) {
var strings = document.getElementById("placeBundle");
var childsCount =
PlacesUtils.getFolderContents(asFolder(selectedNode).folderId)
.childCount;
statusText = strings.getFormattedString("status_foldercount",
[childsCount]);
}
else if (PlacesUtils.nodeIsBookmark(selectedNode))
statusText = selectedNode.uri;
}
document.getElementById("status").label = statusText;
}
};

Просмотреть файл

@ -296,7 +296,8 @@
<tree id="placesList" class="placesTree" type="places"
place="place:&amp;folder=1&amp;group=3&amp;excludeItems=1"
hidecolumnpicker="true" context="placesContext"
onselect="PlacesOrganizer.onPlaceSelected(true);"
onselect="PlacesOrganizer.onPlaceSelected(true);
PlacesOrganizer.updateStatusBarForView(this);"
onclick="PlacesOrganizer.onTreeClick(event);"
seltype="single">
<treecols>
@ -338,7 +339,8 @@
<tree id="placeContent" class="placesTree" context="placesContext"
flex="1" type="places"
ondblclick="this.controller.openSelectedNodeWithEvent(event);"
onclick="PlacesOrganizer.onTreeClick(event);">
onclick="PlacesOrganizer.onTreeClick(event);"
onselect="PlacesOrganizer.updateStatusBarForView(this);">
<treecols id="placeContentColumns">
<treecol label="&col.title.label;" id="title" flex="5" primary="true"
persist="width hidden ordinal sortActive sortDirection"/>

Просмотреть файл

@ -72,3 +72,5 @@ tabs.openWarningTitle=Confirm open
tabs.openWarningMultipleBranded=You are about to open %S tabs. This might slow down %S while the pages are loading. Are you sure you want to continue?
tabs.openButtonMultiple=Open tabs
tabs.openWarningPromptMeBranded=Warn me when opening multiple tabs might slow down %S
status_foldercount = %S object(s)