r1000 - trunk/ui
r1000 - trunk/ui
Author: paul.bakaus
Date: Sun Nov 23 10:00:29 2008
New Revision: 1000
Modified:
trunk/ui/ui.core.js
Log:
core (mouse): preventDefault in most cases instead of returning false, that
blocks all bubbling events (fixed #3552)
Modified: trunk/ui/ui.core.js
==============================================================================
--- trunk/ui/ui.core.js (original)
+++ trunk/ui/ui.core.js Sun Nov 23 10:00:29 2008
@@ -462,7 +462,11 @@
.bind('mousemove.'+this.widgetName, this._mouseMoveDelegate)
.bind('mouseup.'+this.widgetName, this._mouseUpDelegate);
- return $.browser.safari; //Fix for safari to allow selecting select
options
+ // preventDefault() is used to prevent the selection of text here -
+ // however, in Safari, this causes select boxes not to be selectable
+ // anymore, so this fix is needed
+ if(!$.browser.safari) event.preventDefault();
+ return true;
},
_mouseMove: function(event) {
@@ -473,7 +477,7 @@
if (this._mouseStarted) {
this._mouseDrag(event);
- return false;
+ return event.preventDefault();
}
if (this._mouseDistanceMet(event) && this._mouseDelayMet(event)) {