GUI: Inhibit auto-mark-read after toggling the state manually
The point of this patch is to make sure that a quick press of "M" immediately after hitting the up/down arrow key will abort the delayed "let's make current message as read" feature. This stuff has to be done in a slightly complicated way due to way how shortcuts are implemented in Qt. The shortcut receives the key information *prior* to the target widget's keyReleaseEvent; the keyPressEvent is actually eaten by the QAction's shortcut handler. However, we can still listen to the QEvent::ShortcutOverride which is processed prior to QAction. This patch therefore configures the widget so that if it detects that any other key than those in the "delay any action for these" group has been pressed, the delay is immediately cut and the action is performed. On top of that, the actual inhibition of the auto-mark-as-read timer can be trivially implemented. The ihibiting is only active when the "current message" as defined by the listing matches the "current message" as defined by the message viewer. REVIEW: 113669
parent
f8e478b0
Please register or sign in to comment