mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-26 09:30:24 +00:00
PDFViewer: Ignore wheel events when there is no document loaded
This commit is contained in:
parent
f808279769
commit
076018b74b
Notes:
sideshowbarker
2024-07-18 17:48:31 +09:00
Author: https://github.com/awesomekling Commit: https://github.com/SerenityOS/serenity/commit/076018b74b5
1 changed files with 3 additions and 0 deletions
|
@ -72,6 +72,9 @@ void PDFViewer::paint_event(GUI::PaintEvent& event)
|
|||
|
||||
void PDFViewer::mousewheel_event(GUI::MouseEvent& event)
|
||||
{
|
||||
if (!m_document)
|
||||
return;
|
||||
|
||||
bool scrolled_down = event.wheel_delta() > 0;
|
||||
|
||||
if (event.ctrl()) {
|
||||
|
|
Loading…
Reference in a new issue