Window.pkg 1.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. $#include "Window.h"
  2. enum WindowDragMode
  3. {
  4. DRAG_NONE,
  5. DRAG_MOVE,
  6. DRAG_RESIZE_TOPLEFT,
  7. DRAG_RESIZE_TOP,
  8. DRAG_RESIZE_TOPRIGHT,
  9. DRAG_RESIZE_RIGHT,
  10. DRAG_RESIZE_BOTTOMRIGHT,
  11. DRAG_RESIZE_BOTTOM,
  12. DRAG_RESIZE_BOTTOMLEFT,
  13. DRAG_RESIZE_LEFT
  14. };
  15. class Window : public BorderImage
  16. {
  17. public:
  18. Window(Context* context);
  19. virtual ~Window();
  20. void SetMovable(bool enable);
  21. void SetResizable(bool enable);
  22. void SetResizeBorder(const IntRect& rect);
  23. void SetModal(bool modal);
  24. void SetModalShadeColor(const Color& color);
  25. void SetModalFrameColor(const Color& color);
  26. void SetModalFrameSize(const IntVector2& size);
  27. bool IsMovable() const;
  28. bool IsResizable() const;
  29. const IntRect& GetResizeBorder() const;
  30. bool IsModal() const;
  31. const Color& GetModalShadeColor() const;
  32. const Color& GetModalFrameColor() const;
  33. const IntVector2& GetModalFrameSize() const;
  34. // Properties:
  35. tolua_property__is_set bool movable;
  36. tolua_property__is_set bool resizable;
  37. tolua_property__get_set const IntRect& resizeBorder;
  38. tolua_property__is_set bool modal;
  39. tolua_property__get_set const Color& modalShadeColor;
  40. tolua_property__get_set const Color& modalFrameColor;
  41. tolua_property__get_set const IntVector2& modalFrameSize;
  42. };