GUIScrollArea.cs 1.1 KB

123456789101112131415161718192021222324252627282930313233
  1. using System.Runtime.CompilerServices;
  2. namespace BansheeEngine
  3. {
  4. public enum ScrollBarType
  5. {
  6. ShowIfDoesntFit,
  7. AlwaysShow,
  8. NeverShow
  9. };
  10. public sealed class GUIScrollArea : GUIElement
  11. {
  12. private GUILayout _mainLayout;
  13. public GUILayout layout
  14. {
  15. get { return _mainLayout; }
  16. }
  17. internal GUIScrollArea(GUILayout parentLayout, ScrollBarType vertBarType, ScrollBarType horzBarType,
  18. GUIElementStyle scrollBarStyle, GUIElementStyle scrollAreaStyle, params GUIOption[] options)
  19. :base(parentLayout)
  20. {
  21. Internal_CreateInstance(this, parentLayout, vertBarType, horzBarType, scrollBarStyle, scrollAreaStyle, options);
  22. _mainLayout = new GUILayoutY(this);
  23. }
  24. [MethodImpl(MethodImplOptions.InternalCall)]
  25. private static extern void Internal_CreateInstance(GUIScrollArea instance, GUILayout parentLayout, ScrollBarType vertBarType, ScrollBarType horzBarType,
  26. GUIElementStyle scrollBarStyle, GUIElementStyle scrollAreaStyle, params GUIOption[] options);
  27. }
  28. }