Author: max
Date: 2007-11-18 18:31:04 -0800 (Sun, 18 Nov 2007)
New Revision: 7314
Modified:
openlaszlo/trunk/WEB-INF/lps/lfc/kernel/dhtml/LzSprite.js
openlaszlo/trunk/lps/includes/source/LzMousewheelKernel.js
Log:
Change 20071118-maxcarlson-Z by [EMAIL PROTECTED] on 2007-11-18 14:20:22 PST
in /Users/maxcarlson/openlaszlo/trunk
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: Fix mousewheel in Safari
New Features:
Bugs Fixed: LPP-4715 - Include a method for attaching event handlers in the
platform javascript
Technical Reviewer: promanik
QA Reviewer: ptw
Doc Reviewer: (pending)
Documentation:
Release Notes:
Details: LzSprite.js - clean up obsolete quirk.
LzMousewheelKernel.js - Use __BrowserDetect instead of quirk - which in
unavailable when running in Flash. Fix event sending to always register for
onmousewheel event - like before r7295.
Tests: http://192.168.1.109:8080/trunk/test/lfc/legals/keyboardandmouse.lzx
shows mousewheel events in Safari OS X. All other browsers supported as well.
Modified: openlaszlo/trunk/WEB-INF/lps/lfc/kernel/dhtml/LzSprite.js
===================================================================
--- openlaszlo/trunk/WEB-INF/lps/lfc/kernel/dhtml/LzSprite.js 2007-11-18
22:23:56 UTC (rev 7313)
+++ openlaszlo/trunk/WEB-INF/lps/lfc/kernel/dhtml/LzSprite.js 2007-11-19
02:31:04 UTC (rev 7314)
@@ -215,7 +215,6 @@
,alt_key_sends_control: false
,safari_textarea_subtract_scrollbar_height: false
,safari_avoid_clip_position_input_text: false
- ,reverse_mouse_wheel: false
,no_cursor_colresize: false
,safari_visibility_instead_of_display: false
,preload_images_only_once: false
@@ -309,8 +308,6 @@
} else if (Lz.__BrowserDetect.isOpera) {
// Fix bug in where if any parent of an image is hidden the size
is 0
this.quirks['invisible_parent_image_sizing_fix'] = true;
- // reverse mouse wheel
- this.quirks['reverse_mouse_wheel'] = true;
this.quirks['no_cursor_colresize'] = true;
this.quirks['absolute_position_accounts_for_offset'] = true;
this.quirks['canvas_div_cannot_be_clipped'] = true;
Modified: openlaszlo/trunk/lps/includes/source/LzMousewheelKernel.js
===================================================================
--- openlaszlo/trunk/lps/includes/source/LzMousewheelKernel.js 2007-11-18
22:23:56 UTC (rev 7313)
+++ openlaszlo/trunk/lps/includes/source/LzMousewheelKernel.js 2007-11-19
02:31:04 UTC (rev 7314)
@@ -4,7 +4,7 @@
var delta = 0;
if (e.wheelDelta) {
delta = e.wheelDelta / 120;
- if (LzSprite.prototype.quirks['reverse_mouse_wheel']) {
+ if (Lz.__BrowserDetect.isOpera) {
delta = -delta;
}
} else if (e.detail) {
@@ -27,9 +27,8 @@
if (LzMousewheelKernel.__callbacks.length == 0 &&
lzOptions.dhtmlKeyboardControl != false) {
if (window.addEventListener) {
Lz.attachEventHandler(window, 'DOMMouseScroll',
LzMousewheelKernel, '__mousewheelEvent');
- } else {
- Lz.attachEventHandler(document, 'mousewheel',
LzMousewheelKernel, '__mousewheelEvent');
}
+ Lz.attachEventHandler(document, 'mousewheel', LzMousewheelKernel,
'__mousewheelEvent');
}
LzMousewheelKernel.__callbacks.push(scope, mousewheelcallback);
//console.log('setCallback', LzMousewheelKernel.__callbacks);
_______________________________________________
Laszlo-checkins mailing list
[email protected]
http://www.openlaszlo.org/mailman/listinfo/laszlo-checkins