[ascoders] AW: OOP
- From: "Jursa, Jan (init)" <Jan.Jursa@xxxxxxx>
- To: "'ascoders@xxxxxxxxxxxxx'" <ascoders@xxxxxxxxxxxxx>
- Date: Thu, 30 Oct 2003 10:19:49 +0100
moin moin,
schreibs doch einfach beim Object mit rein, oder?
Object.prototype.getStage = function() {
this.width = this._width;
this.height = this._height;
this.x = this._x;
this.y = this._y;
this.left = this._x;
this.right = this._x+this.width;
this.halfwidth = this.width/2;
trace(this.halfwidth);
};
//--
myTextfield_txt.getStage();
grüsse,
jan
-----Ursprüngliche Nachricht-----
Von: Peter Oliver Geller [mailto:nc-gellerpe@xxxxxxxxxxxxx]
Gesendet: Donnerstag, 30. Oktober 2003 09:45
An: ascoders@xxxxxxxxxxxxx
Betreff: [ascoders] OOP
Schönen guten Morgen,
ist es eigentlich möglich diese Methode an Textfelder zu übergeben?
MovieClip.prototype.getStage = function(){
this.width = this._width;
this.height = this._height;
this.x = this._x;
this.y = this._y;
this.left = this._x;
this.right = this._x + this.width;
this.halfwidth = this.width/2;
}
z.B.
TextField.prototype = MovieClip.prototype;
oder
TextField.__proto__ = MovieClip.prototype;
Peter
------------------------------------------------------
Archiv : http://www.freelists.org/archives/ascoders/
Optionen : http://www.freelists.org/list/ascoders
------------------------------------------------------
------------------------------------------------------
Archiv : http://www.freelists.org/archives/ascoders/
Optionen : http://www.freelists.org/list/ascoders
------------------------------------------------------
Other related posts: