mirror of
https://github.com/libretro/bsnes-libretro.git
synced 2024-11-27 02:50:32 +00:00
903d1e4012
* GB: integrated SameBoy v0.12.1 by Lior Halphon * SFC: added HG51B169 (Cx4) math tables into bsnes binary
41 lines
739 B
C++
Executable File
41 lines
739 B
C++
Executable File
#if defined(Hiro_PopupMenu)
|
|
|
|
namespace hiro {
|
|
|
|
auto pPopupMenu::construct() -> void {
|
|
qtPopupMenu = new QMenu;
|
|
_setState();
|
|
}
|
|
|
|
auto pPopupMenu::destruct() -> void {
|
|
delete qtPopupMenu;
|
|
qtPopupMenu = nullptr;
|
|
}
|
|
|
|
auto pPopupMenu::append(sAction action) -> void {
|
|
_setState();
|
|
}
|
|
|
|
auto pPopupMenu::remove(sAction action) -> void {
|
|
_setState();
|
|
}
|
|
|
|
auto pPopupMenu::setFont(const Font& font) -> void {
|
|
_setState();
|
|
}
|
|
|
|
auto pPopupMenu::setVisible(bool visible) -> void {
|
|
if(visible) qtPopupMenu->popup(QCursor::pos());
|
|
}
|
|
|
|
auto pPopupMenu::_setState() -> void {
|
|
qtPopupMenu->setFont(pFont::create(self().font(true)));
|
|
for(auto& action : state().actions) {
|
|
if(auto self = action->self()) self->_setState();
|
|
}
|
|
}
|
|
|
|
}
|
|
|
|
#endif
|