From b54df0ddd0c6a0372327c5aa3668e5a6458fcd64 Mon Sep 17 00:00:00 2001 From: st782s Date: Thu, 4 May 2017 07:48:42 -0400 Subject: [PORTAL-7] Rebase This rebasing includes common libraries and common overlays projects abstraction of components Change-Id: I9a24a338665c7cd058978e8636bc412d9e2fdce8 Signed-off-by: st782s --- .../jquery.event.drag-new/event.drop/test/touch.js | 140 --------------------- 1 file changed, 140 deletions(-) delete mode 100644 ecomp-portal-FE/client/bower_components/jquery.event.drag-new/event.drop/test/touch.js (limited to 'ecomp-portal-FE/client/bower_components/jquery.event.drag-new/event.drop/test/touch.js') diff --git a/ecomp-portal-FE/client/bower_components/jquery.event.drag-new/event.drop/test/touch.js b/ecomp-portal-FE/client/bower_components/jquery.event.drag-new/event.drop/test/touch.js deleted file mode 100644 index b28177fc..00000000 --- a/ecomp-portal-FE/client/bower_components/jquery.event.drag-new/event.drop/test/touch.js +++ /dev/null @@ -1,140 +0,0 @@ -;(function(){ - - module("Touch Interaction"); - - if ( !document.createEvent ){ - test("Touch Simulation Not Supported",function(){ - ok( true, 'This browser does not support "document.createEvent" and cannot simulate touch events.'); - }); - return; - } - - // a simple re-usable test harness object - var obj = { - init: function( opts ){ - obj.$drag = $('
') - .css({ - position: 'absolute', - top: 0, - left: 0, - height: 100, - width: 100 - }) - .appendTo( document.body ) - .bind("draginit dragstart drag dragend click", opts || {}, function( event ){ - obj[ event.type ] += 1; - }); - obj.$drop = $('
') - .css({ - position: 'absolute', - top: 0, - left: 0, - height: 100, - width: 100 - }) - .appendTo( document.body ) - .bind("dropinit dropstart drop dropend",function( event ){ - obj[ event.type ] += 1; - }); - $.extend( obj, { - draginit:0, dragstart:0, drag:0, dragend:0, - dropinit:0, dropstart:0, drop:0, dropend:0, - click:0 - }); - }, - touch: function(){ - var start = { - pageX: Math.round( Math.random() * 90 ) + 5, - pageY: Math.round( Math.random() * 90 ) + 5 - }, - end = { - pageX: Math.round( Math.random() * 90 ) + start.pageX, - pageY: Math.round( Math.random() * 90 ) + start.pageY - }; - // simulate a complete mouse drag - obj.$drag - .fire("touchstart", start ) - .fire("touchmove", end ) - .fire("touchend", end ) - .fire("click", end ); - }, - done: function(){ - obj.$drag.remove(); - obj.$drop.remove(); - start(); - } - }; - - asyncTest('Drag and Drop defaults',function(){ - // prep DEFAULT interaction - obj.init(); - // simulate DEFAULT interaction - obj.touch(); - // inspect results - equals( obj.draginit, 1, "draginit"); - equals( obj.dragstart, 1, "dragstart"); - equals( obj.drag, 1, "drag"); - equals( obj.dragend, 1, "dragend"); - equals( obj.dropinit, 1, "dropinit"); - equals( obj.dropstart, 1, "dropstart"); - equals( obj.drop, 1, "drop"); - equals( obj.dropend, 1, "dropend"); - // continue - obj.done(); - }); - - asyncTest('Drag "drop" option (false)',function(){ - // prep interaction - obj.init({ drop:false }); - // simulate drag - obj.touch(); - // inspect results - equals( obj.draginit, 1, "draginit"); - equals( obj.dragstart, 1, "dragstart"); - equals( obj.drag, 1, "drag"); - equals( obj.dragend, 1, "dragend"); - equals( obj.dropinit, 0, "dropinit"); - equals( obj.dropstart, 0, "dropstart"); - equals( obj.drop, 0, "drop"); - equals( obj.dropend, 0, "dropend"); - // continue - obj.done(); - }); - - asyncTest('Drag "drop" option (unmatched)',function(){ - // prep interaction - obj.init({ drop:'body' }); - // simulate drag - obj.touch(); - // inspect results - equals( obj.draginit, 1, "draginit"); - equals( obj.dragstart, 1, "dragstart"); - equals( obj.drag, 1, "drag"); - equals( obj.dragend, 1, "dragend"); - equals( obj.dropinit, 0, "dropinit"); - equals( obj.dropstart, 0, "dropstart"); - equals( obj.drop, 0, "drop"); - equals( obj.dropend, 0, "dropend"); - // continue - obj.done(); - }); - - asyncTest('Drag "drop" option (matched)',function(){ - // prep interaction - obj.init({ drop:'div' }); - // simulate drag - obj.touch(); - // inspect results - equals( obj.draginit, 1, "draginit"); - equals( obj.dragstart, 1, "dragstart"); - equals( obj.drag, 1, "drag"); - equals( obj.dragend, 1, "dragend"); - equals( obj.dropinit, 1, "dropinit"); - equals( obj.dropstart, 1, "dropstart"); - equals( obj.drop, 1, "drop"); - equals( obj.dropend, 1, "dropend"); - // continue - obj.done(); - }); - -})(); \ No newline at end of file -- cgit 1.2.3-korg