A couple small hotkey shortcuts for refreshing the view, and

re-indexing.
This commit is contained in:
casey 2016-05-21 00:06:48 -07:00
parent af60dedb4b
commit 174d00b4d5
2 changed files with 7 additions and 12 deletions

View File

@ -59,15 +59,6 @@ void LibraryLayout::InitializeWindows() {
void LibraryLayout::Show() {
LayoutBase::Show();
this->categoryList->Requery();
//if (GetOverlay()) {
// this->CloseOverlay();
//}
//std::shared_ptr<IWindow> overlay(new OutputWindow(NULL));
//overlay->SetPosition(2, 2);
//overlay->SetSize(20, 20);
//this->ShowOverlay(overlay);
}
void LibraryLayout::OnCategoryViewSelectionChanged(
@ -95,6 +86,10 @@ bool LibraryLayout::KeyPress(int64 ch) {
this->categoryList->SetFieldName(Track::GENRE_ID);
return true;
}
else if (ch == KEY_F(5)) {
this->categoryList->Requery();
return true;
}
return LayoutBase::KeyPress(ch);
}

View File

@ -32,9 +32,9 @@ bool GlobalHotkeys::Handle(int64 ch) {
this->transport.SetVolume(this->transport.Volume() - 0.05);
return true;
}
else if (ch == KEY_F(5)) {
library->Indexer()->Synchronize(true);
}
else if (kn == "^R") {
library->Indexer()->Synchronize(true);
}
return false;
}