Ticket #7469: 0001-haiku_loader-search-for-matching-shortcut-in-superme.patch

File 0001-haiku_loader-search-for-matching-shortcut-in-superme.patch, 972 bytes (added by jessicah, 10 years ago)
  • src/system/boot/loader/menu.cpp

    From 21c2522ef884c24616a5b7f2b9b5c29747f5f4da Mon Sep 17 00:00:00 2001
    From: Jessica Hamilton <jessica.l.hamilton@gmail.com>
    Date: Mon, 7 Apr 2014 19:52:23 +1200
    Subject: [PATCH] haiku_loader: search for matching shortcut in supermenus
    
    Fixes #7469.
    ---
     src/system/boot/loader/menu.cpp | 10 ++++++++++
     1 file changed, 10 insertions(+)
    
    diff --git a/src/system/boot/loader/menu.cpp b/src/system/boot/loader/menu.cpp
    index dd1da9d..9b91164 100644
    a b Menu::FindShortcut(char key) const  
    414414        shortcut = shortcut->next;
    415415    }
    416416
     417    Menu *superMenu = Supermenu();
     418
     419    if (superMenu != NULL)
     420        return superMenu->FindShortcut(key);
     421
    417422    return NULL;
    418423}
    419424
    Menu::FindItemByShortcut(char key)  
    430435            return item;
    431436    }
    432437
     438    Menu *superMenu = Supermenu();
     439
     440    if (superMenu != NULL)
     441        return superMenu->FindItemByShortcut(key);
     442
    433443    return NULL;
    434444}
    435445