Custom Query (18300 matches)


Show under each result:

Results (142 - 144 of 18300)

Ticket Resolution Summary Owner Reporter
#199 fixed Add a 'dojo.lang.bind' to deprecate prototype.js's bind. anonymous [email protected]


We're currently converting from prototype.js to dojo. During refactoring of our code we discovered a possible gap between prototype and dojo for binding functions to a scope. The current implementation of dojo.lang.hitch is:

dojo.lang.hitch = function(obj, meth){

return function(){ return obj[meth].apply(obj, arguments); }


This method is insufficent for binding functions declared as variables to a different scope because it requires that 'meth' be a property of 'obj'.

David Schontzler's idea was to add a method such as dojo.lang.bind that would bind a function to any scope. The logic might look something like:

dojo.lang.bind = function(obj, meth) {

return function() {return meth.apply(obj, arguments);};


We've already tested this code in our conversion and it seems to get the job done.

For your reference, the following is some code where dojo.lang.bind would be useful:

foo.prototype = {

bar: function() {

var url = '../api/foo_bar.php';

var callback = function(type, data, evt) {



url: url, load: dojo.lang.bind(this, callback), method: "get", mimetype: "application/xml"




#202 fixed [patch] Allow drag and drop of table rows alex Sylvain Wallez <[email protected]…>

Here's a patch to allow table rows to be drag'n dropped. This requires adding a surrounding <table> and <tbody> to the <tr>, and setting fixed widths to the <td>s to avoid them being packed.

#203 fixed Iterator bugs in the collection package [email protected] james dot talmage at jrtechnical dot com

Detailed description found in this thread at Dojo-Interest

Note: See TracQuery for help on using queries.