You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

31 lines
544B

  1. #pragma once
  2. #include <ui/common.hpp>
  3. #include <ui/Menu.hpp>
  4. #include <ui/MenuEntry.hpp>
  5. #include <app.hpp>
  6. namespace rack {
  7. namespace ui {
  8. struct MenuItem : MenuEntry {
  9. std::string text;
  10. std::string rightText;
  11. bool disabled = false;
  12. bool active = false;
  13. void draw(const DrawArgs& args) override;
  14. void step() override;
  15. void onEnter(const event::Enter& e) override;
  16. void onDragDrop(const event::DragDrop& e) override;
  17. void doAction();
  18. virtual Menu* createChildMenu() {
  19. return NULL;
  20. }
  21. };
  22. } // namespace ui
  23. } // namespace rack