Skip to content

Commit

Permalink
reset text scroll in game launcher when moving
Browse files Browse the repository at this point in the history
  • Loading branch information
JoseAaronLopezGarcia committed Dec 21, 2024
1 parent 94332cd commit 8ed63ef
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
3 changes: 2 additions & 1 deletion extras/menus/arkMenu/include/gamemgr.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@ class GameManager : public SystemEntry{
private:

GameManager();

TextScroll scroll;

/* Array of game menus */
Menu* categories[MAX_CATEGORIES];
Expand Down Expand Up @@ -128,7 +130,6 @@ class GameManager : public SystemEntry{
}

void drawInfo(){
static TextScroll scroll;
string info = getInfo();
bool is_entry_info = (getEntry() != NULL && info == getEntry()->getName());
bool translate = ( !is_entry_info || info == "Recovery Menu" || info == "UMD Drive" );
Expand Down
3 changes: 3 additions & 0 deletions extras/menus/arkMenu/src/gamemgr.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ GameManager::GameManager(){
// set the global self variable as this instance for the threads to use it
self = this;

scroll.w = 0;
this->use_categories = true;
this->scanning = true;
this->optionsmenu = NULL;
Expand Down Expand Up @@ -356,12 +357,14 @@ void GameManager::moveUp(){
if (selectedCategory < 0)
return;
this->categories[this->selectedCategory]->moveUp();
scroll.tmp = scroll.x; // reset text scroll
}

void GameManager::moveDown(){
if (selectedCategory < 0)
return;
this->categories[this->selectedCategory]->moveDown();
scroll.tmp = scroll.x; // reset text scroll
}

void GameManager::stopFastScroll(){
Expand Down

0 comments on commit 8ed63ef

Please sign in to comment.