no more OZ.Class(), dedicated pubsub, std bind
This commit is contained in:
+5
-7
@@ -1,8 +1,6 @@
|
||||
/* --------------------- window ------------ */
|
||||
|
||||
SQL.Window = OZ.Class();
|
||||
|
||||
SQL.Window.prototype.init = function(owner) {
|
||||
SQL.Window = function(owner) {
|
||||
this.owner = owner;
|
||||
this.dom = {
|
||||
container:OZ.$("window"),
|
||||
@@ -16,11 +14,11 @@ SQL.Window.prototype.init = function(owner) {
|
||||
this.dom.ok.value = _("windowok");
|
||||
this.dom.cancel.value = _("windowcancel");
|
||||
this.dom.throbber.alt = this.dom.throbber.title = _("throbber");
|
||||
OZ.Event.add(this.dom.ok, "click", this.bind(this.ok));
|
||||
OZ.Event.add(this.dom.cancel, "click", this.bind(this.close));
|
||||
OZ.Event.add(document, "keydown", this.bind(this.key));
|
||||
OZ.Event.add(this.dom.ok, "click", this.ok.bind(this));
|
||||
OZ.Event.add(this.dom.cancel, "click", this.close.bind(this));
|
||||
OZ.Event.add(document, "keydown", this.key.bind(this));
|
||||
|
||||
this.sync = this.bind(this.sync);
|
||||
this.sync = this.sync.bind(this);
|
||||
|
||||
OZ.Event.add(window, "scroll", this.sync);
|
||||
OZ.Event.add(window, "resize", this.sync);
|
||||
|
||||
Reference in New Issue
Block a user