Window () is a constructor function. This means that it is called when you create a new object with something like
var myWin = new Window();
Inside the function, it thiswill reference the new object that has just been created. (And which is assigned myWinin the above call example.)
As for "element", this is a property of a newly created object. It does not exist before this line:
this.element = document.createElement("div");
Creates a new <div> element and assigns it a DOM representation of this property.
source
share