#pragma once #include #include #include #include "../uw/background.hh" namespace fe { class ClickableBox : public Fl_Box { public: ClickableBox(int X, int Y, int W, int H, const char *L = 0) : Fl_Box(X, Y, W, H, L), imagePath{ "" }, isSelected{ false } {} void setImagePath(const std::string &path) { imagePath = path; } std::string getImagePath() const { return imagePath; } int handle(int event) override; void draw() override; private: std::string imagePath; std::unique_ptr background; bool isSelected; static ClickableBox *lastSelected; void alterXinitrc(const std::string &npath); }; }