Ignore:
Timestamp:
2011-08-22T11:08:09+12:00 (13 years ago)
Author:
sjm84
Message:

Moving another modification made to the JQuery UI to gui_div.js

File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/trunk/greenstone3/web/interfaces/oran/js/gui_div.js

    r24420 r24442  
    425425        }
    426426    });
     427   
     428    $.ui.sortable.prototype._removeCurrentsFromItems = function() {
     429        //console.log("IN _removeCurrentsFromItems FUNCTION");
     430        //console.log("this = " + this.currentItem[0].getAttribute('class'));
     431        var list = this.currentItem.find(":data(sortable-item)");
     432
     433        var i = 0;
     434        while (i<this.items.length) {
     435            var found_match = false;
     436            for (var j=0; j<list.length; j++) {
     437                if(this.items[i])
     438                {
     439                    if(list[j] == this.items[i].item[0]) {
     440                        //console.log("Item to splice = " + this.items[i].item[0].getAttribute('class'));
     441                        this.items.splice(i,1);
     442                        found_match = true;
     443                        break;
     444                    }
     445                }
     446            };
     447            if (!found_match)
     448                i++;
     449            else
     450                break;
     451        }
     452    };
    427453   
    428454    $.ui.plugin.add("draggable", "connectToSortable", {
Note: See TracChangeset for help on using the changeset viewer.