Преглед на файлове

#31 - jquery.touch.js was removed because it was not working, some other solution for touch devices is needed

Alex Trofimov преди 12 години
родител
ревизия
34d640e6d0
променени са 3 файла, в които са добавени 1 реда и са изтрити 73 реда
  1. 0 70
      inc/js/jquery.touch.js
  2. 0 1
      studio/template/scripts/BxBaseStudioBuilderPage.php
  3. 1 2
      studio/template/scripts/BxBaseStudioLauncher.php

+ 0 - 70
inc/js/jquery.touch.js

@@ -1,70 +0,0 @@
-/*
- * Content-Type:text/javascript
- *
- * A bridge between iPad and iPhone touch events and jquery draggable, 
- * sortable etc. mouse interactions.
- * @author Oleg Slobodskoi  
- * 
- * modified by John Hardy to use with any touch device
- * fixed breakage caused by jquery.ui so that mouseHandled internal flag is reset 
- * before each touchStart event
- * 
- */
-(function( $ ) {
-
-    $.support.touch = typeof Touch === 'object';
-
-    if (!$.support.touch) {
-        return;
-    }
-
-    var proto =  $.ui.mouse.prototype,
-    _mouseInit = proto._mouseInit;
-
-    $.extend( proto, {
-        _mouseInit: function() {
-            this.element
-            .bind( "touchstart." + this.widgetName, $.proxy( this, "_touchStart" ) );
-            _mouseInit.apply( this, arguments );
-        },
-
-        _touchStart: function( event ) {
-            if ( event.originalEvent.targetTouches.length != 1 ) {
-                return false;
-            }
-
-            this.element
-            .bind( "touchmove." + this.widgetName, $.proxy( this, "_touchMove" ) )
-            .bind( "touchend." + this.widgetName, $.proxy( this, "_touchEnd" ) );
-
-            this._modifyEvent( event );
-
-            $( document ).trigger($.Event("mouseup")); //reset mouseHandled flag in ui.mouse
-            this._mouseDown( event );
-
-            return false;           
-        },
-
-        _touchMove: function( event ) {
-            this._modifyEvent( event );
-            this._mouseMove( event );   
-        },
-
-        _touchEnd: function( event ) {
-            this.element
-            .unbind( "touchmove." + this.widgetName )
-            .unbind( "touchend." + this.widgetName );
-            this._mouseUp( event ); 
-        },
-
-        _modifyEvent: function( event ) {
-            event.which = 1;
-            var target = event.originalEvent.targetTouches[0];
-            event.pageX = target.clientX;
-            event.pageY = target.clientY;
-        }
-
-    });
-
-})( jQuery );
-

+ 0 - 1
studio/template/scripts/BxBaseStudioBuilderPage.php

@@ -60,7 +60,6 @@ class BxBaseStudioBuilderPage extends BxDolStudioBuilderPage {
         	'jquery.ui.mouse.min.js',
         	'jquery.ui.sortable.min.js',
         	'jquery.easing.js',
-        	'jquery.touch.js',
             'jquery.form.js',
         	'functions.js',
         	'builder_page.js'

+ 1 - 2
studio/template/scripts/BxBaseStudioLauncher.php

@@ -31,7 +31,6 @@ class BxBaseStudioLauncher extends BxDolStudioLauncher {
         	'jquery.ui.mouse.min.js',
         	'jquery.ui.sortable.min.js',
         	'jquery.easing.js',
-        	'jquery.touch.js',
         	'jquery.cookie.js',
         	'launcher.js'
         );
@@ -65,4 +64,4 @@ class BxBaseStudioLauncher extends BxDolStudioLauncher {
         ));
     }
 }
-/** @} */
+/** @} */