EditorSettings.cs 4.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Runtime.CompilerServices;
  5. using System.Text;
  6. using System.Threading.Tasks;
  7. using BansheeEngine;
  8. namespace BansheeEditor
  9. {
  10. internal static class EditorSettings
  11. {
  12. public static bool MoveHandleSnapActive
  13. {
  14. get { return Internal_GetMoveHandleSnapActive(); }
  15. set { Internal_SetMoveHandleSnapActive(value); }
  16. }
  17. public static bool RotateHandleSnapActive
  18. {
  19. get { return Internal_GetRotateHandleSnapActive(); }
  20. set { Internal_SetRotateHandleSnapActive(value); }
  21. }
  22. public static float MoveHandleSnapAmount
  23. {
  24. get { return Internal_GetMoveHandleSnapAmount(); }
  25. set { Internal_SetMoveHandleSnapAmount(value); }
  26. }
  27. public static Degree RotateHandleSnapAmount
  28. {
  29. get { return Internal_GetRotateHandleSnapAmount(); }
  30. set { Internal_SetRotateHandleSnapAmount(value.Degrees); }
  31. }
  32. public static float DefaultHandleSize
  33. {
  34. get { return Internal_GetDefaultHandleSize(); }
  35. set { Internal_SetDefaultHandleSize(value); }
  36. }
  37. public static SceneViewTool ActiveSceneTool
  38. {
  39. get { return (SceneViewTool)Internal_GetActiveSceneTool(); }
  40. set { Internal_SetActiveSceneTool((int)value); }
  41. }
  42. public static HandleCoordinateMode ActiveCoordinateMode
  43. {
  44. get { return (HandleCoordinateMode)Internal_GetActiveCoordinateMode(); }
  45. set { Internal_SetActiveCoordinateMode((int)value); }
  46. }
  47. public static HandlePivotMode ActivePivotMode
  48. {
  49. get { return (HandlePivotMode)Internal_GetActivePivotMode(); }
  50. set { Internal_SetActivePivotMode((int)value); }
  51. }
  52. public static int Hash
  53. {
  54. get { return Internal_GetHash(); }
  55. }
  56. [MethodImpl(MethodImplOptions.InternalCall)]
  57. private static extern bool Internal_GetMoveHandleSnapActive();
  58. [MethodImpl(MethodImplOptions.InternalCall)]
  59. private static extern void Internal_SetMoveHandleSnapActive(bool value);
  60. [MethodImpl(MethodImplOptions.InternalCall)]
  61. private static extern bool Internal_GetRotateHandleSnapActive();
  62. [MethodImpl(MethodImplOptions.InternalCall)]
  63. private static extern void Internal_SetRotateHandleSnapActive(bool value);
  64. [MethodImpl(MethodImplOptions.InternalCall)]
  65. private static extern float Internal_GetMoveHandleSnapAmount();
  66. [MethodImpl(MethodImplOptions.InternalCall)]
  67. private static extern void Internal_SetMoveHandleSnapAmount(float value);
  68. [MethodImpl(MethodImplOptions.InternalCall)]
  69. private static extern float Internal_GetRotateHandleSnapAmount();
  70. [MethodImpl(MethodImplOptions.InternalCall)]
  71. private static extern void Internal_SetRotateHandleSnapAmount(float value);
  72. [MethodImpl(MethodImplOptions.InternalCall)]
  73. private static extern float Internal_GetDefaultHandleSize();
  74. [MethodImpl(MethodImplOptions.InternalCall)]
  75. private static extern void Internal_SetDefaultHandleSize(float value);
  76. [MethodImpl(MethodImplOptions.InternalCall)]
  77. private static extern int Internal_GetActiveSceneTool();
  78. [MethodImpl(MethodImplOptions.InternalCall)]
  79. private static extern void Internal_SetActiveSceneTool(int value);
  80. [MethodImpl(MethodImplOptions.InternalCall)]
  81. private static extern int Internal_GetActiveCoordinateMode();
  82. [MethodImpl(MethodImplOptions.InternalCall)]
  83. private static extern void Internal_SetActiveCoordinateMode(int value);
  84. [MethodImpl(MethodImplOptions.InternalCall)]
  85. private static extern int Internal_GetActivePivotMode();
  86. [MethodImpl(MethodImplOptions.InternalCall)]
  87. private static extern void Internal_SetActivePivotMode(int value);
  88. [MethodImpl(MethodImplOptions.InternalCall)]
  89. private static extern int Internal_GetHash();
  90. }
  91. }