forked from NaiJi/project-kyoku
You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
26 lines
705 B
C
26 lines
705 B
C
3 years ago
|
#pragma once
|
||
|
|
||
|
#include "button.h"
|
||
|
|
||
|
class MenuDrop;
|
||
|
|
||
|
class CascadeMenuButton : public Button
|
||
|
{
|
||
|
public:
|
||
2 years ago
|
explicit CascadeMenuButton(const std::string& text, const std::shared_ptr<kku::CoreFactory>& factory, unsigned int font_size = 12);
|
||
|
virtual void input(const kku::SystemEvent& event) override final;
|
||
|
virtual void setRect(const kku::Area<float>& rect) override final;
|
||
3 years ago
|
|
||
|
void setSubmenu(const std::shared_ptr<MenuDrop>& submenu);
|
||
3 years ago
|
const std::shared_ptr<MenuDrop> submenu() const;
|
||
3 years ago
|
void resetRect();
|
||
2 years ago
|
void setFillColors(kku::Color&& idle_color, kku::Color&& hover_color);
|
||
3 years ago
|
|
||
|
private:
|
||
|
std::shared_ptr<MenuDrop> _submenu;
|
||
3 years ago
|
|
||
2 years ago
|
kku::Color _color_idle;
|
||
|
kku::Color _color_hover;
|
||
3 years ago
|
};
|
||
|
|