summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKatarina Behrens <Katarina.Behrens@cib.de>2018-10-05 11:39:49 +0200
committerKatarina Behrens <Katarina.Behrens@cib.de>2018-10-18 20:37:20 +0200
commit0585043a6f326a2e108a51bba251ce77ca6a2ea0 (patch)
tree9f460c975f631f2ff8c82dd132e6e7c83fda9c7d
parent6685793351178364460e1580e07b2bf5ccc043ce (diff)
Just enough of SystemEnvData for drag'n'drop
Change-Id: I18ef6cb58632898ddfcb28098b99447565bcfb99 Reviewed-on: https://gerrit.libreoffice.org/61720 Tested-by: Jenkins Reviewed-by: Katarina Behrens <Katarina.Behrens@cib.de>
-rw-r--r--vcl/inc/qt5/Qt5Frame.hxx5
-rw-r--r--vcl/qt5/Qt5Frame.cxx11
-rw-r--r--vcl/unx/kde5/KDE5SalFrame.hxx1
3 files changed, 13 insertions, 4 deletions
diff --git a/vcl/inc/qt5/Qt5Frame.hxx b/vcl/inc/qt5/Qt5Frame.hxx
index ce468ded3c18..d3400f378d1f 100644
--- a/vcl/inc/qt5/Qt5Frame.hxx
+++ b/vcl/inc/qt5/Qt5Frame.hxx
@@ -26,6 +26,7 @@
#include <headless/svpgdi.hxx>
#include <vcl/svapp.hxx>
+#include <vcl/sysdata.hxx>
#include <QtCore/QObject>
@@ -68,6 +69,8 @@ class VCLPLUG_QT5_PUBLIC Qt5Frame : public QObject, public SalFrame
Qt5Frame* m_pParent;
PointerStyle m_ePointerStyle;
+ SystemEnvData m_aSystemData;
+
Qt5Menu* m_pSalMenu;
Qt5DragSource* m_pDragSource;
@@ -160,7 +163,7 @@ public:
virtual LanguageType GetInputLanguage() override;
virtual void UpdateSettings(AllSettings& rSettings) override;
virtual void Beep() override;
- virtual const SystemEnvData* GetSystemData() const override;
+ virtual const SystemEnvData* GetSystemData() const override { return &m_aSystemData; }
virtual SalPointerState GetPointerState() override;
virtual KeyIndicatorState GetIndicatorState() override;
virtual void SimulateKeyPress(sal_uInt16 nKeyCode) override;
diff --git a/vcl/qt5/Qt5Frame.cxx b/vcl/qt5/Qt5Frame.cxx
index 070342601bbd..ae3ae325ccd2 100644
--- a/vcl/qt5/Qt5Frame.cxx
+++ b/vcl/qt5/Qt5Frame.cxx
@@ -133,6 +133,14 @@ Qt5Frame::Qt5Frame(Qt5Frame* pParent, SalFrameStyleFlags nStyle, bool bUseCairo)
maGeometry.nLeftDecoration = 0;
maGeometry.nRightDecoration = 0;
}
+
+ m_aSystemData.nSize = sizeof(SystemEnvData);
+ //m_aSystemData.aWindow = GetNativeWindowHandle(m_pWindow);
+ m_aSystemData.aShellWindow = reinterpret_cast<sal_IntPtr>(this);
+ //m_aSystemData.pSalFrame = this;
+ //m_aSystemData.pWidget = m_pQWidget;
+ //m_aSystemData.nScreen = m_nXScreen.getXScreen();
+ m_aSystemData.pToolkit = "qt5";
}
Qt5Frame::~Qt5Frame()
@@ -143,6 +151,7 @@ Qt5Frame::~Qt5Frame()
delete m_pTopLevel;
else
delete m_pQWidget;
+ m_aSystemData.aShellWindow = 0;
}
void Qt5Frame::Damage(sal_Int32 nExtentsX, sal_Int32 nExtentsY, sal_Int32 nExtentsWidth,
@@ -780,8 +789,6 @@ void Qt5Frame::UpdateSettings(AllSettings& rSettings)
void Qt5Frame::Beep() { QApplication::beep(); }
-const SystemEnvData* Qt5Frame::GetSystemData() const { return nullptr; }
-
SalFrame::SalPointerState Qt5Frame::GetPointerState()
{
SalPointerState aState;
diff --git a/vcl/unx/kde5/KDE5SalFrame.hxx b/vcl/unx/kde5/KDE5SalFrame.hxx
index e39dab65503d..441039829846 100644
--- a/vcl/unx/kde5/KDE5SalFrame.hxx
+++ b/vcl/unx/kde5/KDE5SalFrame.hxx
@@ -47,7 +47,6 @@ public:
virtual void StartPresentation(bool bStart) override;
virtual LanguageType GetInputLanguage() override { return LANGUAGE_SYSTEM; }
- virtual const SystemEnvData* GetSystemData() const override { return nullptr; }
virtual SalPointerState GetPointerState() override { return SalPointerState(); }
virtual KeyIndicatorState GetIndicatorState() override { return KeyIndicatorState(); }
};