AtomicWork.d.ts 2.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109
  1. /// <reference path="Atomic.d.ts" />
  2. /// <reference path="ToolCore.d.ts" />
  3. /// <reference path="Editor.d.ts" />
  4. declare module Atomic {
  5. export function print(...args:any[]);
  6. export var platform:string;
  7. export interface PathInfo {
  8. pathName: string;
  9. fileName: string;
  10. ext: string;
  11. }
  12. /*
  13. export enum UIWidgetEventType {
  14. EVENT_TYPE_CLICK,
  15. EVENT_TYPE_LONG_CLICK,
  16. EVENT_TYPE_POINTER_DOWN,
  17. EVENT_TYPE_POINTER_UP,
  18. EVENT_TYPE_POINTER_MOVE,
  19. EVENT_TYPE_RIGHT_POINTER_DOWN,
  20. EVENT_TYPE_RIGHT_POINTER_UP,
  21. EVENT_TYPE_WHEEL,
  22. EVENT_TYPE_CHANGED,
  23. EVENT_TYPE_KEY_DOWN,
  24. EVENT_TYPE_KEY_UP,
  25. EVENT_TYPE_SHORTCUT,
  26. EVENT_TYPE_CONTEXT_MENU,
  27. EVENT_TYPE_FILE_DROP,
  28. EVENT_TYPE_TAB_CHANGED,
  29. EVENT_TYPE_CUSTOM
  30. }
  31. */
  32. export interface UIWidgetEvent {
  33. handler: UIWidget;
  34. target: UIWidget;
  35. type: number; /*UIWidgetEventType*/
  36. x: number;
  37. y: number;
  38. deltax: number;
  39. deltay: number;
  40. count: number;
  41. key: number;
  42. specialkey: number;
  43. modifierkeys: number;
  44. refid: string;
  45. touch: boolean;
  46. }
  47. export interface UIWidgetDeletedEvent {
  48. widget: UIWidget;
  49. }
  50. export interface AttributeInfo {
  51. type:VariantType;
  52. name:string;
  53. mode:number; // AM_*
  54. defaultValue:string;
  55. enumNames:string[];
  56. }
  57. export interface ShaderParameter {
  58. name:string;
  59. value:any;
  60. valueString:string;
  61. typeName:string;
  62. type:VariantType;
  63. }
  64. export function getArguments(): Array<string>;
  65. export function getEngine(): Engine;
  66. export function getInput(): Input;
  67. export function getGraphics(): Graphics;
  68. export function getFileSystem(): FileSystem;
  69. export function getResourceCache(): ResourceCache;
  70. export function getParentPath(path: string): string;
  71. export function addTrailingSlash(path: string): string;
  72. export function getExtension(path: string): string;
  73. export function splitPath(path: string): PathInfo;
  74. }
  75. declare module Editor {
  76. export function getPreferences() : AEPreferences;
  77. }
  78. declare module ToolCore {
  79. export function getToolEnvironment(): ToolEnvironment;
  80. export function getToolSystem(): ToolSystem;
  81. export function getAssetDatabase(): AssetDatabase;
  82. export function getLicenseSystem(): LicenseSystem;
  83. }