Browse Source

updated to show usage of user preferences

Shaddock Heath 9 years ago
parent
commit
6c91d19123

+ 5 - 1
EditorPluginExample/Resources/EditorData/JSExample.plugin.js

@@ -8,6 +8,7 @@ var extensionWindow = null;
 var helloLabel = null;
 var helloLabel = null;
 var nameField = null;
 var nameField = null;
 var lastObjectName = null;
 var lastObjectName = null;
+var totalUses = 0;
 
 
 // Private functions
 // Private functions
 function getWidgets() {
 function getWidgets() {
@@ -37,7 +38,8 @@ function handleWidgetEvent(ev) {
         }
         }
 
 
         if (ev.target.id == "example_speak") {
         if (ev.target.id == "example_speak") {
-            helloLabel.text = "Hello " + nameField.text;
+            serviceLocator.projectServices.setUserPreference("JSExamplePlugin", "UsageCount", ++totalUses);
+            helloLabel.text = "Hello " + nameField.text + ", This was used " + totalUses + " times.";
             return true;
             return true;
         }
         }
     }
     }
@@ -97,6 +99,8 @@ JSExamplePlugin.projectLoaded = function(ev) {
     serviceLocator.uiServices.createProjectContextMenuItemSource(ExamplePluginUILabel, {
     serviceLocator.uiServices.createProjectContextMenuItemSource(ExamplePluginUILabel, {
         "Get name": ["jsexampleplugin project context"]
         "Get name": ["jsexampleplugin project context"]
     });
     });
+
+    totalUses = serviceLocator.projectServices.getUserPreference("JSExamplePlugin", "UsageCount", 0);
 };
 };
 
 
 JSExamplePlugin.playerStarted = function() {
 JSExamplePlugin.playerStarted = function() {

+ 5 - 1
EditorPluginExample/Resources/EditorData/TSExample.plugin.js

@@ -1,3 +1,4 @@
+/// <reference path="../../typings/Atomic/Atomic.d.ts" />
 "use strict";
 "use strict";
 var ExamplePluginUILabel = "TS Example Plugin";
 var ExamplePluginUILabel = "TS Example Plugin";
 var ExamplePluginTBPath = "EditorData/Example.tb.txt";
 var ExamplePluginTBPath = "EditorData/Example.tb.txt";
@@ -10,6 +11,7 @@ var TSExamplePluginService = (function () {
         this.serviceLocator = null;
         this.serviceLocator = null;
         this.extensionWindow = null;
         this.extensionWindow = null;
         this.lastObjectName = null;
         this.lastObjectName = null;
+        this.totalUses = 0;
         this.handleWidgetEvent = function (ev) {
         this.handleWidgetEvent = function (ev) {
             if (!_this.extensionWindow) {
             if (!_this.extensionWindow) {
                 return;
                 return;
@@ -21,7 +23,8 @@ var TSExamplePluginService = (function () {
                     return true;
                     return true;
                 }
                 }
                 if (ev.target.id == "example_speak") {
                 if (ev.target.id == "example_speak") {
-                    _this.helloLabel.text = "Hello " + _this.nameField.text;
+                    _this.serviceLocator.projectServices.setUserPreference(_this.name, "UsageCount", ++_this.totalUses);
+                    _this.helloLabel.text = "Hello " + _this.nameField.text + ", This was used " + _this.totalUses + " times.";
                     return true;
                     return true;
                 }
                 }
             }
             }
@@ -51,6 +54,7 @@ var TSExamplePluginService = (function () {
         this.serviceLocator.uiServices.createPluginMenuItemSource(ExamplePluginUILabel, { "Open": ["tsexampleplugin open"] });
         this.serviceLocator.uiServices.createPluginMenuItemSource(ExamplePluginUILabel, { "Open": ["tsexampleplugin open"] });
         this.serviceLocator.uiServices.createHierarchyContextMenuItemSource(ExamplePluginUILabel, { "Get name": ["tsexampleplugin hierarchy context"] });
         this.serviceLocator.uiServices.createHierarchyContextMenuItemSource(ExamplePluginUILabel, { "Get name": ["tsexampleplugin hierarchy context"] });
         this.serviceLocator.uiServices.createProjectContextMenuItemSource(ExamplePluginUILabel, { "Get name": ["tsexampleplugin project context"] });
         this.serviceLocator.uiServices.createProjectContextMenuItemSource(ExamplePluginUILabel, { "Get name": ["tsexampleplugin project context"] });
+        this.totalUses = this.serviceLocator.projectServices.getUserPreference(this.name, "UsageCount", 0);
     };
     };
     TSExamplePluginService.prototype.playerStarted = function () {
     TSExamplePluginService.prototype.playerStarted = function () {
         Atomic.print("TSExamplePluginService.playerStarted");
         Atomic.print("TSExamplePluginService.playerStarted");

+ 5 - 3
EditorPluginExample/Resources/EditorData/TSExample.plugin.ts

@@ -1,5 +1,4 @@
-/// <reference path="../../typings/Atomic/AtomicWork.d.ts" />
-/// <reference path="../../typings/Atomic/EditorWork.d.ts" />
+/// <reference path="../../typings/Atomic/Atomic.d.ts" />
 
 
 const ExamplePluginUILabel = "TS Example Plugin";
 const ExamplePluginUILabel = "TS Example Plugin";
 const ExamplePluginTBPath = "EditorData/Example.tb.txt";
 const ExamplePluginTBPath = "EditorData/Example.tb.txt";
@@ -17,6 +16,7 @@ class TSExamplePluginService implements Editor.HostExtensions.HostEditorService,
     private nameField: Atomic.UIEditField;
     private nameField: Atomic.UIEditField;
 
 
     private lastObjectName: string = null;
     private lastObjectName: string = null;
+    private totalUses = 0;
 
 
     initialize(serviceLoader: Editor.HostExtensions.HostServiceLocator) {
     initialize(serviceLoader: Editor.HostExtensions.HostServiceLocator) {
         Atomic.print("TSExamplePluginService.initialize");
         Atomic.print("TSExamplePluginService.initialize");
@@ -43,6 +43,7 @@ class TSExamplePluginService implements Editor.HostExtensions.HostEditorService,
         this.serviceLocator.uiServices.createPluginMenuItemSource(ExamplePluginUILabel, { "Open" : ["tsexampleplugin open"] });
         this.serviceLocator.uiServices.createPluginMenuItemSource(ExamplePluginUILabel, { "Open" : ["tsexampleplugin open"] });
         this.serviceLocator.uiServices.createHierarchyContextMenuItemSource(ExamplePluginUILabel, { "Get name" : ["tsexampleplugin hierarchy context"]});
         this.serviceLocator.uiServices.createHierarchyContextMenuItemSource(ExamplePluginUILabel, { "Get name" : ["tsexampleplugin hierarchy context"]});
         this.serviceLocator.uiServices.createProjectContextMenuItemSource(ExamplePluginUILabel, { "Get name" : ["tsexampleplugin project context"]});
         this.serviceLocator.uiServices.createProjectContextMenuItemSource(ExamplePluginUILabel, { "Get name" : ["tsexampleplugin project context"]});
+        this.totalUses = this.serviceLocator.projectServices.getUserPreference(this.name, "UsageCount", 0);
     }
     }
     playerStarted() {
     playerStarted() {
         Atomic.print("TSExamplePluginService.playerStarted");
         Atomic.print("TSExamplePluginService.playerStarted");
@@ -127,7 +128,8 @@ class TSExamplePluginService implements Editor.HostExtensions.HostEditorService,
 
 
             if (ev.target.id == "example_speak") {
             if (ev.target.id == "example_speak") {
 
 
-                this.helloLabel.text = "Hello " + this.nameField.text;
+                this.serviceLocator.projectServices.setUserPreference(this.name, "UsageCount", ++this.totalUses);
+                this.helloLabel.text = `Hello ${this.nameField.text}, This was used ${this.totalUses} times.`;
 
 
                 return true;
                 return true;
             }
             }

+ 2 - 3
EditorPluginExample/tsconfig.json

@@ -14,10 +14,9 @@
         "typings/**/*.ts"
         "typings/**/*.ts"
     ],
     ],
     "files": [
     "files": [
+        "Resources/EditorData/TSExample.plugin.ts",
         "Resources/Scripts/main.ts",
         "Resources/Scripts/main.ts",
-        "typings/Atomic/Atomic.d.ts",
-        "typings/Atomic/AtomicPlayer.d.ts",
-        "typings/Atomic/AtomicWork.d.ts"
+        "typings/Atomic/Atomic.d.ts"
     ],
     ],
     "atom": {
     "atom": {
         "rewriteTsconfig": true
         "rewriteTsconfig": true

File diff suppressed because it is too large
+ 477 - 383
EditorPluginExample/typings/Atomic/Atomic.d.ts


+ 0 - 124
EditorPluginExample/typings/Atomic/AtomicNET.d.ts

@@ -1,124 +0,0 @@
-//////////////////////////////////////////////////////////
-// IMPORTANT: THIS FILE IS GENERATED, CHANGES WILL BE LOST
-//////////////////////////////////////////////////////////
-
-// Atomic TypeScript Definitions
-
-/// <reference path="Atomic.d.ts" />
-
-declare module AtomicNET {
-
-
-   // enum CSComponentMethod
-   export type CSComponentMethod = number;
-   export var CSComponentMethod_Start: CSComponentMethod;
-   export var CSComponentMethod_DelayedStart: CSComponentMethod;
-   export var CSComponentMethod_Update: CSComponentMethod;
-   export var CSComponentMethod_PostUpdate: CSComponentMethod;
-   export var CSComponentMethod_FixedUpdate: CSComponentMethod;
-   export var CSComponentMethod_PostFixedUpdate: CSComponentMethod;
-
-
-//----------------------------------------------------
-// MODULE: NETCore
-//----------------------------------------------------
-
-
-   export class NETCore extends Atomic.AObject {
-
-      context: Atomic.Context;
-
-      // Construct.
-      constructor();
-
-      shutdown(): void;
-      addAssemblyLoadPath(assemblyPath: string): void;
-      execAssembly(assemblyName: string, args: string[]): number;
-      waitForDebuggerConnect(): void;
-      // to get a reference from
-      static getContext(): Atomic.Context;
-
-   }
-
-   export class NETVariantMap extends Atomic.RefCounted {
-
-      constructor();
-
-      getBool(key: string): boolean;
-      getInt(key: string): number;
-      getFloat(key: string): number;
-      getVector3(key: string): Atomic.Vector3;
-      getQuaternion(key: string): Atomic.Quaternion;
-      getPtr(key: string): Atomic.RefCounted;
-      getString(key: string): string;
-      getVariantType(key: string): Atomic.VariantType;
-      getResourceFromRef(key: string): Atomic.Resource;
-      contains(key: string): boolean;
-
-   }
-
-
-
-//----------------------------------------------------
-// MODULE: NETScript
-//----------------------------------------------------
-
-
-   export class CSComponent extends Atomic.ScriptComponent {
-
-      componentClassName: string;
-      componentFile: Atomic.ScriptComponentFile;
-      assemblyFile: CSComponentAssembly;
-
-      // Construct.
-      constructor();
-
-      applyAttributes(): void;
-      // Handle enabled/disabled state change. Changes update event subscription.
-      onSetEnabled(): void;
-      applyFieldValues(): void;
-      setComponentClassName(name: string): void;
-      getComponentClassName(): string;
-      getComponentFile(): Atomic.ScriptComponentFile;
-      getAssemblyFile(): CSComponentAssembly;
-      setAssemblyFile(assemblyFile: CSComponentAssembly): void;
-
-   }
-
-   export class CSComponentAssembly extends Atomic.ScriptComponentFile {
-
-      classNames: string[];
-
-      // Construct.
-      constructor();
-
-      createCSComponent(classname: string): CSComponent;
-      // Only valid in editor, as we don't inspect assembly at runtime
-      getClassNames(): string[];
-
-   }
-
-   export class CSManaged extends Atomic.AObject {
-
-      // Construct.
-      constructor();
-
-      initialize(): boolean;
-      nETUpdate(timeStep: number): void;
-      cSComponentCreate(assemblyName: string, componentName: string): CSComponent;
-      cSComponentApplyFields(component: CSComponent, fieldMapPtr: NETVariantMap): void;
-      cSComponentCallMethod(id: number, methodID: CSComponentMethod, value?: number): void;
-
-   }
-
-   export class CSScriptObject extends Atomic.AObject {
-
-      // Construct.
-      constructor();
-
-
-   }
-
-
-
-}

+ 0 - 31
EditorPluginExample/typings/Atomic/AtomicPlayer.d.ts

@@ -1,31 +0,0 @@
-//////////////////////////////////////////////////////////
-// IMPORTANT: THIS FILE IS GENERATED, CHANGES WILL BE LOST
-//////////////////////////////////////////////////////////
-
-// Atomic TypeScript Definitions
-
-/// <reference path="Atomic.d.ts" />
-
-declare module AtomicPlayer {
-
-
-//----------------------------------------------------
-// MODULE: Player
-//----------------------------------------------------
-
-
-   export class Player extends Atomic.AObject {
-
-      currentScene: Atomic.Scene;
-
-      // Construct.
-      constructor();
-
-      loadScene(filename: string, camera?: Atomic.Camera): Atomic.Scene;
-      getCurrentScene(): Atomic.Scene;
-
-   }
-
-
-
-}

+ 0 - 396
EditorPluginExample/typings/Atomic/AtomicWork.d.ts

@@ -1,396 +0,0 @@
-/// <reference path="Atomic.d.ts" />
-/// <reference path="ToolCore.d.ts" />
-/// <reference path="Editor.d.ts" />
-/// <reference path="AtomicPlayer.d.ts" />
-/// <reference path="AtomicNET.d.ts" />
-
-declare module Atomic {
-
-    export function print(...args: any[]);
-
-    export var platform: string;
-
-    // subsystems
-
-    export var engine: Engine;
-    export var graphics: Graphics;
-    export var renderer: Renderer;
-    export var cache: ResourceCache;
-    export var input: Input;
-    export var fileSystem: FileSystem;
-    export var network: Network;
-    export var ui: UI;
-    export var audio: Audio;
-    export var player: AtomicPlayer.Player;
-
-    export var editorMode: Editor.EditorMode;
-
-    // end subsystems
-
-
-    export interface PathInfo {
-
-        pathName: string;
-        fileName: string;
-        ext: string;
-
-    }
-
-    export interface ScreenModeEvent {
-
-        width: number;
-        height: number;
-        fullscreen: boolean;
-        resizable: boolean;
-        borderless: boolean;
-
-    }
-
-    export interface KeyDownEvent {
-
-        // keycode
-        key: number;
-        //  Atomic.QUAL_SHIFT, Atomic.QUAL_CTRL, Atomic.QUAL_ALT, Atomic.QUAL_ANY
-        qualifiers: number;
-
-        // mouse buttons down
-        buttons: number;
-
-    }
-
-    export interface KeyUpEvent {
-
-        // keycode
-        key: number;
-        //  Atomic.QUAL_SHIFT, Atomic.QUAL_CTRL, Atomic.QUAL_ALT, Atomic.QUAL_ANY
-        qualifiers: number;
-        // mouse buttons down
-        buttons: number;
-
-    }
-
-    export interface UIShortcutEvent {
-
-        // keycode
-        key: number;
-        //  Atomic.QUAL_SHIFT, Atomic.QUAL_CTRL, Atomic.QUAL_ALT, Atomic.QUAL_ANY
-        qualifiers: number;
-
-    }
-
-    export interface UIListViewSelectionChangedEvent {
-
-        refid: string;
-        selected: boolean;
-
-    }
-
-    export interface NodeAddedEvent {
-
-        scene: Atomic.Scene;
-        parent: Atomic.Node;
-        node: Atomic.Node;
-
-    }
-
-    export interface NodeRemovedEvent {
-
-        scene: Atomic.Scene;
-        parent: Atomic.Node;
-        node: Atomic.Node;
-
-    }
-
-    export interface NodeNameChangedEvent {
-
-        scene: Atomic.Scene;
-        node: Atomic.Node;
-
-    }
-
-    export interface UIWidgetEvent {
-
-        handler: UIWidget;
-        target: UIWidget;
-        type: number; /*UIWidgetEventType*/
-        x: number;
-        y: number;
-        deltax: number;
-        deltay: number;
-        count: number;
-        key: number;
-        specialkey: number;
-        modifierkeys: number;
-        refid: string;
-        touch: boolean;
-    }
-
-    export interface UIWidgetFocusChangedEvent {
-        widget: UIWidget;
-        focused: boolean;
-    }
-
-    export interface UIWidgetEditCompleteEvent {
-        widget: UIWidget;
-    }
-
-    export interface UIWidgetDeletedEvent {
-
-        widget: UIWidget;
-    }
-
-    export interface DragBeginEvent {
-
-        source: UIWidget;
-        dragObject: UIDragObject;
-    }
-
-    export interface DragEnterWidgetEvent {
-
-        widget: UIWidget;
-        dragObject: UIDragObject;
-    }
-
-    export interface DragExitWidgetEvent {
-
-        widget: UIWidget;
-        dragObject: UIDragObject;
-    }
-
-    export interface DragEndedEvent {
-
-        target: UIWidget;
-        dragObject: UIDragObject;
-    }
-
-    export interface TemporaryChangedEvent {
-
-        serializable: Atomic.Serializable;
-
-    }
-
-    export interface ComponentAddedEvent {
-
-        scene: Atomic.Scene;
-        node: Atomic.Node;
-        component: Atomic.Component;
-
-    }
-
-    export interface ComponentRemovedEvent {
-
-        scene: Atomic.Scene;
-        node: Atomic.Node;
-        component: Atomic.Component;
-
-    }
-
-    export interface IPCJSErrorEvent {
-
-        errorName: string;
-        errorMessage: string;
-        errorFileName: string;
-        errorLineNumber: number;
-        errorStack: string;
-
-    }
-
-
-    export interface IPCMessageEvent {
-
-        message: string;
-        value: number;
-    }
-
-    export interface AttributeInfo {
-
-        type: VariantType;
-        name: string;
-        mode: number; // AM_*
-        defaultValue: string;
-        enumNames: string[];
-        resourceTypeName: string;
-        dynamic: boolean;
-
-    }
-
-    export interface ShaderParameter {
-
-        name: string;
-        value: any;
-        valueString: string;
-        typeName: string;
-        type: VariantType;
-
-    }
-
-    export function getArguments(): Array<string>;
-    export function getEngine(): Engine;
-    export function getInput(): Input;
-    export function getGraphics(): Graphics;
-    export function getFileSystem(): FileSystem;
-    export function getResourceCache(): ResourceCache;
-    export function getRenderer(): Atomic.Renderer;
-    export function getNetwork(): Atomic.Network;
-    export function getUI(): Atomic.UI;
-
-    export function assert();
-    export function js_module_read_file(path: string);
-    export function openConsoleWindow();
-    export function script(script: string): boolean;
-    export function destroy(node: Atomic.Node): boolean;
-    export function destroy(scene: Atomic.Scene): boolean;
-    export function destroy(component: Atomic.JSComponent): boolean;
-
-    export function getParentPath(path: string): string;
-    export function addTrailingSlash(path: string): string;
-    export function getExtension(path: string): string;
-
-    export function splitPath(path: string): PathInfo;
-
-}
-
-declare module AtomicNET {
-
-    export interface CSComponentClassChangedEvent {
-
-        cscomponent: CSComponent;
-        classname: string;
-
-    }
-
-}
-
-declare module Editor {
-
-    export interface SceneNodeSelectedEvent {
-        scene: Atomic.Scene;
-        node: Atomic.Node;
-        selected: boolean;
-        quiet: boolean;
-    }
-
-    export interface SceneEditAddRemoveNodesEvent {
-
-        end: boolean;
-
-    }
-
-
-    export interface SceneEditNodeAddedEvent {
-
-        scene: Atomic.Scene;
-        parent: Atomic.Node;
-        node: Atomic.Node;
-
-    }
-
-    export interface SceneEditNodeRemovedEvent {
-
-        scene: Atomic.Scene;
-        parent: Atomic.Node;
-        node: Atomic.Node;
-
-    }
-
-    export interface SceneEditComponentAddedRemovedEvent {
-
-        scene: Atomic.Scene;
-        node: Atomic.Node;
-        component: Atomic.Component;
-        removed: boolean;
-    }
-
-    export interface SceneEditStateChangeEvent {
-
-        serializable: Atomic.Serializable;
-
-    }
-
-    export interface SceneEditNodeCreatedEvent {
-        node: Atomic.Node;
-    }
-
-    export interface GizmoEditModeChangedEvent {
-        mode: EditMode;
-    }
-
-    export interface GizmoAxisModeChangedEvent {
-        mode: AxisMode;
-    }
-
-}
-
-declare module ToolCore {
-
-    export interface ResourceAddedEvent {
-
-        guid: string;
-
-    }
-
-    export interface ResourceRemovedEvent {
-
-        guid: string;
-
-    }
-
-    export interface LicenseDeactivationErrorEvent {
-
-        message: string;
-
-    }
-
-    export interface AssetImportErrorEvent {
-
-        path: string;
-        guid: string;
-        error: string;
-    }
-
-    export interface AssetRenamedEvent {
-
-        asset: Asset;
-
-    }
-
-    export interface AssetMovedEvent {
-
-        asset: Asset;
-        oldPath: string;
-
-    }
-
-
-    export interface PlatformChangedEvent {
-
-        platform: ToolCore.Platform;
-
-    }
-
-    export interface BuildOutputEvent {
-
-        text: string;
-
-    }
-
-    export interface BuildCompleteEvent {
-
-        platformID: number;
-        message: string;
-        success: boolean;
-        buildFolder: string;
-
-    }
-
-    export var toolEnvironment: ToolEnvironment;
-    export var toolSystem: ToolSystem;
-    export var assetDatabase: AssetDatabase;
-    export var licenseSystem: LicenseSystem;
-    export var buildSystem: BuildSystem;
-
-    export function getToolEnvironment(): ToolEnvironment;
-    export function getToolSystem(): ToolSystem;
-    export function getAssetDatabase(): AssetDatabase;
-    export function getLicenseSystem(): LicenseSystem;
-}

+ 0 - 257
EditorPluginExample/typings/Atomic/Editor.d.ts

@@ -1,257 +0,0 @@
-//////////////////////////////////////////////////////////
-// IMPORTANT: THIS FILE IS GENERATED, CHANGES WILL BE LOST
-//////////////////////////////////////////////////////////
-
-// Atomic TypeScript Definitions
-
-/// <reference path="Atomic.d.ts" />
-
-declare module Editor {
-
-
-   // enum EditMode
-   export type EditMode = number;
-   export var EDIT_SELECT: EditMode;
-   export var EDIT_MOVE: EditMode;
-   export var EDIT_ROTATE: EditMode;
-   export var EDIT_SCALE: EditMode;
-
-
-   // enum AxisMode
-   export type AxisMode = number;
-   export var AXIS_WORLD: AxisMode;
-   export var AXIS_LOCAL: AxisMode;
-
-
-   // enum SceneEditType
-   export type SceneEditType = number;
-   export var SCENEEDIT_UNKNOWN: SceneEditType;
-   export var SCENEEDIT_SELECTION: SceneEditType;
-
-
-   export var FINDTEXT_FLAG_NONE: number;
-   export var FINDTEXT_FLAG_CASESENSITIVE: number;
-   export var FINDTEXT_FLAG_WHOLEWORD: number;
-   export var FINDTEXT_FLAG_WRAP: number;
-   export var FINDTEXT_FLAG_NEXT: number;
-   export var FINDTEXT_FLAG_PREV: number;
-   export var EDITOR_MODALERROR: number;
-   export var EDITOR_MODALINFO: number;
-
-
-//----------------------------------------------------
-// MODULE: Editor
-//----------------------------------------------------
-
-
-   export class FileUtils extends Atomic.AObject {
-
-      mobileProvisionPath: string;
-
-      // Construct.
-      constructor();
-
-      createDirs(folder: string): boolean;
-      getMobileProvisionPath(): string;
-      getAndroidSDKPath(defaultPath: string): string;
-      getAntPath(defaultPath: string): string;
-      getJDKRootPath(defaultPath: string): string;
-      openProjectFileDialog(): string;
-      newProjectFileDialog(): string;
-      getBuildPath(defaultPath: string): string;
-      revealInFinder(fullpath: string): void;
-
-   }
-
-   export class EditorMode extends Atomic.AObject {
-
-      // Construct.
-      constructor();
-
-      playProject(addArgs?: string, debug?: boolean): boolean;
-      isPlayerEnabled(): boolean;
-
-   }
-
-   export class PlayerMode extends Atomic.AObject {
-
-      // Construct.
-      constructor();
-
-      launchedByEditor(): boolean;
-
-   }
-
-   export class JSResourceEditor extends ResourceEditor {
-
-      constructor(fullpath: string, container: Atomic.UITabContainer);
-
-      findText(findText: string, flags: number): boolean;
-      findTextClose(): void;
-      gotoTokenPos(tokenPos: number): void;
-      gotoLineNumber(lineNumber: number): void;
-      formatCode(): void;
-      setFocus(): void;
-      save(): boolean;
-
-   }
-
-   export class ResourceEditor extends Atomic.AObject {
-
-      button: Atomic.UIButton;
-      fullPath: string;
-      rootContentWidget: Atomic.UIWidget;
-      modified: boolean;
-
-      constructor(fullpath: string, container: Atomic.UITabContainer);
-
-      getButton(): Atomic.UIButton;
-      hasUnsavedModifications(): boolean;
-      setFocus(): void;
-      close(navigateToAvailableResource?: boolean): void;
-      findText(text: string, flags: number): boolean;
-      findTextClose(): void;
-      requiresInspector(): boolean;
-      getFullPath(): string;
-      undo(): void;
-      redo(): void;
-      save(): boolean;
-      projectUnloaded(): void;
-      delete(): void;
-      getRootContentWidget(): Atomic.UIWidget;
-      invokeShortcut(shortcut: string): void;
-      requestClose(): void;
-      setModified(modified: boolean): void;
-
-   }
-
-   export class Gizmo3D extends Atomic.AObject {
-
-      view: SceneView3D;
-      axisMode: AxisMode;
-      editMode: EditMode;
-      gizmoNode: Atomic.Node;
-      snapTranslationX: number;
-      snapTranslationY: number;
-      snapTranslationZ: number;
-      snapRotation: number;
-      snapScale: number;
-
-      constructor();
-
-      setView(view3D: SceneView3D): void;
-      setAxisMode(mode: AxisMode): void;
-      getAxisMode(): AxisMode;
-      setEditMode(mode: EditMode): void;
-      selected(): boolean;
-      show(): void;
-      hide(): void;
-      update(): void;
-      getGizmoNode(): Atomic.Node;
-      getSnapTranslationX(): number;
-      getSnapTranslationY(): number;
-      getSnapTranslationZ(): number;
-      getSnapRotation(): number;
-      getSnapScale(): number;
-      setSnapTranslationX(value: number): void;
-      setSnapTranslationY(value: number): void;
-      setSnapTranslationZ(value: number): void;
-      setSnapRotation(value: number): void;
-      setSnapScale(value: number): void;
-
-   }
-
-   export class SceneEditor3D extends ResourceEditor {
-
-      selection: SceneSelection;
-      sceneView3D: SceneView3D;
-      scene: Atomic.Scene;
-      gizmo: Gizmo3D;
-
-      constructor(fullpath: string, container: Atomic.UITabContainer);
-
-      getSelection(): SceneSelection;
-      getSceneView3D(): SceneView3D;
-      registerNode(node: Atomic.Node): void;
-      reparentNode(node: Atomic.Node, newParent: Atomic.Node): void;
-      getScene(): Atomic.Scene;
-      getGizmo(): Gizmo3D;
-      setFocus(): void;
-      requiresInspector(): boolean;
-      close(navigateToAvailableResource?: boolean): void;
-      save(): boolean;
-      undo(): void;
-      redo(): void;
-      cut(): void;
-      copy(): void;
-      paste(): void;
-      invokeShortcut(shortcut: string): void;
-      static getSceneEditor(scene: Atomic.Scene): SceneEditor3D;
-
-   }
-
-   export class SceneSelection extends Atomic.AObject {
-
-      selectedNodeCount: number;
-
-      constructor(sceneEditor: SceneEditor3D);
-
-      cut(): void;
-      copy(): void;
-      paste(): void;
-      delete(): void;
-      // Add a node to the selection, if clear specified removes current nodes first
-      addNode(node: Atomic.Node, clear?: boolean): void;
-      removeNode(node: Atomic.Node, quiet?: boolean): void;
-      getBounds(bbox: Atomic.BoundingBox): void;
-      contains(node: Atomic.Node): boolean;
-      getSelectedNode(index: number): Atomic.Node;
-      getSelectedNodeCount(): number;
-      clear(): void;
-
-   }
-
-   export class SceneView3D extends Atomic.UISceneView {
-
-      pitch: number;
-      yaw: number;
-      debugRenderer: Atomic.DebugRenderer;
-      sceneEditor3D: SceneEditor3D;
-
-      constructor(sceneEditor: SceneEditor3D);
-
-      setPitch(pitch: number): void;
-      setYaw(yaw: number): void;
-      frameSelection(): void;
-      enable(): void;
-      disable(): void;
-      isEnabled(): boolean;
-      getDebugRenderer(): Atomic.DebugRenderer;
-      getSceneEditor3D(): SceneEditor3D;
-
-   }
-
-   export class CubemapGenerator extends EditorComponent {
-
-      imageSize: number;
-
-      // Construct.
-      constructor();
-
-      render(): boolean;
-      getImageSize(): number;
-      setImageSize(size: number): void;
-
-   }
-
-   export class EditorComponent extends Atomic.Component {
-
-      // Construct.
-      constructor();
-
-
-   }
-
-
-
-}

+ 0 - 351
EditorPluginExample/typings/Atomic/EditorWork.d.ts

@@ -1,351 +0,0 @@
-//
-// Copyright (c) 2014-2015, THUNDERBEAST GAMES LLC All rights reserved
-// LICENSE: Atomic Game Engine Editor and Tools EULA
-// Please see LICENSE_ATOMIC_EDITOR_AND_TOOLS.md in repository root for
-// license information: https://github.com/AtomicGameEngine/AtomicGameEngine
-//
-
-/// <reference path="Atomic.d.ts" />
-/// <reference path="Editor.d.ts" />
-/// <reference path="ToolCore.d.ts" />
-
-declare module Editor.EditorEvents {
-
-    export interface ModalErrorEvent {
-
-        title: string;
-        message: string;
-
-    }
-
-    export interface PlayerLogEvent {
-
-        message: string;
-        level: number;
-
-    }
-
-    export interface ActiveSceneEditorChangeEvent {
-
-        sceneEditor: Editor.SceneEditor3D;
-
-    }
-
-    export interface SceneClosedEvent {
-
-        scene: Atomic.Scene;
-
-    }
-
-    export interface ContentFolderChangedEvent {
-
-        path: string;
-
-    }
-
-    export interface LoadProjectEvent {
-
-        // The full path to the .atomic file
-        path: string;
-
-    }
-
-    /**
-     * Called once the resource has been saved
-     * @type {String}
-     */
-    export interface SaveResourceEvent {
-
-        // The full path to the resource to save / empty or undefined for current
-        path: string;
-
-    }
-
-    export interface LoadResourceEvent {
-
-        // The full path to the resource to load
-        path: string;
-
-    }
-
-    export interface EditorFileEvent {
-        filename: string;
-        fileExt: string;
-        editor: any;
-    }
-
-    export interface CodeLoadedEvent extends EditorFileEvent {
-        code: string;
-    }
-
-    export interface CodeSavedEvent extends EditorFileEvent {
-        code: string;
-    }
-
-    export interface EditorCloseResourceEvent {
-
-        editor: Editor.ResourceEditor;
-        navigateToAvailableResource: boolean;
-
-    }
-
-    export interface EditResourceEvent {
-
-        // The full path to the resource to edit
-        path: string;
-
-    }
-
-    /**
-     * Called once the resource has been deleted
-     * @type {String}
-     */
-    export interface DeleteResourceEvent {
-
-        // The full path to the resource to edit
-        path: string;
-
-    }
-
-    /**
-     * Called once the resource has been renamed
-     * @type {String}
-     */
-    export interface RenameResourceEvent {
-
-        /**
-         * Original path of the resource
-         * @type {string}
-         */
-        path: string;
-
-        /**
-         * New path of the resource
-         * @type {string}
-         */
-        newPath: string;
-
-        /**
-         * New base name of the resource (no path or extension)
-         * @type {string}
-         */
-        newName?: string;
-
-        // the asset being changed
-        asset?: ToolCore.Asset;
-    }
-
-    export interface SceneEditStateChangeEvent {
-
-        serializable: Atomic.Serializable;
-
-    }
-}
-
-declare module Editor.Extensions {
-
-    /**
-     * Base interface for any editor services.
-     */
-    export interface EditorServiceExtension {
-        /**
-         * Unique name of this service
-         * @type {string}
-         */
-        name: string;
-
-        /**
-         * Description of this service
-         * @type {string}
-         */
-        description: string;
-
-    }
-
-    /**
-     * Base Service Event Listener.  Attach descendents of these to an EditorServiceExtension
-     * to hook service events
-     */
-    export interface ServiceEventListener extends EditorServiceExtension { }
-
-    interface EventDispatcher {
-        /**
-         * Send a custom event.  This can be used by services to publish custom events
-         * @param  {string} eventType
-         * @param  {any} data
-         */
-        sendEvent(eventType: string, data: any);
-
-        /**
-         * Subscribe to an event and provide a callback.  This can be used by services to subscribe to custom events
-         * @param  {string} eventType
-         * @param  {any} callback
-         */
-        subscribeToEvent(eventType, callback);
-    }
-
-    /**
-     * Generic service locator of editor services that may be injected by either a plugin
-     * or by the editor itself.
-     */
-    export interface ServiceLoader extends EventDispatcher {
-        /**
-         * Loads a service into a service registry
-         * @param  {EditorService} service
-         */
-        loadService(service: EditorServiceExtension): void;
-    }
-
-    /**
-     * Service registry interface for registering services
-     */
-    export interface ServicesProvider<T extends ServiceEventListener> {
-        registeredServices: T[];
-
-        /**
-         * Adds a service to the registered services list for this type of service
-         * @param  {T}      service the service to register
-         */
-        register(service: T);
-        /**
-         * Removes a service from the registered services list for this type of service
-         * @param  {T}      service the service to unregister
-         */
-        unregister(service: T);
-    }
-}
-
-declare module Editor.Modal {
-    export interface ExtensionWindow extends Atomic.UIWindow {
-        hide();
-    }
-}
-
-declare module Editor.HostExtensions {
-
-    /**
-     * Generic service locator of editor services that may be injected by either a plugin
-     * or by the editor itself.
-     */
-    export interface HostServiceLocator extends Editor.Extensions.ServiceLoader {
-        resourceServices: ResourceServicesProvider;
-        projectServices: ProjectServicesProvider;
-        uiServices: UIServicesProvider;
-    }
-
-    export interface HostEditorService extends Editor.Extensions.EditorServiceExtension {
-        /**
-         * Called by the service locator at load time
-         */
-        initialize(serviceLocator: HostServiceLocator);
-    }
-
-    export interface ResourceServicesEventListener extends Editor.Extensions.ServiceEventListener {
-        save?(ev: EditorEvents.SaveResourceEvent);
-        delete?(ev: EditorEvents.DeleteResourceEvent);
-        rename?(ev: EditorEvents.RenameResourceEvent);
-    }
-    export interface ResourceServicesProvider extends Editor.Extensions.ServicesProvider<ResourceServicesEventListener> { }
-
-    export interface ProjectServicesEventListener extends Editor.Extensions.ServiceEventListener {
-        projectUnloaded?();
-        projectLoaded?(ev: EditorEvents.LoadProjectEvent);
-        playerStarted?();
-    }
-    export interface ProjectServicesProvider extends Editor.Extensions.ServicesProvider<ProjectServicesEventListener> { }
-
-    export interface UIServicesEventListener extends Editor.Extensions.ServiceEventListener {
-        menuItemClicked?(refid: string): boolean;
-        projectContextItemClicked?(asset: ToolCore.Asset, refid: string): boolean;
-        hierarchyContextItemClicked?(node: Atomic.Node, refid: string): boolean;
-    }
-    export interface UIServicesProvider extends Editor.Extensions.ServicesProvider<UIServicesEventListener> {
-        createPluginMenuItemSource(id: string, items: any): Atomic.UIMenuItemSource;
-        removePluginMenuItemSource(id: string);
-        createHierarchyContextMenuItemSource(id: string, items: any): Atomic.UIMenuItemSource;
-        removeHierarchyContextMenuItemSource(id: string);
-        createProjectContextMenuItemSource(id: string, items: any): Atomic.UIMenuItemSource;
-        removeProjectContextMenuItemSource(id: string);
-        showModalWindow(windowText: string, uifilename: string, handleWidgetEventCB: (ev: Atomic.UIWidgetEvent) => void): Editor.Modal.ExtensionWindow;
-    }
-}
-
-/**
- * Interfaces for client extensions
- */
-declare module Editor.ClientExtensions {
-
-    /**
-     * Generic service locator of editor services that may be injected by either a plugin
-     * or by the editor itself.
-     */
-    export interface ClientServiceLocator extends Editor.Extensions.ServiceLoader {
-        getHostInterop(): HostInterop;
-    }
-
-    export interface ClientEditorService extends Editor.Extensions.EditorServiceExtension {
-        /**
-         * Called by the service locator at load time
-         */
-        initialize(serviceLocator: ClientServiceLocator);
-    }
-
-    export interface WebViewService extends Editor.Extensions.EditorServiceExtension {
-        configureEditor?(ev: EditorEvents.EditorFileEvent);
-        codeLoaded?(ev: EditorEvents.CodeLoadedEvent);
-        save?(ev: EditorEvents.CodeSavedEvent);
-        delete?(ev: EditorEvents.DeleteResourceEvent);
-        rename?(ev: EditorEvents.RenameResourceEvent);
-        projectUnloaded?();
-    }
-
-    export interface AtomicErrorMessage {
-        error_code: number;
-        error_message: string;
-    }
-
-    /**
-     * Interface for functions that are available from the client web view to call on the host
-     */
-    export interface HostInterop {
-
-        /**
-         * Called from the host to notify the client what file to load
-         * @param  {string} codeUrl
-         */
-        loadCode(codeUrl: string);
-
-        /**
-         * Save the contents of the editor
-         * @return {Promise}
-         */
-        saveCode(): PromiseLike<{}>;
-
-        /**
-         * Save the contents of a file as filename
-         * @param  {string} filename
-         * @param  {string} fileContents
-         * @return {Promise}
-         */
-        saveFile(filename: string, fileContents: string): PromiseLike<{}>;
-
-        /**
-         * Queries the host for a particular resource and returns it in a promise
-         * @param  {string} codeUrl
-         * @return {Promise}
-         */
-        getResource(codeUrl: string): PromiseLike<{}>;
-
-        /**
-         * Returns a file resource from the resources directory
-         * @param  {string} filename name and path of file under the project directory or a fully qualified file name
-         * @return {Promise}
-         */
-        getFileResource(filename: string): PromiseLike<{}>;
-
-        /**
-         * Notify the host that the contents of the editor has changed
-         */
-        notifyEditorChange();
-    }
-}

+ 0 - 879
EditorPluginExample/typings/Atomic/ToolCore.d.ts

@@ -1,879 +0,0 @@
-//////////////////////////////////////////////////////////
-// IMPORTANT: THIS FILE IS GENERATED, CHANGES WILL BE LOST
-//////////////////////////////////////////////////////////
-
-// Atomic TypeScript Definitions
-
-/// <reference path="Atomic.d.ts" />
-
-declare module ToolCore {
-
-
-   // enum PlatformID
-   export type PlatformID = number;
-   export var PLATFORMID_UNDEFINED: PlatformID;
-   export var PLATFORMID_WINDOWS: PlatformID;
-   export var PLATFORMID_MAC: PlatformID;
-   export var PLATFORMID_ANDROID: PlatformID;
-   export var PLATFORMID_IOS: PlatformID;
-   export var PLATFORMID_WEB: PlatformID;
-
-
-   export var PROJECTFILE_VERSION: number;
-
-
-//----------------------------------------------------
-// MODULE: ToolCore
-//----------------------------------------------------
-
-
-   export class ToolEnvironment extends Atomic.AObject {
-
-      rootSourceDir: string;
-      toolPrefs: ToolPrefs;
-      rootBuildDir: string;
-      editorBinary: string;
-      playerBinary: string;
-      toolBinary: string;
-      coreDataDir: string;
-      playerDataDir: string;
-      editorDataDir: string;
-      nETCoreCLRAbsPath: string;
-      nETAssemblyLoadPaths: string;
-      nETTPAPaths: string;
-      atomicNETEngineAssemblyPath: string;
-      deploymentDataDir: string;
-      toolDataDir: string;
-      devConfigFilename: string;
-      playerAppFolder: string;
-      iOSDeployBinary: string;
-
-      constructor();
-
-      initFromPackage(): boolean;
-      initFromJSON(atomicTool?: boolean): boolean;
-      // Root source and build directories for development source tree builds
-      setRootSourceDir(sourceDir: string): void;
-      setRootBuildDir(buildDir: string, setBinaryPaths?: boolean): void;
-      getToolPrefs(): ToolPrefs;
-      saveToolPrefs(): void;
-      loadToolPrefs(): void;
-      getRootSourceDir(): string;
-      getRootBuildDir(): string;
-      // Binaries
-      getEditorBinary(): string;
-      getPlayerBinary(): string;
-      getToolBinary(): string;
-      // Resource directories
-      getCoreDataDir(): string;
-      getPlayerDataDir(): string;
-      getEditorDataDir(): string;
-      // AtomicNET
-      getNETCoreCLRAbsPath(): string;
-      getNETAssemblyLoadPaths(): string;
-      getNETTPAPaths(): string;
-      getAtomicNETEngineAssemblyPath(): string;
-      // Data directories
-      getDeploymentDataDir(): string;
-      getToolDataDir(): string;
-      getDevConfigFilename(): string;
-      getPlayerAppFolder(): string;
-      getIOSDeployBinary(): string;
-      dump(): void;
-
-   }
-
-   export class ToolPrefs extends Atomic.AObject {
-
-      androidSDKPath: string;
-      jDKRootPath: string;
-      antPath: string;
-      prefsPath: string;
-
-      constructor();
-
-      getAndroidSDKPath(): string;
-      getJDKRootPath(): string;
-      getAntPath(): string;
-      setAndroidSDKPath(path: string): void;
-      setJDKRootPath(path: string): void;
-      setAntPath(path: string): void;
-      getPrefsPath(): string;
-      load(): void;
-      save(): void;
-
-   }
-
-   export class ToolSystem extends Atomic.AObject {
-
-      project: Project;
-      dataPath: string;
-      currentPlatform: Platform;
-
-      constructor();
-
-      loadProject(fullpath: string): boolean;
-      getProject(): Project;
-      closeProject(): void;
-      getDataPath(): string;
-      setDataPath(path: string): void;
-      registerPlatform(platform: Platform): void;
-      getPlatformByID(platform: PlatformID): Platform;
-      getPlatformByName(name: string): Platform;
-      setCurrentPlatform(platform: PlatformID): void;
-      getCurrentPlatform(): Platform;
-      setCLI(): void;
-      isCLI(): boolean;
-
-   }
-
-   export class Project extends Atomic.AObject {
-
-      resourcePath: string;
-      componentsPath: string;
-      scriptsPath: string;
-      modulesPath: string;
-      buildSettings: ProjectBuildSettings;
-      userPrefs: ProjectUserPrefs;
-      projectPath: string;
-      projectFilePath: string;
-      userPrefsFullPath: string;
-      buildSettingsFullPath: string;
-      version: string;
-
-      // Construct.
-      constructor();
-
-      load(fullpath: string): boolean;
-      save(fullpath?: string): void;
-      // Paths
-      getResourcePath(): string;
-      setResourcePath(resourcePath: string): void;
-      getComponentsPath(): string;
-      getScriptsPath(): string;
-      getModulesPath(): string;
-      isComponentsDirOrFile(fullPath: string): boolean;
-      isScriptsDirOrFile(fullPath: string): boolean;
-      isModulesDirOrFile(fullPath: string): boolean;
-      addPlatform(platformID: PlatformID): void;
-      containsPlatform(platformID: PlatformID): boolean;
-      removePlatform(platformID: PlatformID): void;
-      isDirty(): boolean;
-      setDirty(): void;
-      getBuildSettings(): ProjectBuildSettings;
-      getUserPrefs(): ProjectUserPrefs;
-      getProjectPath(): string;
-      getProjectFilePath(): string;
-      getUserPrefsFullPath(): string;
-      getBuildSettingsFullPath(): string;
-      getVersion(): string;
-      setVersion(version: string): void;
-      saveBuildSettings(): void;
-      loadBuildSettings(): boolean;
-      saveUserPrefs(): void;
-      loadUserPrefs(): boolean;
-
-   }
-
-   export class MacBuildSettings extends Atomic.RefCounted {
-
-      appName: string;
-      packageName: string;
-      companyName: string;
-      productName: string;
-
-      constructor();
-
-      getAppName(): string;
-      getPackageName(): string;
-      getCompanyName(): string;
-      getProductName(): string;
-      setAppName(name: string): void;
-      setPackageName(packageName: string): void;
-      setCompanyName(companyName: string): void;
-      setProductName(productName: string): void;
-
-   }
-
-   export class WebBuildSettings extends Atomic.RefCounted {
-
-      appName: string;
-      packageName: string;
-      companyName: string;
-      productName: string;
-
-      constructor();
-
-      getAppName(): string;
-      getPackageName(): string;
-      getCompanyName(): string;
-      getProductName(): string;
-      setAppName(name: string): void;
-      setPackageName(packageName: string): void;
-      setCompanyName(companyName: string): void;
-      setProductName(productName: string): void;
-
-   }
-
-   export class WindowsBuildSettings extends Atomic.RefCounted {
-
-      appName: string;
-      packageName: string;
-      companyName: string;
-      productName: string;
-
-      constructor();
-
-      getAppName(): string;
-      getPackageName(): string;
-      getCompanyName(): string;
-      getProductName(): string;
-      setAppName(name: string): void;
-      setPackageName(packageName: string): void;
-      setCompanyName(companyName: string): void;
-      setProductName(productName: string): void;
-
-   }
-
-   export class AndroidBuildSettings extends Atomic.RefCounted {
-
-      appName: string;
-      packageName: string;
-      companyName: string;
-      productName: string;
-      sDKVersion: string;
-      minSDKVersion: string;
-      activityName: string;
-
-      constructor();
-
-      getAppName(): string;
-      getPackageName(): string;
-      getCompanyName(): string;
-      getProductName(): string;
-      getSDKVersion(): string;
-      getMinSDKVersion(): string;
-      getActivityName(): string;
-      setAppName(name: string): void;
-      setPackageName(packageName: string): void;
-      setCompanyName(companyName: string): void;
-      setProductName(productName: string): void;
-      setSDKVersion(value: string): void;
-      setMinSDKVersion(value: string): void;
-      setActivityName(value: string): void;
-
-   }
-
-   export class IOSBuildSettings extends Atomic.RefCounted {
-
-      appName: string;
-      packageName: string;
-      companyName: string;
-      productName: string;
-      provisionFile: string;
-      appIDPrefix: string;
-
-      constructor();
-
-      getAppName(): string;
-      getPackageName(): string;
-      getCompanyName(): string;
-      getProductName(): string;
-      getProvisionFile(): string;
-      getAppIDPrefix(): string;
-      setAppName(name: string): void;
-      setPackageName(packageName: string): void;
-      setCompanyName(companyName: string): void;
-      setProductName(productName: string): void;
-      setProvisionFile(value: string): void;
-      setAppIDPrefix(value: string): void;
-
-   }
-
-   export class ProjectBuildSettings extends Atomic.AObject {
-
-      macBuildSettings: MacBuildSettings;
-      windowsBuildSettings: WindowsBuildSettings;
-      webBuildSettings: WebBuildSettings;
-      androidBuildSettings: AndroidBuildSettings;
-      iOSBuildSettings: IOSBuildSettings;
-
-      // Construct.
-      constructor();
-
-      getMacBuildSettings(): MacBuildSettings;
-      getWindowsBuildSettings(): WindowsBuildSettings;
-      getWebBuildSettings(): WebBuildSettings;
-      getAndroidBuildSettings(): AndroidBuildSettings;
-      getIOSBuildSettings(): IOSBuildSettings;
-      load(path: string): boolean;
-      save(path: string): void;
-
-   }
-
-   export class ProjectFile extends Atomic.AObject {
-
-      // Construct.
-      constructor();
-
-      save(project: Project): void;
-      load(project: Project): boolean;
-      writeNewProject(fullpath: string): void;
-
-   }
-
-   export class ProjectUserPrefs extends Atomic.AObject {
-
-      defaultPlatform: PlatformID;
-      lastBuildPath: string;
-      snapTranslationX: number;
-      snapTranslationY: number;
-      snapTranslationZ: number;
-      snapRotation: number;
-      snapScale: number;
-
-      // Construct.
-      constructor();
-
-      getDefaultPlatform(): PlatformID;
-      getLastBuildPath(): string;
-      setLastBuildPath(path: string): void;
-      getSnapTranslationX(): number;
-      getSnapTranslationY(): number;
-      getSnapTranslationZ(): number;
-      getSnapRotation(): number;
-      getSnapScale(): number;
-      setSnapTranslationX(value: number): void;
-      setSnapTranslationY(value: number): void;
-      setSnapTranslationZ(value: number): void;
-      setSnapRotation(value: number): void;
-      setSnapScale(value: number): void;
-
-   }
-
-   export class Platform extends Atomic.AObject {
-
-      license: boolean;
-      name: string;
-      platformID: PlatformID;
-
-      constructor();
-
-      getLicense(): boolean;
-      getName(): string;
-      getPlatformID(): PlatformID;
-      newBuild(project: Project): BuildBase;
-
-   }
-
-   export class PlatformAndroid extends Platform {
-
-      license: boolean;
-      name: string;
-      platformID: PlatformID;
-      androidCommand: string;
-      aDBCommand: string;
-      androidTargets: string[];
-
-      constructor();
-
-      getLicense(): boolean;
-      getName(): string;
-      getPlatformID(): PlatformID;
-      getAndroidCommand(): string;
-      getADBCommand(): string;
-      refreshAndroidTargets(): void;
-      getAndroidTargets(): string[];
-      newBuild(project: Project): BuildBase;
-
-   }
-
-   export class PlatformIOS extends Platform {
-
-      name: string;
-      platformID: PlatformID;
-      license: boolean;
-
-      constructor();
-
-      getName(): string;
-      getPlatformID(): PlatformID;
-      newBuild(project: Project): BuildBase;
-      parseProvisionAppIdentifierPrefix(provisionFile: string): string;
-      getLicense(): boolean;
-
-   }
-
-   export class PlatformMac extends Platform {
-
-      name: string;
-      platformID: PlatformID;
-      license: boolean;
-
-      constructor();
-
-      getName(): string;
-      getPlatformID(): PlatformID;
-      newBuild(project: Project): BuildBase;
-      getLicense(): boolean;
-
-   }
-
-   export class PlatformWeb extends Platform {
-
-      name: string;
-      platformID: PlatformID;
-      license: boolean;
-
-      constructor();
-
-      getName(): string;
-      getPlatformID(): PlatformID;
-      newBuild(project: Project): BuildBase;
-      getLicense(): boolean;
-
-   }
-
-   export class PlatformWindows extends Platform {
-
-      name: string;
-      platformID: PlatformID;
-      license: boolean;
-
-      constructor();
-
-      getName(): string;
-      getPlatformID(): PlatformID;
-      newBuild(project: Project): BuildBase;
-      getLicense(): boolean;
-
-   }
-
-   export class Command extends Atomic.AObject {
-
-      constructor();
-
-      parse(command: string): boolean;
-      run(): void;
-      finished(): void;
-      error(errorMsg: string): void;
-      cancel(): void;
-      requiresProjectLoad(): boolean;
-      requiresLicenseValidation(): boolean;
-
-   }
-
-   export class PlayCmd extends Command {
-
-      constructor();
-
-      run(): void;
-
-   }
-
-   export class OpenAssetImporter extends Atomic.AObject {
-
-      errorMessage: string;
-      importNode: Atomic.Node;
-      startTime: number;
-      endTime: number;
-      scale: number;
-      exportAnimations: boolean;
-      verboseLog: boolean;
-
-      constructor();
-
-      load(assetPath: string): boolean;
-      getErrorMessage(): string;
-      exportModel(outName: string, animName?: string, animationOnly?: boolean): boolean;
-      setImportNode(node: Atomic.Node): void;
-      setStartTime(startTime: number): void;
-      setEndTime(endTime: number): void;
-      setScale(scale: number): void;
-      setExportAnimations(exportAnimations: boolean): void;
-      setVerboseLog(verboseLog: boolean): void;
-
-   }
-
-   export class Asset extends Atomic.AObject {
-
-      guid: string;
-      name: string;
-      path: string;
-      extension: string;
-      relativePath: string;
-      cachePath: string;
-      importerType: string;
-      importerTypeName: string;
-      importer: AssetImporter;
-      parent: Asset;
-      dirty: boolean;
-      fileTimestamp: number;
-      dotAssetFilename: string;
-
-      // Construct.
-      constructor();
-
-      import(): boolean;
-      preload(): boolean;
-      setPath(path: string): boolean;
-      getGUID(): string;
-      getName(): string;
-      getPath(): string;
-      getExtension(): string;
-      // Get the path relative to project
-      getRelativePath(): string;
-      getCachePath(): string;
-      getResource(typeName?: string): Atomic.Resource;
-      getImporterType(): string;
-      getImporterTypeName(): string;
-      getImporter(): AssetImporter;
-      postImportError(message: string): void;
-      getParent(): Asset;
-      setDirty(dirty: boolean): void;
-      isDirty(): boolean;
-      // Get the last timestamp as seen by the AssetDatabase
-      getFileTimestamp(): number;
-      // Sets the time stamp to the asset files current time
-      updateFileTimestamp(): void;
-      getDotAssetFilename(): string;
-      // Rename the asset, which depending on the asset type may be nontrivial
-      rename(newName: string): boolean;
-      // Move the asset, which depending on the asset type may be nontrivial
-      move(newPath: string): boolean;
-      isFolder(): boolean;
-      load(): boolean;
-      save(): boolean;
-      // Instantiate a node from the asset
-      instantiateNode(parent: Atomic.Node, name: string): Atomic.Node;
-
-   }
-
-   export class AssetDatabase extends Atomic.AObject {
-
-      cachePath: string;
-
-      // Construct.
-      constructor();
-
-      getAssetByGUID(guid: string): Asset;
-      getAssetByPath(path: string): Asset;
-      getAssetByCachePath(cachePath: string): Asset;
-      generateAssetGUID(): string;
-      registerGUID(guid: string): void;
-      getCachePath(): string;
-      deleteAsset(asset: Asset): void;
-      scan(): void;
-      reimportAllAssets(): void;
-      reimportAllAssetsInDirectory(directoryPath: string): void;
-      getResourceImporterName(resourceTypeName: string): string;
-      getDotAssetFilename(path: string): string;
-      getFolderAssets(folder:string):ToolCore.Asset[];
-      getAssetsByImporterType(importerType:string, resourceType:string):ToolCore.Asset[];
-
-   }
-
-   export class AssetImporter extends Atomic.AObject {
-
-      asset: Asset;
-
-      // Construct.
-      constructor(asset: Asset);
-
-      setDefaults(): void;
-      preload(): boolean;
-      getAsset(): Asset;
-      getResource(typeName?: string): Atomic.Resource;
-      requiresCacheFile(): boolean;
-      // Instantiate a node from the asset
-      instantiateNode(parent: Atomic.Node, name: string): Atomic.Node;
-      rename(newName: string): boolean;
-      move(newPath: string): boolean;
-
-   }
-
-   export class AudioImporter extends AssetImporter {
-
-      // Construct.
-      constructor(asset: Asset);
-
-      setDefaults(): void;
-      getResource(typeName?: string): Atomic.Resource;
-
-   }
-
-   export class JSONImporter extends AssetImporter {
-
-      // Construct.
-      constructor(asset: Asset);
-
-      setDefaults(): void;
-      getResource(typeName?: string): Atomic.Resource;
-
-   }
-
-   export class JavascriptImporter extends AssetImporter {
-
-      // Construct.
-      constructor(asset: Asset);
-
-      setDefaults(): void;
-      isComponentFile(): boolean;
-      getResource(typeName?: string): Atomic.Resource;
-
-   }
-
-   export class MaterialImporter extends AssetImporter {
-
-      // Construct.
-      constructor(asset: Asset);
-
-      setDefaults(): void;
-      saveMaterial(): void;
-      getResource(typeName?: string): Atomic.Resource;
-
-   }
-
-   export class AnimationImportInfo extends Atomic.AObject {
-
-      name: string;
-      startTime: number;
-      endTime: number;
-
-      constructor();
-
-      getName(): string;
-      getStartTime(): number;
-      getEndTime(): number;
-      setName(name: string): void;
-      setStartTime(time: number): void;
-      setEndTime(time: number): void;
-
-   }
-
-   export class ModelImporter extends AssetImporter {
-
-      scale: number;
-      importAnimations: boolean;
-      animationCount: number;
-
-      // Construct.
-      constructor(asset: Asset);
-
-      setDefaults(): void;
-      getScale(): number;
-      setScale(scale: number): void;
-      getImportAnimations(): boolean;
-      setImportAnimations(importAnimations: boolean): void;
-      getAnimationCount(): number;
-      setAnimationCount(count: number): void;
-      getResource(typeName?: string): Atomic.Resource;
-      getAnimationInfo(index: number): AnimationImportInfo;
-      // Instantiate a node from the asset
-      instantiateNode(parent: Atomic.Node, name: string): Atomic.Node;
-      getAnimations():Atomic.Animation[];
-
-   }
-
-   export class NETAssemblyImporter extends AssetImporter {
-
-      // Construct.
-      constructor(asset: Asset);
-
-      setDefaults(): void;
-      getResource(typeName?: string): Atomic.Resource;
-
-   }
-
-   export class PEXImporter extends AssetImporter {
-
-      // Construct.
-      constructor(asset: Asset);
-
-      setDefaults(): void;
-      getResource(typeName: string): Atomic.Resource;
-
-   }
-
-   export class PrefabImporter extends AssetImporter {
-
-      // Construct.
-      constructor(asset: Asset);
-
-      setDefaults(): void;
-      preload(): boolean;
-      // Instantiate a node from the asset
-      instantiateNode(parent: Atomic.Node, name: string): Atomic.Node;
-
-   }
-
-   export class SpriterImporter extends AssetImporter {
-
-      // Construct.
-      constructor(asset: Asset);
-
-      setDefaults(): void;
-      getResource(typeName?: string): Atomic.Resource;
-      instantiateNode(parent: Atomic.Node, name: string): Atomic.Node;
-
-   }
-
-   export class TextureImporter extends AssetImporter {
-
-      // Construct.
-      constructor(asset: Asset);
-
-      setDefaults(): void;
-      getResource(typeName?: string): Atomic.Resource;
-      instantiateNode(parent: Atomic.Node, name: string): Atomic.Node;
-
-   }
-
-   export class LicenseSystem extends Atomic.AObject {
-
-      sourceBuild: boolean;
-      licenseWindows: boolean;
-      licenseMac: boolean;
-      licenseAndroid: boolean;
-      licenseIOS: boolean;
-      licenseHTML5: boolean;
-      licenseModule3D: boolean;
-      key: string;
-      email: string;
-
-      // Construct.
-      constructor();
-
-      initialize(): void;
-      getSourceBuild(): boolean;
-      getLicenseWindows(): boolean;
-      getLicenseMac(): boolean;
-      getLicenseAndroid(): boolean;
-      getLicenseIOS(): boolean;
-      getLicenseHTML5(): boolean;
-      getLicenseModule3D(): boolean;
-      // Returns whether there are any platform licenses available
-      isStandardLicense(): boolean;
-      // Returns true if request to deactivate is made
-      deactivate(): boolean;
-      resetLicense(): void;
-      loadLicense(): boolean;
-      // Basic key validation
-      validateKey(key: string): boolean;
-      // Activate on server
-      requestServerActivation(key: string): void;
-      getKey(): string;
-      generateMachineID(): string;
-      getEmail(): string;
-      licenseAgreementConfirmed(): void;
-
-   }
-
-   export class BuildAndroid extends BuildBase {
-
-      buildSubfolder: string;
-
-      constructor(project: Project);
-
-      build(buildPath: string): void;
-      getBuildSubfolder(): string;
-
-   }
-
-   export class BuildBase extends Atomic.AObject {
-
-      buildSubfolder: string;
-
-      constructor(project: Project, platform: PlatformID);
-
-      build(buildPath: string): void;
-      useResourcePackager(): boolean;
-      getBuildSubfolder(): string;
-      addResourceDir(dir: string): void;
-      buildLog(message: string, sendEvent?: boolean): void;
-      buildWarn(warning: string, sendEvent?: boolean): void;
-      buildError(error: string, sendEvent?: boolean): void;
-      // Fail the current build
-      failBuild(message: string): void;
-
-   }
-
-   export class BuildIOS extends BuildBase {
-
-      buildSubfolder: string;
-
-      constructor(project: Project);
-
-      getBuildSubfolder(): string;
-      build(buildPath: string): void;
-
-   }
-
-   export class BuildMac extends BuildBase {
-
-      buildSubfolder: string;
-
-      constructor(project: Project);
-
-      getBuildSubfolder(): string;
-      build(buildPath: string): void;
-
-   }
-
-   export class BuildSystem extends Atomic.AObject {
-
-      buildPath: string;
-
-      // Construct.
-      constructor();
-
-      setBuildPath(path: string): void;
-      getBuildPath(): string;
-      queueBuild(buildBase: BuildBase): void;
-      startNextBuild(): boolean;
-      buildComplete(platform: PlatformID, buildFolder: string, success?: boolean, buildMessage?: string): void;
-
-   }
-
-   export class BuildWeb extends BuildBase {
-
-      buildSubfolder: string;
-
-      constructor(project: Project);
-
-      build(buildPath: string): void;
-      getBuildSubfolder(): string;
-
-   }
-
-   export class BuildWindows extends BuildBase {
-
-      buildSubfolder: string;
-
-      constructor(project: Project);
-
-      getBuildSubfolder(): string;
-      build(buildPath: string): void;
-
-   }
-
-   export class Subprocess extends Atomic.AObject {
-
-      // Construct.
-      constructor();
-
-
-   }
-
-   export class SubprocessSystem extends Atomic.AObject {
-
-      // Construct.
-      constructor();
-
-      launch(command: string, args: string[], initialDirectory?: string): Subprocess;
-
-   }
-
-
-
-}

+ 0 - 148
EditorPluginExample/typings/Atomic/WebView.d.ts

@@ -1,148 +0,0 @@
-//////////////////////////////////////////////////////////
-// IMPORTANT: THIS FILE IS GENERATED, CHANGES WILL BE LOST
-//////////////////////////////////////////////////////////
-
-// Atomic TypeScript Definitions
-
-/// <reference path="Atomic.d.ts" />
-
-declare module WebView {
-
-
-//----------------------------------------------------
-// MODULE: WebView
-//----------------------------------------------------
-
-
-   export class UIWebView extends Atomic.UIWidget {
-
-      webClient: WebClient;
-      webTexture2D: WebTexture2D;
-
-      constructor(initialURL?: string);
-
-      // Get the widget's WebClient
-      getWebClient(): WebClient;
-      // Get the WebTexture in use by the WebView
-      getWebTexture2D(): WebTexture2D;
-
-   }
-
-   export class WebBrowserHost extends Atomic.AObject {
-
-      // Construct.
-      constructor();
-
-      // Set global property object values, available as read only on page
-      static setGlobalBoolProperty(globalVar: string, property: string, value: boolean): void;
-      static setGlobalStringProperty(globalVar: string, property: string, value: string): void;
-      static setGlobalNumberProperty(globalVar: string, property: string, value: number): void;
-
-   }
-
-   export class WebClient extends Atomic.AObject {
-
-      webRenderHandler: WebRenderHandler;
-
-      // Construct.
-      constructor();
-
-      // Create the browser, call only once initialized with handlers
-      createBrowser(initialURL: string, width: number, height: number): boolean;
-      // Set the browser's width and height
-      setSize(width: number, height: number): void;
-      // Send a mouse click event to the browser
-      sendMouseClickEvent(x: number, y: number, button: number, mouseUp: boolean, modifier: number, clickCount?: number): void;
-      // Send a mouse press event to the browser
-      sendMousePressEvent(x: number, y: number, button?: number, modifier?: number, clickCount?: number): void;
-      // Send a mouse move event to the browser
-      sendMouseMoveEvent(x: number, y: number, modifier: number, mouseLeave?: boolean): void;
-      // Send a mouse wheel event to the browser
-      sendMouseWheelEvent(x: number, y: number, modifier: number, deltaX: number, deltaY: number): void;
-      // Send a focus event to the browser
-      sendFocusEvent(focus?: boolean): void;
-      // Invoke the Cut shortcut on the browser's main frame
-      shortcutCut(): void;
-      // Invoke the Copy shortcut on the browser's main frame
-      shortcutCopy(): void;
-      // Invoke the Paste shortcut on the browser's main frame
-      shortcutPaste(): void;
-      // Invoke the SelectAll shortcut on the browser's main frame
-      shortcutSelectAll(): void;
-      // Invoke the Undo shortcut on the browser's main frame
-      shortcutUndo(): void;
-      // Invoke the Redo shortcut on the browser's main frame
-      shortcutRedo(): void;
-      // Invoke the Delete shortcut on the browser's main frame
-      shortcutDelete(): void;
-      // Execute some JavaScript in the browser
-      executeJavaScript(script: string): void;
-      // Eval some JavaScript in the browser (async return value referenced by evalID)
-      evalJavaScript(evalID: number, script: string): void;
-      // Returns true if the page is currently loading
-      isLoading(): boolean;
-      // Load the specified url into the main frame of the browser
-      loadURL(url: string): void;
-      // Load html source into main frame of browser
-      loadString(source: string, url?: string): void;
-      // Go back in page history
-      goBack(): void;
-      // Go forward in page history
-      goForward(): void;
-      // Reload the current page
-      reload(): void;
-      // Set the render handler for this client
-      setWebRenderHandler(handler: WebRenderHandler): void;
-
-   }
-
-   export class WebRenderHandler extends Atomic.AObject {
-
-      width: number;
-      height: number;
-      webClient: WebClient;
-
-      // Construct.
-      constructor();
-
-      // Get the current renderer width
-      getWidth(): number;
-      // Get the current renderer height
-      getHeight(): number;
-      // Get the WebClient associated with the render handler
-      getWebClient(): WebClient;
-      // Set the dimensions of the render handler
-      setSize(width: number, height: number): void;
-      // Set the render handlers WebClient
-      setWebClient(webClient: WebClient): void;
-
-   }
-
-   export class WebTexture2D extends WebRenderHandler {
-
-      width: number;
-      height: number;
-      texture2D: Atomic.Texture2D;
-      clearColor: Atomic.Color;
-
-      // Construct.
-      constructor();
-
-      // Get the current width of the texture
-      getWidth(): number;
-      // Get the current height of the texture
-      getHeight(): number;
-      // Get the Texture2D associated with the WebTexture2D
-      getTexture2D(): Atomic.Texture2D;
-      // get the clear color for the WebTexture
-      getClearColor(): Atomic.Color;
-      // Set the dimensions of the texture
-      setSize(width: number, height: number): void;
-      // Set the clear color for the WebTexture
-      setClearColor(color: Atomic.Color): void;
-
-   }
-
-
-
-}

+ 0 - 17
EditorPluginExample/typings/Atomic/duktape.d.ts

@@ -1,17 +0,0 @@
-// Duktape built-ins
-
-// extracted from lib.d.ts
-declare interface Console {
-    log(message?: any, ...optionalParams: any[]): void;
-}
-
-declare var console: Console;
-
-// Duktape require isn't recognized as a function, but can be used as one
-declare function require(filename: string): any;
-
-declare interface DuktapeModule {
-    modSearch(id: string, require, exports, module);
-}
-
-declare var Duktape: DuktapeModule;

Some files were not shown because too many files changed in this diff