mirror of
https://github.com/flynx/ImageGrid.git
synced 2025-11-02 04:10:11 +00:00
added 'filtering' CSS class to indicate filtering...
Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
parent
16b10e9bd7
commit
514a14046b
@ -203,6 +203,9 @@
|
||||
float: right;
|
||||
font-size: small;
|
||||
}
|
||||
.browse.filtering .list div:before {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.browse .list div:nth-of-type(1):before {
|
||||
content: "1";
|
||||
|
||||
@ -135,6 +135,7 @@ var BrowserPrototype = {
|
||||
|
||||
// XXX TEST: this should prevent event handler delegation...
|
||||
keyboard: {
|
||||
// XXX should we ignore numbers here???
|
||||
FullPathEdit: {
|
||||
pattern: '.browse .path[contenteditable]',
|
||||
|
||||
@ -153,15 +154,17 @@ var BrowserPrototype = {
|
||||
'A',
|
||||
|
||||
// let the system handle copy paste...
|
||||
'C',
|
||||
'V',
|
||||
'X',
|
||||
'C', 'V', 'X',
|
||||
|
||||
// enter numbers as-is...
|
||||
'#1', '#2', '#3', '#4', '#5', '#6', '#7', '#8', '#9',
|
||||
],
|
||||
|
||||
Enter: 'stopFullPathEdit!',
|
||||
Esc: 'abortFullPathEdit!',
|
||||
},
|
||||
|
||||
// XXX should we have things like ctrl-<number> for fast selection???
|
||||
Filter: {
|
||||
pattern: '.browse .path div.cur[contenteditable]',
|
||||
|
||||
@ -178,9 +181,10 @@ var BrowserPrototype = {
|
||||
'A',
|
||||
|
||||
// let the system handle copy paste...
|
||||
'C',
|
||||
'V',
|
||||
'X',
|
||||
'C', 'V', 'X',
|
||||
|
||||
// enter numbers as-is...
|
||||
'#1', '#2', '#3', '#4', '#5', '#6', '#7', '#8', '#9',
|
||||
],
|
||||
|
||||
Enter: 'action!',
|
||||
@ -339,7 +343,8 @@ var BrowserPrototype = {
|
||||
|
||||
// Indicate if UI in list filtering mode...
|
||||
get filtering(){
|
||||
return this.dom.find('.path .dir.cur[contenteditable]').length > 0
|
||||
return this.dom.hasClass('filtering')
|
||||
//return this.dom.find('.path .dir.cur[contenteditable]').length > 0
|
||||
},
|
||||
|
||||
// Get/set the path...
|
||||
@ -823,6 +828,7 @@ var BrowserPrototype = {
|
||||
var selection = window.getSelection()
|
||||
|
||||
var that = this
|
||||
this.dom.addClass('filtering')
|
||||
var e = this.dom.find('.path .dir.cur')
|
||||
//.text('')
|
||||
.attr('contenteditable', true)
|
||||
@ -839,6 +845,7 @@ var BrowserPrototype = {
|
||||
},
|
||||
stopFilter: function(){
|
||||
this.filterList('*')
|
||||
this.dom.removeClass('filtering')
|
||||
this.dom.find('.path .dir.cur')
|
||||
.text('')
|
||||
.removeAttr('contenteditable')
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user