Fix positioning of BPopUpMenu when a nested item is selected.
Signed-off-by: John Scipione <jscipione@gmail.com>
This commit is contained in:
parent
ecc0703995
commit
3bf528b59c
@ -293,8 +293,13 @@ BPopUpMenu::ScreenLocation()
|
||||
|
||||
superMenu->ConvertToScreen(&point);
|
||||
|
||||
if (selectedItem != NULL)
|
||||
if (selectedItem != NULL) {
|
||||
while (selectedItem->Menu() != this
|
||||
&& selectedItem->Menu()->Superitem() != NULL) {
|
||||
selectedItem = selectedItem->Menu()->Superitem();
|
||||
}
|
||||
point.y -= selectedItem->Frame().top;
|
||||
}
|
||||
|
||||
return point;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user