From 59905d623d7cc7ac878616ffdfd392c6c2e56239 Mon Sep 17 00:00:00 2001 From: DRayX7 Date: Thu, 21 May 2009 18:26:01 +0000 Subject: [PATCH] *Better fix for zero entries (fixes teh problem instead of avoiding it) *Moved a button --- source/libwiigui/gui_gamebrowser.cpp | 22 ++++++------------- source/menu.cpp | 32 +++++++++++++++++----------- 2 files changed, 27 insertions(+), 27 deletions(-) diff --git a/source/libwiigui/gui_gamebrowser.cpp b/source/libwiigui/gui_gamebrowser.cpp index 172e64c8..441d8c3b 100644 --- a/source/libwiigui/gui_gamebrowser.cpp +++ b/source/libwiigui/gui_gamebrowser.cpp @@ -643,24 +643,16 @@ void GuiGameBrowser::Update(GuiTrigger * t) if(updateCB) updateCB(this); -} - +} + void GuiGameBrowser::Reload(struct discHdr * l, int count) { LOCK(this); - gameList = l; - gameCnt = count; - if (gameCnt == 0) { - focus = 0; - dontsetfocus = 1; - } else { - dontsetfocus = 0; - focus = 1; - selectedItem = 0; - } - gameList = l; - scrollbaron = (gameCnt > THEME.pagesize) ? 1 : 0; - pagesize = (gameCnt > THEME.pagesize) ? THEME.pagesize : gameCnt; + gameList = l; + gameCnt = count; + scrollbaron = (gameCnt > THEME.pagesize) ? 1 : 0; + pagesize = (gameCnt > THEME.pagesize) ? THEME.pagesize : gameCnt; + selectedItem = 0; listOffset = 0; for(int i=0; i