fix scrolling in browsers being reversed
This commit is contained in:
parent
48a333f0de
commit
0e383e1045
@ -124,7 +124,7 @@ void LocalBrowserController::SetPage(int page)
|
||||
void LocalBrowserController::SetPageRelative(int offset)
|
||||
{
|
||||
int page = std::min(std::max(browserModel->GetPageNum() + offset, 1), browserModel->GetPageCount());
|
||||
if(page != browserModel->GetPageCount())
|
||||
if (page != browserModel->GetPageNum())
|
||||
browserModel->UpdateSavesList(page);
|
||||
}
|
||||
|
||||
|
@ -245,8 +245,8 @@ void LocalBrowserView::NotifySelectedChanged(LocalBrowserModel * sender)
|
||||
|
||||
void LocalBrowserView::OnMouseWheel(int x, int y, int d)
|
||||
{
|
||||
if(d)
|
||||
c->SetPageRelative(d);
|
||||
if (d)
|
||||
c->SetPageRelative(-d);
|
||||
}
|
||||
|
||||
void LocalBrowserView::OnKeyPress(int key, int scan, bool repeat, bool shift, bool ctrl, bool alt)
|
||||
|
@ -137,7 +137,7 @@ void SearchController::SetPage(int page)
|
||||
void SearchController::SetPageRelative(int offset)
|
||||
{
|
||||
int page = std::min(std::max(searchModel->GetPageNum() + offset, 1), searchModel->GetPageCount());
|
||||
if(page != searchModel->GetPageCount())
|
||||
if (page != searchModel->GetPageNum())
|
||||
searchModel->UpdateSaveList(page, searchModel->GetLastQuery());
|
||||
}
|
||||
|
||||
|
@ -778,8 +778,8 @@ void SearchView::OnTick(float dt)
|
||||
|
||||
void SearchView::OnMouseWheel(int x, int y, int d)
|
||||
{
|
||||
if(d)
|
||||
c->SetPageRelative(d);
|
||||
if (d)
|
||||
c->SetPageRelative(-d);
|
||||
}
|
||||
void SearchView::OnKeyPress(int key, int scan, bool repeat, bool shift, bool ctrl, bool alt)
|
||||
{
|
||||
|
Reference in New Issue
Block a user