2014-07-13 01:04:16 +02:00
|
|
|
//// [interfaceExtendsClass1.ts]
|
|
|
|
class Control {
|
|
|
|
private state: any;
|
|
|
|
}
|
|
|
|
interface SelectableControl extends Control {
|
|
|
|
select(): void;
|
|
|
|
}
|
|
|
|
class Button extends Control {
|
|
|
|
select() { }
|
|
|
|
}
|
|
|
|
class TextBox extends Control {
|
|
|
|
select() { }
|
|
|
|
}
|
|
|
|
class Image extends Control {
|
|
|
|
}
|
|
|
|
class Location {
|
|
|
|
select() { }
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
//// [interfaceExtendsClass1.js]
|
|
|
|
var __extends = this.__extends || function (d, b) {
|
|
|
|
for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p];
|
|
|
|
function __() { this.constructor = d; }
|
|
|
|
__.prototype = b.prototype;
|
|
|
|
d.prototype = new __();
|
|
|
|
};
|
|
|
|
var Control = (function () {
|
|
|
|
function Control() {
|
|
|
|
}
|
|
|
|
return Control;
|
|
|
|
})();
|
|
|
|
var Button = (function (_super) {
|
|
|
|
__extends(Button, _super);
|
|
|
|
function Button() {
|
|
|
|
_super.apply(this, arguments);
|
|
|
|
}
|
2015-02-07 03:45:09 +01:00
|
|
|
Button.prototype.select = function () { };
|
2014-07-13 01:04:16 +02:00
|
|
|
return Button;
|
|
|
|
})(Control);
|
|
|
|
var TextBox = (function (_super) {
|
|
|
|
__extends(TextBox, _super);
|
|
|
|
function TextBox() {
|
|
|
|
_super.apply(this, arguments);
|
|
|
|
}
|
2015-02-07 03:45:09 +01:00
|
|
|
TextBox.prototype.select = function () { };
|
2014-07-13 01:04:16 +02:00
|
|
|
return TextBox;
|
|
|
|
})(Control);
|
|
|
|
var Image = (function (_super) {
|
|
|
|
__extends(Image, _super);
|
|
|
|
function Image() {
|
|
|
|
_super.apply(this, arguments);
|
|
|
|
}
|
|
|
|
return Image;
|
|
|
|
})(Control);
|
|
|
|
var Location = (function () {
|
|
|
|
function Location() {
|
|
|
|
}
|
2015-02-07 03:45:09 +01:00
|
|
|
Location.prototype.select = function () { };
|
2014-07-13 01:04:16 +02:00
|
|
|
return Location;
|
|
|
|
})();
|