Browse Source

#2041 Adds showonFocus option to dropdown

pull/2092/head
jlukic 9 years ago
parent
commit
87b3cd08c5
1 changed files with 6 additions and 2 deletions
  1. 8
      src/definitions/modules/dropdown.js

8
src/definitions/modules/dropdown.js

@ -526,7 +526,7 @@ $.fn.dropdown = function(parameters) {
event: { event: {
focus: function() { focus: function() {
if(!activated && module.is.hidden()) {
if(settings.showonFocus && !activated && module.is.hidden()) {
module.show(); module.show();
} }
}, },
@ -558,7 +558,9 @@ $.fn.dropdown = function(parameters) {
search: { search: {
focus: function() { focus: function() {
activated = true; activated = true;
module.show();
if(settings.showOnFocus) {
module.show();
}
}, },
blur: function(event) { blur: function(event) {
var var
@ -2074,6 +2076,8 @@ $.fn.dropdown.settings = {
action : 'activate', action : 'activate',
allowTab : true, allowTab : true,
showOnFocus : true,
fullTextSearch : false, fullTextSearch : false,
preserveHTML : true, preserveHTML : true,
sortSelect : false, sortSelect : false,

Loading…
Cancel
Save