зеркало из https://github.com/mozilla/snowl.git
fix filtering behavior when deselecting a collection.
This commit is contained in:
Родитель
a05a3c7a79
Коммит
fd323528cc
|
@ -371,9 +371,15 @@ this._log.info("onClick: START itemIds - " +this.itemIds.toSource());
|
|||
|
||||
onSearch: function(aValue) {
|
||||
this.Filters["searchterms"] = aValue ? aValue : null;
|
||||
|
||||
if (this.itemIds == -1 && !aValue)
|
||||
// If no selection and clearing searchbox, clear list (don't select 'All').
|
||||
gMessageViewWindow.SnowlMessageView.onCollectionsDeselect();
|
||||
else
|
||||
// Search selected or 'All Messages' if no explicit selection.
|
||||
gMessageViewWindow.SnowlMessageView.onFilter(this.Filters);
|
||||
if (!aValue)
|
||||
this._tree.place = this._tree.place;
|
||||
// if (!aValue)
|
||||
// this._tree.place = this._tree.place;
|
||||
},
|
||||
|
||||
onCommandUnreadButton: function(aEvent) {
|
||||
|
@ -381,6 +387,11 @@ this._log.info("onClick: START itemIds - " +this.itemIds.toSource());
|
|||
// properties and pseudo element selectors.
|
||||
aEvent.target.checked = !aEvent.target.checked;
|
||||
this.Filters["unread"] = aEvent.target.checked ? true : false;
|
||||
|
||||
if (this.itemIds == -1)
|
||||
// If no selection.
|
||||
return;
|
||||
|
||||
gMessageViewWindow.SnowlMessageView.onFilter(this.Filters);
|
||||
},
|
||||
|
||||
|
@ -393,6 +404,10 @@ this._log.info("onClick: START itemIds - " +this.itemIds.toSource());
|
|||
else
|
||||
document.getElementById("snowlPurgeDeletedButton").setAttribute("disabled", true);
|
||||
|
||||
if (this.itemIds == -1)
|
||||
// If no selection.
|
||||
return;
|
||||
|
||||
gMessageViewWindow.SnowlMessageView.onFilter(this.Filters);
|
||||
},
|
||||
|
||||
|
|
|
@ -2,8 +2,8 @@
|
|||
<!ENTITY unsubscribeButton.tooltip "Unsubscribe from selected message sources.">
|
||||
<!ENTITY refreshButton.tooltip "Refresh all message sources.">
|
||||
<!ENTITY exportButton.tooltip "Export message sources as OPML.">
|
||||
<!ENTITY unreadButton.tooltip "Only show unread messages.">
|
||||
<!ENTITY unreadButton.tooltip "Show unread messages for selected collections.">
|
||||
<!ENTITY listToolbarButton.tooltip "Toggle View toolbar.">
|
||||
<!ENTITY writeButton.tooltip "Write a message.">
|
||||
<!ENTITY showDeletedButton.tooltip "Show deleted messages for selected Collections.">
|
||||
<!ENTITY purgeDeletedButton.tooltip "Purge all deleted messages from selected Collections.">
|
||||
<!ENTITY showDeletedButton.tooltip "Show deleted messages for selected collections.">
|
||||
<!ENTITY purgeDeletedButton.tooltip "Purge all deleted messages from selected collections.">
|
||||
|
|
|
@ -308,6 +308,7 @@ this._log.info("got " + groups.length + " groups");
|
|||
},
|
||||
|
||||
clear: function() {
|
||||
this.constraints = [];
|
||||
this._messages = [];
|
||||
this._messageIndex = {};
|
||||
},
|
||||
|
|
Загрузка…
Ссылка в новой задаче