mirror of
https://github.com/FunKey-Project/RetroFE.git
synced 2025-12-12 17:58:53 +01:00
Allow menus of level n to finish the onMenuEnter animation at level n-1. This allows themes to e.g. fade out a collection menu during the onMenuEnter animation sequence of the Main collection.
This commit is contained in:
parent
51d63e1b10
commit
f5c7808c80
@ -648,14 +648,17 @@ void Page::update(float dt)
|
||||
if(*it) (*it)->update(dt);
|
||||
}
|
||||
|
||||
// many nodes still have handles on the collection info. We need to delete
|
||||
// them once everything is done using them
|
||||
}
|
||||
|
||||
|
||||
void Page::cleanup()
|
||||
{
|
||||
std::list<MenuInfo_S>::iterator del = deleteCollections_.begin();
|
||||
|
||||
while(del != deleteCollections_.end())
|
||||
{
|
||||
MenuInfo_S &info = *del;
|
||||
if(info.queueDelete && info.menu && info.menu->isIdle())
|
||||
if(info.queueDelete && info.menu)
|
||||
{
|
||||
std::list<MenuInfo_S>::iterator next = del;
|
||||
++next;
|
||||
@ -675,6 +678,7 @@ void Page::update(float dt)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void Page::draw()
|
||||
{
|
||||
for(unsigned int i = 0; i < NUM_LAYERS; ++i)
|
||||
|
||||
@ -78,6 +78,7 @@ public:
|
||||
bool isMenuIdle();
|
||||
void setStatusTextComponent(Text *t);
|
||||
void update(float dt);
|
||||
void cleanup();
|
||||
void draw();
|
||||
void freeGraphicsMemory();
|
||||
void allocateGraphicsMemory();
|
||||
|
||||
@ -510,6 +510,7 @@ void RetroFE::run()
|
||||
case RETROFE_BACK_MENU_ENTER:
|
||||
if(currentPage_->isIdle())
|
||||
{
|
||||
currentPage_->cleanup();
|
||||
state = RETROFE_IDLE;
|
||||
}
|
||||
break;
|
||||
|
||||
@ -20,7 +20,7 @@
|
||||
|
||||
std::string retrofe_version_major = "0";
|
||||
std::string retrofe_version_minor = "7";
|
||||
std::string retrofe_version_build = "7";
|
||||
std::string retrofe_version_build = "8";
|
||||
|
||||
|
||||
std::string Version::getString()
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user