diff options
author | Pranav Kant <pranavk@collabora.co.uk> | 2017-12-08 18:06:36 +0530 |
---|---|---|
committer | Jan Holesovsky <kendy@collabora.com> | 2017-12-13 20:25:19 +0100 |
commit | 976f65f94d1e8d4114fc3afe26844f412a3eb6f8 (patch) | |
tree | e8c0e035e7013f34dcb29c0d277b174792683db5 /vcl | |
parent | e8400fb18cfc3f8f09ee1e13b4a6fd1eec11d9ba (diff) |
Use ImplIsFloatingWindow instead of dynamic_cast
Change-Id: I09f351ae5d8d1b5c1a405d7aa8082be6014268b3
(cherry picked from commit 0898ced81a3129b4c36c08e0222f96c513f0fd77)
Reviewed-on: https://gerrit.libreoffice.org/46114
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
Diffstat (limited to 'vcl')
-rw-r--r-- | vcl/source/window/window.cxx | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/vcl/source/window/window.cxx b/vcl/source/window/window.cxx index 7eaa26482630..95157d665b1f 100644 --- a/vcl/source/window/window.cxx +++ b/vcl/source/window/window.cxx @@ -3255,7 +3255,7 @@ void Window::LogicMouseButtonDown(const MouseEvent& rMouseEvent) // When we're not doing tiled rendering, then positions must be passed as pixels. assert(comphelper::LibreOfficeKit::isActive()); - if (dynamic_cast<FloatingWindow*>(this) != nullptr) + if (ImplIsFloatingWindow()) ImplWindowFrameProc(ImplGetBorderWindow(), SalEvent::ExternalMouseButtonDown, &rMouseEvent); else ImplWindowFrameProc(this, SalEvent::ExternalMouseButtonDown, &rMouseEvent); @@ -3266,7 +3266,7 @@ void Window::LogicMouseButtonUp(const MouseEvent& rMouseEvent) // When we're not doing tiled rendering, then positions must be passed as pixels. assert(comphelper::LibreOfficeKit::isActive()); - if (dynamic_cast<FloatingWindow*>(this) != nullptr) + if (ImplIsFloatingWindow()) ImplWindowFrameProc(ImplGetBorderWindow(), SalEvent::ExternalMouseButtonUp, &rMouseEvent); else ImplWindowFrameProc(this, SalEvent::ExternalMouseButtonUp, &rMouseEvent); @@ -3277,7 +3277,7 @@ void Window::LogicMouseMove(const MouseEvent& rMouseEvent) // When we're not doing tiled rendering, then positions must be passed as pixels. assert(comphelper::LibreOfficeKit::isActive()); - if (dynamic_cast<FloatingWindow*>(this) != nullptr) + if (ImplIsFloatingWindow()) ImplWindowFrameProc(ImplGetBorderWindow(), SalEvent::ExternalMouseMove, &rMouseEvent); else ImplWindowFrameProc(this, SalEvent::ExternalMouseMove, &rMouseEvent); |