ginebra2/chrome/js/Bind.js
author Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
Tue, 04 May 2010 12:39:35 +0300
changeset 0 1450b09d0cfd
child 3 0954f5dd2cd0
permissions -rw-r--r--
Revision: 201015 Kit: 201018


Function.prototype.bind = function(obj) {
    var method = this,
    temp = function() {
        return method.apply(obj, arguments);
    };
 
    return temp;
} 

function createDelegate(object, method) {
    var shim = function()
        {
            method.apply(object, arguments);
        }

    return shim;
}