Bug 449661 – Use the new search textbox binding in the password manager. r=mconnor
This commit is contained in:
Родитель
c12a1d6b38
Коммит
d27b0a833c
|
@ -54,8 +54,10 @@ function SignonsStartup() {
|
|||
|
||||
// filter the table if requested by caller
|
||||
if (window.arguments && window.arguments[0] &&
|
||||
window.arguments[0].filterString)
|
||||
setFilter(window.arguments[0].filterString);
|
||||
window.arguments[0].filterString) {
|
||||
document.getElementById("filter").value = window.arguments[0].filterString;
|
||||
_filterPasswords();
|
||||
}
|
||||
|
||||
FocusFilterBox();
|
||||
}
|
||||
|
@ -238,8 +240,7 @@ function SignonColumnSort(column) {
|
|||
function SignonClearFilter() {
|
||||
var singleSelection = (signonsTreeView.selection.count == 1);
|
||||
|
||||
// Clear the Filter and the Tree Display
|
||||
document.getElementById("filter").value = "";
|
||||
// Clear the Tree Display
|
||||
signonsTreeView.rowCount = 0;
|
||||
signonsTree.treeBoxObject.rowCountChanged(0, -signonsTreeView._filterSet.length);
|
||||
signonsTreeView._filterSet = [];
|
||||
|
@ -262,14 +263,12 @@ function SignonClearFilter() {
|
|||
signonsTreeView._lastSelectedRanges = [];
|
||||
|
||||
document.getElementById("signonsIntro").value = kSignonBundle.getString("loginsSpielAll");
|
||||
document.getElementById("clearFilter").disabled = true;
|
||||
FocusFilterBox();
|
||||
}
|
||||
|
||||
function FocusFilterBox()
|
||||
{
|
||||
if (document.getElementById("filter").getAttribute("focused") != "true")
|
||||
document.getElementById("filter").focus();
|
||||
function FocusFilterBox() {
|
||||
var filterBox = document.getElementById("filter");
|
||||
if (filterBox.getAttribute("focused") != "true")
|
||||
filterBox.focus();
|
||||
}
|
||||
|
||||
function SignonMatchesFilter(aSignon, aFilterValue) {
|
||||
|
@ -332,18 +331,4 @@ function _filterPasswords()
|
|||
signonsTreeView.selection.select(0);
|
||||
|
||||
document.getElementById("signonsIntro").value = kSignonBundle.getString("loginsSpielFiltered");
|
||||
document.getElementById("clearFilter").disabled = false;
|
||||
}
|
||||
|
||||
function HandleSignonFilterKeyPress(aEvent) {
|
||||
if (aEvent.keyCode == KeyEvent.DOM_VK_ESCAPE &&
|
||||
document.getElementById("filter").value != "")
|
||||
SignonClearFilter();
|
||||
}
|
||||
|
||||
function setFilter(aFilterString) {
|
||||
if (document.getElementById("filter").value != "")
|
||||
SignonClearFilter();
|
||||
document.getElementById("filter").value = aFilterString;
|
||||
_filterPasswords();
|
||||
}
|
||||
|
|
|
@ -69,12 +69,8 @@
|
|||
<!-- filter -->
|
||||
<hbox align="center">
|
||||
<label accesskey="&filter.accesskey;" control="filter">&filter.label;</label>
|
||||
<textbox id="filter" flex="1" type="timed" timeout="500"
|
||||
oncommand="_filterPasswords();"
|
||||
onkeypress="HandleSignonFilterKeyPress(event);"/>
|
||||
<button id="clearFilter" icon="clear" label="&clear.label;"
|
||||
accesskey="&clear.accesskey;"
|
||||
oncommand="SignonClearFilter();" disabled="true"/>
|
||||
<textbox id="filter" flex="1" type="search"
|
||||
oncommand="_filterPasswords();"/>
|
||||
</hbox>
|
||||
|
||||
<description control="signonsTree" id="signonsIntro"/>
|
||||
|
|
|
@ -55,8 +55,6 @@
|
|||
|
||||
<!ENTITY filter.label "Search:">
|
||||
<!ENTITY filter.accesskey "S">
|
||||
<!ENTITY clear.label "Clear">
|
||||
<!ENTITY clear.accesskey "l">
|
||||
|
||||
<!ENTITY windowClose.key "w">
|
||||
<!ENTITY focusSearch1.key "f">
|
||||
|
|
Загрузка…
Ссылка в новой задаче