Tracker: Fix B_UNDO/B_REDO forwarding to a focused BTextView.
This commit is contained in:
parent
56f9e8b759
commit
a8ae893bc3
@ -1399,6 +1399,26 @@ BContainerWindow::MessageReceived(BMessage* message)
|
||||
break;
|
||||
}
|
||||
|
||||
case B_UNDO: {
|
||||
BView* view = CurrentFocus();
|
||||
if (dynamic_cast<BTextView*>(view) == NULL) {
|
||||
FSUndo();
|
||||
} else {
|
||||
view->MessageReceived(message);
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
case B_REDO: {
|
||||
BView* view = CurrentFocus();
|
||||
if (dynamic_cast<BTextView*>(view) == NULL) {
|
||||
FSRedo();
|
||||
} else {
|
||||
view->MessageReceived(message);
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
case kNewFolder:
|
||||
PostMessage(message, PoseView());
|
||||
break;
|
||||
@ -1690,14 +1710,6 @@ BContainerWindow::MessageReceived(BMessage* message)
|
||||
UpdateTitle();
|
||||
break;
|
||||
|
||||
case B_UNDO:
|
||||
FSUndo();
|
||||
break;
|
||||
|
||||
case B_REDO:
|
||||
FSRedo();
|
||||
break;
|
||||
|
||||
default:
|
||||
_inherited::MessageReceived(message);
|
||||
break;
|
||||
|
Loading…
Reference in New Issue
Block a user