Add NetConection and NetStream stubs

This commit is contained in:
Jet Villegas 2012-09-27 13:52:50 -07:00
Родитель 6e95ddff66
Коммит a9351ac271
4 изменённых файлов: 38 добавлений и 0 удалений

Просмотреть файл

@ -97,6 +97,8 @@
<script src="../../src/flash/events/ProgressEvent.js"></script>
<script src="../../src/flash/events/TimerEvent.js"></script>
<script src="../../src/flash/events/EventDispatcher.js"></script>
<script src="../../src/flash/net/NetConnection.js"></script>
<script src="../../src/flash/net/NetStream.js"></script>
<script src="../../src/flash/display/DisplayObject.js"></script>
<script src="../../src/flash/display/InteractiveObject.js"></script>
<script src="../../src/flash/display/DisplayObjectContainer.js"></script>
@ -129,6 +131,7 @@
<script src="../../src/glue/avm2/flash_geom.js"></script>
<script src="../../src/glue/avm2/flash_events.js"></script>
<script src="../../src/glue/avm2/flash_media.js"></script>
<script src="../../src/glue/avm2/flash_net.js"></script>
<script src="../../src/glue/avm2/flash_display.js"></script>
<script src="../../src/glue/avm2/flash_ui.js"></script>
<script src="../../src/glue/avm2/flash_utils.js"></script>

Просмотреть файл

@ -0,0 +1,7 @@
function NetConnection() {
EventDispatcher.call(this);
}
NetConnection.prototype = Object.create(EventDispatcher.prototype, {
__class__: describeInternalProperty('flash.net.NetConnection')
});

Просмотреть файл

@ -0,0 +1,7 @@
function NetStream() {
EventDispatcher.call(this);
}
NetStream.prototype = Object.create(EventDispatcher.prototype, {
__class__: describeInternalProperty('flash.net.NetStream')
});

Просмотреть файл

@ -0,0 +1,21 @@
natives.NetConnectionClass = function EventDispatcherClass(runtime, scope, instance, baseClass) {
var c = new runtime.domain.system.Class("NetConnection", instance, Domain.passthroughCallable(instance));
c.extend(baseClass);
c.nativeStatics = {};
c.nativeMethods = {};
return c;
};
natives.NetStreamClass = function EventDispatcherClass(runtime, scope, instance, baseClass) {
var c = new runtime.domain.system.Class("NetStream", instance, Domain.passthroughCallable(instance));
c.extend(baseClass);
c.nativeStatics = {};
c.nativeMethods = {};
return c;
};