Как в javascript вызвать один метод-прототип в другом методе-прототипе?

Предположим, у меня есть функция:

function test(){}

test.prototype.method01=function(){
    //do something
}

test.prototype.method02=function(){
    //how can I call the method01?
    //this.method01()...?
    //but the chrome through an error:
    //Uncaught TypeError: Object #<HTMLImageElement> has no method 'method01'
}

Отредактировано: на самом деле метод method01 такой:

test.prototype.method02=function(){
    $('.cpy').resizable({

    }).draggable({
        start:function(e,ui){
            this.method01();
        }
    });
}
10
задан hh54188 17 March 2012 в 12:32
поделиться