I have two functions here
function Preloader() {}
Preloader.prototype = {
init:function() {
// do something
}
}
var preloader = new Preloader();
function Project() {}
Project.prototype = {
init:function() {
// do something else
}
}
var project = new Project();
I want to call project.init() in preloader's init function but obviously
project.init()
doesn't work 'cause there's no project variable in preloader. How should I call it? Thanks!
Projectinstance you wish to callinit()on to thePreloaderinit()function?