Permalink
Browse files

fixing issue with column drag and drop in IE

Columns native HTML5 Drag and Drop doesn't work in IE.
#187
  • Loading branch information...
igoryan-k committed Jan 11, 2013
1 parent 3f65ee3 commit edf3776e2af46e7395aeb3c512b02d13bcb4551a
Showing with 22 additions and 7 deletions.
  1. +8 −3 build/KoGrid.debug.js
  2. +8 −3 koGrid-2.1.1.debug.js
  3. +1 −1 koGrid-2.1.1.js
  4. +5 −0 src/classes/eventProvider.js
View
@@ -2,7 +2,7 @@
* koGrid JavaScript Library
* Authors: https://github.com/ericmbarnard/koGrid/blob/master/README.md
* License: MIT (http://www.opensource.org/licenses/mit-license.php)
-* Compiled At: 12/19/2012 10:15:47
+* Compiled At: 01/11/2013 15:58:36
***********************************************/
(function (window) {
@@ -659,6 +659,11 @@ window.kg.EventProvider = function (grid) {
self.setDraggables = function(){
if(!grid.config.jqueryUIDraggable){
grid.$root.find('.kgHeaderSortColumn').attr('draggable', 'true');
+ if (navigator.userAgent.indexOf("MSIE") != -1)
+ {
+ //call native IE dragDrop() to start dragging
+ grid.$root.find('.kgHeaderSortColumn').bind('selectstart', function () { this.dragDrop(); return false; });
+ }
} else {
grid.$root.find('.kgHeaderSortColumn').draggable({
helper: 'clone',
@@ -1891,7 +1896,7 @@ window.kg.StyleProvider = function (grid) {
};
/***********************************************
-* FILE: ..\src\classes\SortService.js
+* FILE: ..\src\classes\sortService.js
***********************************************/
window.kg.sortService = {
colSortFnCache: {}, // cache of sorting functions. Once we create them, we don't want to keep re-doing it
@@ -2144,7 +2149,7 @@ window.kg.sortService = {
};
/***********************************************
-* FILE: ..\src\classes\DomUtilityService.js
+* FILE: ..\src\classes\domUtilityService.js
***********************************************/
var getWidths = function () {
var $testContainer = $('<div></div>');
View
@@ -2,7 +2,7 @@
* koGrid JavaScript Library
* Authors: https://github.com/ericmbarnard/koGrid/blob/master/README.md
* License: MIT (http://www.opensource.org/licenses/mit-license.php)
-* Compiled At: 12/19/2012 10:15:47
+* Compiled At: 01/11/2013 15:58:36
***********************************************/
(function (window) {
@@ -659,6 +659,11 @@ window.kg.EventProvider = function (grid) {
self.setDraggables = function(){
if(!grid.config.jqueryUIDraggable){
grid.$root.find('.kgHeaderSortColumn').attr('draggable', 'true');
+ if (navigator.userAgent.indexOf("MSIE") != -1)
+ {
+ //call native IE dragDrop() to start dragging
+ grid.$root.find('.kgHeaderSortColumn').bind('selectstart', function () { this.dragDrop(); return false; });
+ }
} else {
grid.$root.find('.kgHeaderSortColumn').draggable({
helper: 'clone',
@@ -1891,7 +1896,7 @@ window.kg.StyleProvider = function (grid) {
};
/***********************************************
-* FILE: ..\src\classes\SortService.js
+* FILE: ..\src\classes\sortService.js
***********************************************/
window.kg.sortService = {
colSortFnCache: {}, // cache of sorting functions. Once we create them, we don't want to keep re-doing it
@@ -2144,7 +2149,7 @@ window.kg.sortService = {
};
/***********************************************
-* FILE: ..\src\classes\DomUtilityService.js
+* FILE: ..\src\classes\domUtilityService.js
***********************************************/
var getWidths = function () {
var $testContainer = $('<div></div>');
View

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.
@@ -33,6 +33,11 @@ window.kg.EventProvider = function (grid) {
self.setDraggables = function(){
if(!grid.config.jqueryUIDraggable){
grid.$root.find('.kgHeaderSortColumn').attr('draggable', 'true');
+ if (navigator.userAgent.indexOf("MSIE") != -1)
+ {
+ //call native IE dragDrop() to start dragging
+ grid.$root.find('.kgHeaderSortColumn').bind('selectstart', function () { this.dragDrop(); return false; });
+ }
} else {
grid.$root.find('.kgHeaderSortColumn').draggable({
helper: 'clone',

0 comments on commit edf3776

Please sign in to comment.