Selection.cs 2.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768
  1. using System.Runtime.CompilerServices;
  2. using BansheeEngine;
  3. namespace BansheeEditor
  4. {
  5. public sealed class Selection
  6. {
  7. public static SceneObject[] sceneObjects
  8. {
  9. get
  10. {
  11. SceneObject[] selection;
  12. Internal_GetSceneObjectSelection(out selection);
  13. return selection;
  14. }
  15. set
  16. {
  17. Internal_SetSceneObjectSelection(value);
  18. }
  19. }
  20. public static string[] resourceUUIDs
  21. {
  22. get
  23. {
  24. string[] selection;
  25. Internal_GetResourceUUIDSelection(out selection);
  26. return selection;
  27. }
  28. set
  29. {
  30. Internal_SetResourceUUIDSelection(value);
  31. }
  32. }
  33. public static string[] resourcePaths
  34. {
  35. get
  36. {
  37. string[] selection;
  38. Internal_GetResourcePathSelection(out selection);
  39. return selection;
  40. }
  41. set
  42. {
  43. Internal_SetResourcePathSelection(value);
  44. }
  45. }
  46. [MethodImpl(MethodImplOptions.InternalCall)]
  47. internal static extern void Internal_GetSceneObjectSelection(out SceneObject[] selection);
  48. [MethodImpl(MethodImplOptions.InternalCall)]
  49. internal static extern void Internal_SetSceneObjectSelection(SceneObject[] selection);
  50. [MethodImpl(MethodImplOptions.InternalCall)]
  51. internal static extern void Internal_GetResourceUUIDSelection(out string[] selection);
  52. [MethodImpl(MethodImplOptions.InternalCall)]
  53. internal static extern void Internal_SetResourceUUIDSelection(string[] selection);
  54. [MethodImpl(MethodImplOptions.InternalCall)]
  55. internal static extern void Internal_GetResourcePathSelection(out string[] selection);
  56. [MethodImpl(MethodImplOptions.InternalCall)]
  57. internal static extern void Internal_SetResourcePathSelection(string[] selection);
  58. }
  59. }