|
|
1.1 ! root 1: // ! 2: // nono ! 3: // Copyright (C) 2022 nono project ! 4: // Licensed under nono-license.txt ! 5: // ! 6: ! 7: // ! 8: // ログレベル設定ウィンドウ ! 9: // ! 10: ! 11: #pragma once ! 12: ! 13: #include "wxtextpanel.h" ! 14: #include "wxsubwindow.h" ! 15: ! 16: class WXLogSettingPanel : public WXTextPanel ! 17: { ! 18: using inherited = WXTextPanel; ! 19: ! 20: static const int Padding = 3; ! 21: ! 22: public: ! 23: WXLogSettingPanel(wxWindow *parent); ! 24: ~WXLogSettingPanel() override; ! 25: ! 26: void FontChanged(); ! 27: void Draw(); ! 28: ! 29: private: ! 30: inline int Col2PX(int col) const; ! 31: inline int Row2PY(int row) const; ! 32: inline int PX2Col(int px) const; ! 33: inline int PY2Row(int py) const; ! 34: ! 35: void DrawButton(const Rect& rect, bool button_pressed); ! 36: void OnLeftDown(wxMouseEvent&); ! 37: void OnLeftUp(wxMouseEvent&); ! 38: ! 39: std::vector<Object *> objs {}; ! 40: ! 41: int maxnamelen {}; ! 42: ! 43: // 押されているボタン ! 44: int pressed {}; ! 45: ! 46: wxDECLARE_EVENT_TABLE(); ! 47: }; ! 48: ! 49: class WXLogSettingWindow : public WXSubWindow ! 50: { ! 51: using inherited = WXSubWindow; ! 52: ! 53: public: ! 54: WXLogSettingWindow(wxWindow *); ! 55: ~WXLogSettingWindow() override; ! 56: ! 57: private: ! 58: WXLogSettingPanel *panel {}; ! 59: };
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.