Keymap: localize system keymap list
Change-Id: Ifd8e7c2b4a8d1f48ce31686b3b653d0304b4c635 Reviewed-on: https://review.haiku-os.org/c/1649 Reviewed-by: waddlesplash <[email protected]>
This commit is contained in:
committed by
waddlesplash
parent
490df7cbfd
commit
84a5d9f625
@@ -925,7 +925,9 @@ KeymapWindow::_FillSystemMaps()
|
|||||||
if (directory.SetTo(path.Path()) == B_OK) {
|
if (directory.SetTo(path.Path()) == B_OK) {
|
||||||
while (directory.GetNextRef(&ref) == B_OK) {
|
while (directory.GetNextRef(&ref) == B_OK) {
|
||||||
fSystemListView->AddItem(
|
fSystemListView->AddItem(
|
||||||
new KeymapListItem(ref, B_TRANSLATE_NOCOLLECT(ref.name)));
|
new KeymapListItem(ref,
|
||||||
|
B_TRANSLATE_NOCOLLECT_ALL((ref.name),
|
||||||
|
"KeymapNames", NULL)));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1017,8 +1019,9 @@ KeymapWindow::_SelectCurrentMap(BListView* view)
|
|||||||
return false;
|
return false;
|
||||||
|
|
||||||
for (int32 i = 0; i < view->CountItems(); i++) {
|
for (int32 i = 0; i < view->CountItems(); i++) {
|
||||||
BStringItem* current = dynamic_cast<BStringItem *>(view->ItemAt(i));
|
KeymapListItem* current =
|
||||||
if (current != NULL && fCurrentMapName == current->Text()) {
|
static_cast<KeymapListItem *>(view->ItemAt(i));
|
||||||
|
if (current != NULL && fCurrentMapName == current->EntryRef().name) {
|
||||||
view->Select(i);
|
view->Select(i);
|
||||||
view->ScrollToSelection();
|
view->ScrollToSelection();
|
||||||
return true;
|
return true;
|
||||||
|
|||||||
Reference in New Issue
Block a user