Browse Source

performance improvements to dropdown

Former-commit-id: 44b1ecdc44
Former-commit-id: 675919b75a
pull/258/head
Jack Lukic 11 years ago
parent
commit
4aa45834f5
7 changed files with 12 additions and 7 deletions
  1. 3
      build/minified/modules/dropdown.js
  2. 2
      build/minified/modules/dropdown.min.js
  3. 3
      build/packaged/modules/dropdown.js
  4. 2
      build/packaged/semantic.min.js.REMOVED.git-id
  5. 3
      build/uncompressed/modules/dropdown.js
  6. 3
      node/src/files/components/semantic/modules/dropdown.js
  7. 3
      src/modules/dropdown.js

3
build/minified/modules/dropdown.js

@ -115,7 +115,7 @@ $.fn.dropdown = function(parameters) {
item: { item: {
click: function () {
click: function (event) {
var var
$choice = $(this), $choice = $(this),
text = $choice.data(metadata.text) || $choice.text(), text = $choice.data(metadata.text) || $choice.text(),
@ -130,6 +130,7 @@ $.fn.dropdown = function(parameters) {
; ;
module.action.determine(text, value); module.action.determine(text, value);
$.proxy(settings.onChange, $menu.get())(text, value); $.proxy(settings.onChange, $menu.get())(text, value);
event.stopPropagation();
} }
} }

2
build/minified/modules/dropdown.min.js
File diff suppressed because it is too large
View File

3
build/packaged/modules/dropdown.js

@ -115,7 +115,7 @@ $.fn.dropdown = function(parameters) {
item: { item: {
click: function () {
click: function (event) {
var var
$choice = $(this), $choice = $(this),
text = $choice.data(metadata.text) || $choice.text(), text = $choice.data(metadata.text) || $choice.text(),
@ -130,6 +130,7 @@ $.fn.dropdown = function(parameters) {
; ;
module.action.determine(text, value); module.action.determine(text, value);
$.proxy(settings.onChange, $menu.get())(text, value); $.proxy(settings.onChange, $menu.get())(text, value);
event.stopPropagation();
} }
} }

2
build/packaged/semantic.min.js.REMOVED.git-id

@ -1 +1 @@
7d3c8b4fe3fb583f87cf300a7c5210b2e18ea1c2
d876032258d1a67275200e157a4230e6f2d8260e

3
build/uncompressed/modules/dropdown.js

@ -115,7 +115,7 @@ $.fn.dropdown = function(parameters) {
item: { item: {
click: function () {
click: function (event) {
var var
$choice = $(this), $choice = $(this),
text = $choice.data(metadata.text) || $choice.text(), text = $choice.data(metadata.text) || $choice.text(),
@ -130,6 +130,7 @@ $.fn.dropdown = function(parameters) {
; ;
module.action.determine(text, value); module.action.determine(text, value);
$.proxy(settings.onChange, $menu.get())(text, value); $.proxy(settings.onChange, $menu.get())(text, value);
event.stopPropagation();
} }
} }

3
node/src/files/components/semantic/modules/dropdown.js

@ -115,7 +115,7 @@ $.fn.dropdown = function(parameters) {
item: { item: {
click: function () {
click: function (event) {
var var
$choice = $(this), $choice = $(this),
text = $choice.data(metadata.text) || $choice.text(), text = $choice.data(metadata.text) || $choice.text(),
@ -130,6 +130,7 @@ $.fn.dropdown = function(parameters) {
; ;
module.action.determine(text, value); module.action.determine(text, value);
$.proxy(settings.onChange, $menu.get())(text, value); $.proxy(settings.onChange, $menu.get())(text, value);
event.stopPropagation();
} }
} }

3
src/modules/dropdown.js

@ -115,7 +115,7 @@ $.fn.dropdown = function(parameters) {
item: { item: {
click: function () {
click: function (event) {
var var
$choice = $(this), $choice = $(this),
text = $choice.data(metadata.text) || $choice.text(), text = $choice.data(metadata.text) || $choice.text(),
@ -130,6 +130,7 @@ $.fn.dropdown = function(parameters) {
; ;
module.action.determine(text, value); module.action.determine(text, value);
$.proxy(settings.onChange, $menu.get())(text, value); $.proxy(settings.onChange, $menu.get())(text, value);
event.stopPropagation();
} }
} }

Loading…
Cancel
Save