mirror of
https://review.haiku-os.org/haiku
synced 2025-01-31 18:56:49 +01:00
* The keyboard target was always the first menu in the window list - no matter if that was hidden or not.
This fixes the bug described by Stefano in r23343. * Therefore, I enabled cached menu windows again. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23356 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
parent
9d2f3035cd
commit
737ce1c03c
@ -34,7 +34,7 @@
|
||||
|
||||
#include "utf8_functions.h"
|
||||
|
||||
#define USE_CACHED_MENUWINDOW 0
|
||||
#define USE_CACHED_MENUWINDOW 1
|
||||
|
||||
using std::nothrow;
|
||||
using BPrivate::BMenuWindow;
|
||||
|
@ -1172,6 +1172,9 @@ EventTarget*
|
||||
Desktop::KeyboardEventTarget()
|
||||
{
|
||||
WindowLayer* window = _CurrentWindows().LastWindow();
|
||||
while (window != NULL && window->IsHidden()) {
|
||||
window = window->PreviousWindow(fCurrentWorkspace);
|
||||
}
|
||||
if (window != NULL && window->Feel() == kMenuWindowFeel)
|
||||
return &window->EventTarget();
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user