@ObjListClass.h 1.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. /******************************************************************************/
  2. /******************************************************************************/
  3. class ObjListClass : ClosableWindow
  4. {
  5. class Elm
  6. {
  7. bool opened;
  8. uint type;
  9. flt offset;
  10. Obj *obj;
  11. Str group, obj_type, base;
  12. Vec pos;
  13. Memx<Elm> children;
  14. public:
  15. Elm();
  16. };
  17. bool _changed;
  18. Button refresh;
  19. Text tgroup, tparams, tgrass;
  20. Tabs group;
  21. TextLine filter;
  22. CheckBox params, grass;
  23. Region region;
  24. List<Elm> list;
  25. Memx<Elm> data;
  26. Memc<Str> opened;
  27. TextBlack ts, ts2;
  28. static void GroupChanged(ObjListClass &ol);
  29. static void FilterChanged(ObjListClass &ol);
  30. static void Refresh(ObjListClass &ol);
  31. static void Hide(ObjListClass &ol);
  32. static void SelChanged(ObjListClass &ol);
  33. void setChanged();
  34. ObjListClass& create();
  35. static int CompareOL(C Elm &elm, C Str &group);
  36. Elm& dataNew(C Str &group);
  37. static Str ReplaceSlash(C Str &str);
  38. static bool SetVisible(Memt<bool> &visible, C Str&filter, bool filter_params, bool hide_grass, Memx<Elm> &data, bool parent_visible=true);
  39. void setVisible();
  40. static void SetType(Memx<Elm> &data, uint type);
  41. void set();
  42. void selChanged();
  43. virtual Rect sizeLimit()C override;
  44. C Rect& rect()C;
  45. virtual Window& rect(C Rect &rect)override;
  46. virtual void update(C GuiPC &gpc)override;
  47. void removed(Obj &obj);
  48. public:
  49. ObjListClass();
  50. };
  51. /******************************************************************************/
  52. /******************************************************************************/
  53. extern ObjListClass ObjList;
  54. /******************************************************************************/