vcl/Library_vclplug_qt5.mk | 2 - vcl/qt5/Qt5Bitmap.cxx | 16 ++++++------ vcl/qt5/Qt5Bitmap.hxx | 2 - vcl/qt5/Qt5Data.cxx | 13 ++------- vcl/qt5/Qt5Data.hxx | 3 +- vcl/qt5/Qt5Frame.cxx | 44 ++++++++++++++++----------------- vcl/qt5/Qt5Graphics.cxx | 28 +++++++++------------ vcl/qt5/Qt5Graphics.hxx | 2 - vcl/qt5/Qt5Graphics_Controls.cxx | 28 +++++++++++---------- vcl/qt5/Qt5Graphics_GDI.cxx | 51 ++++++++++++++++++++++----------------- vcl/qt5/Qt5Graphics_Text.cxx | 24 +++++++++--------- vcl/qt5/Qt5Instance.cxx | 2 - vcl/qt5/Qt5Object.cxx | 4 +-- 13 files changed, 110 insertions(+), 109 deletions(-)
New commits: commit 6c9adeed6186e7a65facffc6cb93277686f1b6e4 Author: Noel Grandin <noel.gran...@collabora.co.uk> Date: Mon Jan 8 09:44:05 2018 +0200 set_warnings_not_errors not necessary in qt5 plugin anymore Change-Id: I8ed8c07ce5b34d6a03a2ec9a5f9782cd506529e5 diff --git a/vcl/Library_vclplug_qt5.mk b/vcl/Library_vclplug_qt5.mk index fba78d738883..68758028d662 100644 --- a/vcl/Library_vclplug_qt5.mk +++ b/vcl/Library_vclplug_qt5.mk @@ -19,8 +19,6 @@ $(eval $(call gb_Library_Library,vclplug_qt5)) -$(eval $(call gb_Library_set_warnings_not_errors,vclplug_qt5)) - $(eval $(call gb_Library_use_custom_headers,vclplug_qt5,vcl/qt5)) $(eval $(call gb_Library_set_include,vclplug_qt5,\ commit 93dae42fd4e5c7425cd0dfa945acd2fa0512d27f Author: Noel Grandin <noel.gran...@collabora.co.uk> Date: Mon Jan 8 09:43:42 2018 +0200 loplugin:useuniqueptr in qt5 Change-Id: Ic7135e6ca3be7848fa39cd442d6dd716ea090713 diff --git a/vcl/qt5/Qt5Data.cxx b/vcl/qt5/Qt5Data.cxx index 7d529964eed9..5c5a341df208 100644 --- a/vcl/qt5/Qt5Data.cxx +++ b/vcl/qt5/Qt5Data.cxx @@ -27,20 +27,13 @@ Qt5Data::Qt5Data(SalInstance* pInstance) : GenericUnixSalData(SAL_DATA_QT5, pInstance) { - for (QCursor*& rpCsr : m_aCursors) - rpCsr = nullptr; - ImplSVData* pSVData = ImplGetSVData(); // draw toolbars on separate lines pSVData->maNWFData.mbDockingAreaSeparateTB = true; } -Qt5Data::~Qt5Data() -{ - for (QCursor*& rpCsr : m_aCursors) - delete rpCsr; -} +Qt5Data::~Qt5Data() {} static QCursor* getQCursorFromXBM(const unsigned char* pBitmap, const unsigned char* pMask, int nWidth, int nHeight, int nXHot, int nYHot) @@ -184,7 +177,7 @@ QCursor& Qt5Data::getCursor(PointerStyle ePointerStyle) SAL_WARN("vcl.qt5", "pointer " << static_cast<int>(ePointerStyle) << "not implemented"); } - m_aCursors[ePointerStyle] = pCursor; + m_aCursors[ePointerStyle].reset(pCursor); } return *m_aCursors[ePointerStyle]; diff --git a/vcl/qt5/Qt5Data.hxx b/vcl/qt5/Qt5Data.hxx index a63d243b6967..f8cf4fb05e6a 100644 --- a/vcl/qt5/Qt5Data.hxx +++ b/vcl/qt5/Qt5Data.hxx @@ -23,12 +23,13 @@ #include <o3tl/enumarray.hxx> #include <vcl/ptrstyle.hxx> +#include <memory> class QCursor; class Qt5Data : public GenericUnixSalData { - o3tl::enumarray<PointerStyle, QCursor*> m_aCursors; + o3tl::enumarray<PointerStyle, std::unique_ptr<QCursor>> m_aCursors; public: explicit Qt5Data(SalInstance* pInstance); diff --git a/vcl/qt5/Qt5Graphics.cxx b/vcl/qt5/Qt5Graphics.cxx index 411dfd7543b8..23249c5799c6 100644 --- a/vcl/qt5/Qt5Graphics.cxx +++ b/vcl/qt5/Qt5Graphics.cxx @@ -44,12 +44,7 @@ Qt5Graphics::Qt5Graphics( Qt5Frame *pFrame, QImage *pQImage ) ResetClipRegion(); } -Qt5Graphics::~Qt5Graphics() -{ - // release the text styles - for (int i = 0; i < MAX_FALLBACK; ++i) - delete m_pTextStyle[i]; -} +Qt5Graphics::~Qt5Graphics() {} void Qt5Graphics::ChangeQImage(QImage* pQImage) { diff --git a/vcl/qt5/Qt5Graphics.hxx b/vcl/qt5/Qt5Graphics.hxx index 6e8332356d49..a9a71c64b5e2 100644 --- a/vcl/qt5/Qt5Graphics.hxx +++ b/vcl/qt5/Qt5Graphics.hxx @@ -49,7 +49,7 @@ class Qt5Graphics : public SalGraphics PhysicalFontCollection* m_pFontCollection; const Qt5FontFace* m_pFontData[MAX_FALLBACK]; - Qt5Font* m_pTextStyle[MAX_FALLBACK]; + std::unique_ptr<Qt5Font> m_pTextStyle[MAX_FALLBACK]; SalColor m_aTextColor; Qt5Graphics(Qt5Frame* pFrame, QImage* pQImage); diff --git a/vcl/qt5/Qt5Graphics_Text.cxx b/vcl/qt5/Qt5Graphics_Text.cxx index ec07d50e4af6..8d25e97df786 100644 --- a/vcl/qt5/Qt5Graphics_Text.cxx +++ b/vcl/qt5/Qt5Graphics_Text.cxx @@ -39,8 +39,7 @@ void Qt5Graphics::SetFont(const FontSelectPattern* pReqFont, int nFallbackLevel) { if (!m_pTextStyle[i]) break; - delete m_pTextStyle[i]; - m_pTextStyle[i] = nullptr; + m_pTextStyle[i].reset(); } if (!pReqFont) @@ -49,7 +48,7 @@ void Qt5Graphics::SetFont(const FontSelectPattern* pReqFont, int nFallbackLevel) else { m_pFontData[nFallbackLevel] = static_cast<const Qt5FontFace*>(pReqFont->mpFontData); - m_pTextStyle[nFallbackLevel] = new Qt5Font(*pReqFont); + m_pTextStyle[nFallbackLevel].reset(new Qt5Font(*pReqFont)); } } commit 4f3c5db4dfacfad32ef207193a21c96e1d39da85 Author: Noel Grandin <noel.gran...@collabora.co.uk> Date: Mon Jan 8 09:40:37 2018 +0200 loplugin:unnecessaryparen in qt5 plugin Change-Id: I07c5cee0b7fa7d05370c8dc61cae0e6a2aead348 diff --git a/vcl/qt5/Qt5Frame.cxx b/vcl/qt5/Qt5Frame.cxx index fc64e7ffe7d4..c8f8609ea14e 100644 --- a/vcl/qt5/Qt5Frame.cxx +++ b/vcl/qt5/Qt5Frame.cxx @@ -84,7 +84,7 @@ Qt5Frame::Qt5Frame(Qt5Frame* pParent, SalFrameStyleFlags nStyle, bool bUseCairo) aWinFlags |= Qt::Dialog; else if (nStyle & SalFrameStyleFlags::TOOLWINDOW) aWinFlags |= Qt::Tool; - else if ((nStyle & SalFrameStyleFlags::OWNERDRAWDECORATION)) + else if (nStyle & SalFrameStyleFlags::OWNERDRAWDECORATION) aWinFlags |= Qt::Window | Qt::FramelessWindowHint | Qt::WindowDoesNotAcceptFocus; else aWinFlags |= Qt::Window; commit 8332e9791c786c89737389bee296260b05b71040 Author: Noel Grandin <noel.gran...@collabora.co.uk> Date: Mon Jan 8 09:40:00 2018 +0200 loplugin:staticaccess in qt5 plugin Change-Id: Ic6a895f9dd9d1474681217d6ddfd31898f916c2c diff --git a/vcl/qt5/Qt5Frame.cxx b/vcl/qt5/Qt5Frame.cxx index c3cc768af37c..fc64e7ffe7d4 100644 --- a/vcl/qt5/Qt5Frame.cxx +++ b/vcl/qt5/Qt5Frame.cxx @@ -470,8 +470,8 @@ SalFrame::SalPointerState Qt5Frame::GetPointerState() SalPointerState aState; QPoint pos = QCursor::pos(); aState.maPos = Point(pos.x(), pos.y()); - aState.mnState - = GetMouseModCode(qApp->mouseButtons()) | GetKeyModCode(qApp->keyboardModifiers()); + aState.mnState = GetMouseModCode(QGuiApplication::mouseButtons()) + | GetKeyModCode(QGuiApplication::keyboardModifiers()); return aState; } commit a4ca332afd13d3f9309eee4b48d93bfe3b2a4fe1 Author: Noel Grandin <noel.gran...@collabora.co.uk> Date: Mon Jan 8 09:38:24 2018 +0200 -Wunused-parameter in qt5 plugin Change-Id: I2d17ccdc9addb911fef8925d87b794075946c3ca diff --git a/vcl/qt5/Qt5Bitmap.cxx b/vcl/qt5/Qt5Bitmap.cxx index 49b7a22e6fb2..f14479fd9419 100644 --- a/vcl/qt5/Qt5Bitmap.cxx +++ b/vcl/qt5/Qt5Bitmap.cxx @@ -113,8 +113,8 @@ bool Qt5Bitmap::Create(const SalBitmap& rSalBmp, sal_uInt16 nNewBitCount) return true; } -bool Qt5Bitmap::Create(const css::uno::Reference<css::rendering::XBitmapCanvas>& rBitmapCanvas, - Size& rSize, bool bMask) +bool Qt5Bitmap::Create(const css::uno::Reference<css::rendering::XBitmapCanvas>& /*rBitmapCanvas*/, + Size& /*rSize*/, bool /*bMask*/) { return false; } @@ -143,7 +143,7 @@ sal_uInt16 Qt5Bitmap::GetBitCount() const return 0; } -BitmapBuffer* Qt5Bitmap::AcquireBuffer(BitmapAccessMode nMode) +BitmapBuffer* Qt5Bitmap::AcquireBuffer(BitmapAccessMode /*nMode*/) { static const BitmapPalette aEmptyPalette; @@ -215,7 +215,7 @@ BitmapBuffer* Qt5Bitmap::AcquireBuffer(BitmapAccessMode nMode) return pBuffer; } -void Qt5Bitmap::ReleaseBuffer(BitmapBuffer* pBuffer, BitmapAccessMode nMode) +void Qt5Bitmap::ReleaseBuffer(BitmapBuffer* pBuffer, BitmapAccessMode /*nMode*/) { m_aPalette = pBuffer->maPalette; auto count = m_aPalette.GetEntryCount(); @@ -230,16 +230,18 @@ void Qt5Bitmap::ReleaseBuffer(BitmapBuffer* pBuffer, BitmapAccessMode nMode) delete pBuffer; } -bool Qt5Bitmap::GetSystemData(BitmapSystemData& rData) { return false; } +bool Qt5Bitmap::GetSystemData(BitmapSystemData& /*rData*/) { return false; } bool Qt5Bitmap::ScalingSupported() const { return false; } -bool Qt5Bitmap::Scale(const double& rScaleX, const double& rScaleY, BmpScaleFlag nScaleFlag) +bool Qt5Bitmap::Scale(const double& /*rScaleX*/, const double& /*rScaleY*/, + BmpScaleFlag /*nScaleFlag*/) { return false; } -bool Qt5Bitmap::Replace(const Color& rSearchColor, const Color& rReplaceColor, sal_uInt8 nTol) +bool Qt5Bitmap::Replace(const Color& /*rSearchColor*/, const Color& /*rReplaceColor*/, + sal_uInt8 /*nTol*/) { return false; } diff --git a/vcl/qt5/Qt5Data.cxx b/vcl/qt5/Qt5Data.cxx index 7fdae2cc0a9c..7d529964eed9 100644 --- a/vcl/qt5/Qt5Data.cxx +++ b/vcl/qt5/Qt5Data.cxx @@ -192,6 +192,6 @@ QCursor& Qt5Data::getCursor(PointerStyle ePointerStyle) void Qt5Data::ErrorTrapPush() {} -bool Qt5Data::ErrorTrapPop(bool bIgnoreError) { return false; } +bool Qt5Data::ErrorTrapPop(bool /*bIgnoreError*/) { return false; } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/vcl/qt5/Qt5Frame.cxx b/vcl/qt5/Qt5Frame.cxx index cb44b71f6e2c..c3cc768af37c 100644 --- a/vcl/qt5/Qt5Frame.cxx +++ b/vcl/qt5/Qt5Frame.cxx @@ -227,13 +227,13 @@ void Qt5Frame::SetIcon(sal_uInt16 nIcon) m_pQWidget->window()->setWindowIcon(aIcon); } -void Qt5Frame::SetMenu(SalMenu* pMenu) {} +void Qt5Frame::SetMenu(SalMenu* /*pMenu*/) {} void Qt5Frame::DrawMenuBar() {} -void Qt5Frame::SetExtendedFrameStyle(SalExtStyle nExtStyle) {} +void Qt5Frame::SetExtendedFrameStyle(SalExtStyle /*nExtStyle*/) {} -void Qt5Frame::Show(bool bVisible, bool bNoActivate) +void Qt5Frame::Show(bool bVisible, bool /*bNoActivate*/) { assert(m_pQWidget.get()); m_pQWidget->setVisible(bVisible); @@ -409,13 +409,13 @@ bool Qt5Frame::GetWindowState(SalFrameState* pState) return true; } -void Qt5Frame::ShowFullScreen(bool bFullScreen, sal_Int32 nDisplay) {} +void Qt5Frame::ShowFullScreen(bool /*bFullScreen*/, sal_Int32 /*nDisplay*/) {} -void Qt5Frame::StartPresentation(bool bStart) {} +void Qt5Frame::StartPresentation(bool /*bStart*/) {} -void Qt5Frame::SetAlwaysOnTop(bool bOnTop) {} +void Qt5Frame::SetAlwaysOnTop(bool /*bOnTop*/) {} -void Qt5Frame::ToTop(SalFrameToTop nFlags) {} +void Qt5Frame::ToTop(SalFrameToTop /*nFlags*/) {} void Qt5Frame::SetPointer(PointerStyle ePointerStyle) { @@ -429,22 +429,22 @@ void Qt5Frame::SetPointer(PointerStyle ePointerStyle) pWindow->setCursor(static_cast<Qt5Data*>(GetSalData())->getCursor(ePointerStyle)); } -void Qt5Frame::CaptureMouse(bool bMouse) {} +void Qt5Frame::CaptureMouse(bool /*bMouse*/) {} -void Qt5Frame::SetPointerPos(long nX, long nY) {} +void Qt5Frame::SetPointerPos(long /*nX*/, long /*nY*/) {} void Qt5Frame::Flush() {} -void Qt5Frame::Flush(const tools::Rectangle& rRect) {} +void Qt5Frame::Flush(const tools::Rectangle& /*rRect*/) {} -void Qt5Frame::SetInputContext(SalInputContext* pContext) {} +void Qt5Frame::SetInputContext(SalInputContext* /*pContext*/) {} -void Qt5Frame::EndExtTextInput(EndExtTextInputFlags nFlags) {} +void Qt5Frame::EndExtTextInput(EndExtTextInputFlags /*nFlags*/) {} -OUString Qt5Frame::GetKeyName(sal_uInt16 nKeyCode) { return OUString(); } +OUString Qt5Frame::GetKeyName(sal_uInt16 /*nKeyCode*/) { return OUString(); } -bool Qt5Frame::MapUnicodeToKeyCode(sal_Unicode aUnicode, LanguageType aLangType, - vcl::KeyCode& rKeyCode) +bool Qt5Frame::MapUnicodeToKeyCode(sal_Unicode /*aUnicode*/, LanguageType /*aLangType*/, + vcl::KeyCode& /*rKeyCode*/) { return false; } @@ -477,17 +477,17 @@ SalFrame::SalPointerState Qt5Frame::GetPointerState() KeyIndicatorState Qt5Frame::GetIndicatorState() { return KeyIndicatorState(); } -void Qt5Frame::SimulateKeyPress(sal_uInt16 nKeyCode) {} +void Qt5Frame::SimulateKeyPress(sal_uInt16 /*nKeyCode*/) {} void Qt5Frame::SetParent(SalFrame* pNewParent) { m_pParent = static_cast<Qt5Frame*>(pNewParent); } -bool Qt5Frame::SetPluginParent(SystemParentData* pNewParent) { return false; } +bool Qt5Frame::SetPluginParent(SystemParentData* /*pNewParent*/) { return false; } void Qt5Frame::ResetClipRegion() {} -void Qt5Frame::BeginSetClipRegion(sal_uLong nRects) {} +void Qt5Frame::BeginSetClipRegion(sal_uLong /*nRects*/) {} -void Qt5Frame::UnionClipRegion(long nX, long nY, long nWidth, long nHeight) {} +void Qt5Frame::UnionClipRegion(long /*nX*/, long /*nY*/, long /*nWidth*/, long /*nHeight*/) {} void Qt5Frame::EndSetClipRegion() {} diff --git a/vcl/qt5/Qt5Graphics.cxx b/vcl/qt5/Qt5Graphics.cxx index a81c941cf17f..411dfd7543b8 100644 --- a/vcl/qt5/Qt5Graphics.cxx +++ b/vcl/qt5/Qt5Graphics.cxx @@ -78,31 +78,34 @@ bool Qt5Graphics::supportsOperation(OutDevSupportType eType) const bool Qt5Graphics::SupportsCairo() const { return false; } cairo::SurfaceSharedPtr -Qt5Graphics::CreateSurface(const cairo::CairoSurfaceSharedPtr& rSurface) const +Qt5Graphics::CreateSurface(const cairo::CairoSurfaceSharedPtr& /*rSurface*/) const { return nullptr; } -cairo::SurfaceSharedPtr Qt5Graphics::CreateSurface(const OutputDevice& rRefDevice, int x, int y, - int width, int height) const +cairo::SurfaceSharedPtr Qt5Graphics::CreateSurface(const OutputDevice& /*rRefDevice*/, int /*x*/, + int /*y*/, int /*width*/, int /*height*/) const { return nullptr; } -cairo::SurfaceSharedPtr Qt5Graphics::CreateBitmapSurface(const OutputDevice& rRefDevice, - const BitmapSystemData& rData, - const Size& rSize) const +cairo::SurfaceSharedPtr Qt5Graphics::CreateBitmapSurface(const OutputDevice& /*rRefDevice*/, + const BitmapSystemData& /*rData*/, + const Size& /*rSize*/) const { return nullptr; } -css::uno::Any Qt5Graphics::GetNativeSurfaceHandle(cairo::SurfaceSharedPtr& rSurface, - const basegfx::B2ISize& rSize) const +css::uno::Any Qt5Graphics::GetNativeSurfaceHandle(cairo::SurfaceSharedPtr& /*rSurface*/, + const basegfx::B2ISize& /*rSize*/) const { return css::uno::Any(); } -SystemFontData Qt5Graphics::GetSysFontData(int nFallbacklevel) const { return SystemFontData(); } +SystemFontData Qt5Graphics::GetSysFontData(int /*nFallbacklevel*/) const +{ + return SystemFontData(); +} #endif diff --git a/vcl/qt5/Qt5Graphics_Controls.cxx b/vcl/qt5/Qt5Graphics_Controls.cxx index a55b8dda235a..ca064ece5e13 100644 --- a/vcl/qt5/Qt5Graphics_Controls.cxx +++ b/vcl/qt5/Qt5Graphics_Controls.cxx @@ -19,28 +19,30 @@ #include "Qt5Graphics.hxx" -bool Qt5Graphics::IsNativeControlSupported(ControlType nType, ControlPart nPart) { return false; } +bool Qt5Graphics::IsNativeControlSupported(ControlType /*nType*/, ControlPart /*nPart*/) +{ + return false; +} -bool Qt5Graphics::hitTestNativeControl(ControlType nType, ControlPart nPart, - const tools::Rectangle& rControlRegion, const Point& aPos, - bool& rIsInside) +bool Qt5Graphics::hitTestNativeControl(ControlType /*nType*/, ControlPart /*nPart*/, + const tools::Rectangle& /*rControlRegion*/, + const Point& /*aPos*/, bool& /*rIsInside*/) { return false; } -bool Qt5Graphics::drawNativeControl(ControlType nType, ControlPart nPart, - const tools::Rectangle& rControlRegion, ControlState nState, - const ImplControlValue& aValue, const OUString& aCaption) +bool Qt5Graphics::drawNativeControl(ControlType /*nType*/, ControlPart /*nPart*/, + const tools::Rectangle& /*rControlRegion*/, + ControlState /*nState*/, const ImplControlValue& /*aValue*/, + const OUString& /*aCaption*/) { return false; } -bool Qt5Graphics::getNativeControlRegion(ControlType nType, ControlPart nPart, - const tools::Rectangle& rControlRegion, - ControlState nState, const ImplControlValue& aValue, - const OUString& aCaption, - tools::Rectangle& rNativeBoundingRegion, - tools::Rectangle& rNativeContentRegion) +bool Qt5Graphics::getNativeControlRegion( + ControlType /*nType*/, ControlPart /*nPart*/, const tools::Rectangle& /*rControlRegion*/, + ControlState /*nState*/, const ImplControlValue& /*aValue*/, const OUString& /*aCaption*/, + tools::Rectangle& /*rNativeBoundingRegion*/, tools::Rectangle& /*rNativeContentRegion*/) { return false; } diff --git a/vcl/qt5/Qt5Graphics_GDI.cxx b/vcl/qt5/Qt5Graphics_GDI.cxx index 7f0bb5929602..fe1b98112b33 100644 --- a/vcl/qt5/Qt5Graphics_GDI.cxx +++ b/vcl/qt5/Qt5Graphics_GDI.cxx @@ -248,8 +248,8 @@ void Qt5Graphics::drawPolygon(sal_uInt32 nPoints, const SalPoint* pPtAry) aPainter.update(aPolygon.boundingRect()); } -void Qt5Graphics::drawPolyPolygon(sal_uInt32 nPoly, const sal_uInt32* pPoints, - PCONSTSALPOINT* pPtAry) +void Qt5Graphics::drawPolyPolygon(sal_uInt32 /*nPoly*/, const sal_uInt32* /*pPoints*/, + PCONSTSALPOINT* /*pPtAry*/) { } @@ -273,21 +273,21 @@ bool Qt5Graphics::drawPolyPolygon(const basegfx::B2DPolyPolygon& rPolyPoly, doub return true; } -bool Qt5Graphics::drawPolyLineBezier(sal_uInt32 nPoints, const SalPoint* pPtAry, - const PolyFlags* pFlgAry) +bool Qt5Graphics::drawPolyLineBezier(sal_uInt32 /*nPoints*/, const SalPoint* /*pPtAry*/, + const PolyFlags* /*pFlgAry*/) { return false; } -bool Qt5Graphics::drawPolygonBezier(sal_uInt32 nPoints, const SalPoint* pPtAry, - const PolyFlags* pFlgAry) +bool Qt5Graphics::drawPolygonBezier(sal_uInt32 /*nPoints*/, const SalPoint* /*pPtAry*/, + const PolyFlags* /*pFlgAry*/) { return false; } -bool Qt5Graphics::drawPolyPolygonBezier(sal_uInt32 nPoly, const sal_uInt32* pPoints, - const SalPoint* const* pPtAry, - const PolyFlags* const* pFlgAry) +bool Qt5Graphics::drawPolyPolygonBezier(sal_uInt32 /*nPoly*/, const sal_uInt32* /*pPoints*/, + const SalPoint* const* /*pPtAry*/, + const PolyFlags* const* /*pFlgAry*/) { return false; } @@ -357,7 +357,7 @@ bool Qt5Graphics::drawPolyLine(const basegfx::B2DPolygon& rPolyLine, double fTra bool Qt5Graphics::drawGradient(const tools::PolyPolygon&, const Gradient&) { return false; } void Qt5Graphics::copyArea(long nDestX, long nDestY, long nSrcX, long nSrcY, long nSrcWidth, - long nSrcHeight, bool bWindowInvalidate) + long nSrcHeight, bool /*bWindowInvalidate*/) { if (nDestX == nSrcX && nDestY == nSrcY) return; @@ -413,8 +413,8 @@ void Qt5Graphics::drawBitmap(const SalTwoRect& rPosAry, const SalBitmap& rSalBit aPainter.update(rPosAry.mnDestX, rPosAry.mnDestY, rPosAry.mnDestWidth, rPosAry.mnDestHeight); } -void Qt5Graphics::drawBitmap(const SalTwoRect& rPosAry, const SalBitmap& rSalBitmap, - const SalBitmap& rTransparentBitmap) +void Qt5Graphics::drawBitmap(const SalTwoRect& rPosAry, const SalBitmap& /*rSalBitmap*/, + const SalBitmap& /*rTransparentBitmap*/) { if (rPosAry.mnSrcWidth <= 0 || rPosAry.mnSrcHeight <= 0 || rPosAry.mnDestWidth <= 0 || rPosAry.mnDestHeight <= 0) @@ -424,8 +424,8 @@ void Qt5Graphics::drawBitmap(const SalTwoRect& rPosAry, const SalBitmap& rSalBit assert(rPosAry.mnSrcHeight == rPosAry.mnDestHeight); } -void Qt5Graphics::drawMask(const SalTwoRect& rPosAry, const SalBitmap& rSalBitmap, - SalColor nMaskColor) +void Qt5Graphics::drawMask(const SalTwoRect& rPosAry, const SalBitmap& /*rSalBitmap*/, + SalColor /*nMaskColor*/) { if (rPosAry.mnSrcWidth <= 0 || rPosAry.mnSrcHeight <= 0 || rPosAry.mnDestWidth <= 0 || rPosAry.mnDestHeight <= 0) @@ -442,19 +442,26 @@ SalBitmap* Qt5Graphics::getBitmap(long nX, long nY, long nWidth, long nHeight) SalColor Qt5Graphics::getPixel(long nX, long nY) { return m_pQImage->pixel(nX, nY); } -void Qt5Graphics::invert(long nX, long nY, long nWidth, long nHeight, SalInvert nFlags) {} +void Qt5Graphics::invert(long /*nX*/, long /*nY*/, long /*nWidth*/, long /*nHeight*/, + SalInvert /*nFlags*/) +{ +} -void Qt5Graphics::invert(sal_uInt32 nPoints, const SalPoint* pPtAry, SalInvert nFlags) {} +void Qt5Graphics::invert(sal_uInt32 /*nPoints*/, const SalPoint* /*pPtAry*/, SalInvert /*nFlags*/) +{ +} -bool Qt5Graphics::drawEPS(long nX, long nY, long nWidth, long nHeight, void* pPtr, sal_uLong nSize) +bool Qt5Graphics::drawEPS(long /*nX*/, long /*nY*/, long /*nWidth*/, long /*nHeight*/, + void* /*pPtr*/, sal_uLong /*nSize*/) { return false; } -bool Qt5Graphics::blendBitmap(const SalTwoRect&, const SalBitmap& rBitmap) { return false; } +bool Qt5Graphics::blendBitmap(const SalTwoRect&, const SalBitmap& /*rBitmap*/) { return false; } -bool Qt5Graphics::blendAlphaBitmap(const SalTwoRect&, const SalBitmap& rSrcBitmap, - const SalBitmap& rMaskBitmap, const SalBitmap& rAlphaBitmap) +bool Qt5Graphics::blendAlphaBitmap(const SalTwoRect&, const SalBitmap& /*rSrcBitmap*/, + const SalBitmap& /*rMaskBitmap*/, + const SalBitmap& /*rAlphaBitmap*/) { return false; } @@ -593,8 +600,8 @@ void Qt5Graphics::SetXORMode(bool bSet) m_eCompositionMode = QPainter::CompositionMode_SourceOver; } -void Qt5Graphics::SetROPLineColor(SalROPColor nROPColor) {} +void Qt5Graphics::SetROPLineColor(SalROPColor /*nROPColor*/) {} -void Qt5Graphics::SetROPFillColor(SalROPColor nROPColor) {} +void Qt5Graphics::SetROPFillColor(SalROPColor /*nROPColor*/) {} /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/vcl/qt5/Qt5Graphics_Text.cxx b/vcl/qt5/Qt5Graphics_Text.cxx index ab9e1afb78d7..ec07d50e4af6 100644 --- a/vcl/qt5/Qt5Graphics_Text.cxx +++ b/vcl/qt5/Qt5Graphics_Text.cxx @@ -108,28 +108,29 @@ void Qt5Graphics::GetDevFontList(PhysicalFontCollection* pPFC) void Qt5Graphics::ClearDevFontCache() {} -bool Qt5Graphics::AddTempDevFont(PhysicalFontCollection*, const OUString& rFileURL, - const OUString& rFontName) +bool Qt5Graphics::AddTempDevFont(PhysicalFontCollection*, const OUString& /*rFileURL*/, + const OUString& /*rFontName*/) { return false; } -bool Qt5Graphics::CreateFontSubset(const OUString& rToFile, const PhysicalFontFace* pFont, - const sal_GlyphId* pGlyphIds, const sal_uInt8* pEncoding, - sal_Int32* pWidths, int nGlyphs, FontSubsetInfo& rInfo) +bool Qt5Graphics::CreateFontSubset(const OUString& /*rToFile*/, const PhysicalFontFace* /*pFont*/, + const sal_GlyphId* /*pGlyphIds*/, const sal_uInt8* /*pEncoding*/, + sal_Int32* /*pWidths*/, int /*nGlyphs*/, + FontSubsetInfo& /*rInfo*/) { return false; } -const void* Qt5Graphics::GetEmbedFontData(const PhysicalFontFace*, long* pDataLen) +const void* Qt5Graphics::GetEmbedFontData(const PhysicalFontFace*, long* /*pDataLen*/) { return nullptr; } -void Qt5Graphics::FreeEmbedFontData(const void* pData, long nDataLen) {} +void Qt5Graphics::FreeEmbedFontData(const void* /*pData*/, long /*nDataLen*/) {} -void Qt5Graphics::GetGlyphWidths(const PhysicalFontFace* pPFF, bool bVertical, - std::vector<sal_Int32>& rWidths, Ucs2UIntMap& rUnicodeEnc) +void Qt5Graphics::GetGlyphWidths(const PhysicalFontFace* /*pPFF*/, bool /*bVertical*/, + std::vector<sal_Int32>& /*rWidths*/, Ucs2UIntMap& /*rUnicodeEnc*/) { } diff --git a/vcl/qt5/Qt5Instance.cxx b/vcl/qt5/Qt5Instance.cxx index c61a29a01935..b9464fa7fc20 100644 --- a/vcl/qt5/Qt5Instance.cxx +++ b/vcl/qt5/Qt5Instance.cxx @@ -158,7 +158,7 @@ bool Qt5Instance::DoYield(bool bWait, bool bHandleAllCurrentEvents) return bWasEvent; } -bool Qt5Instance::AnyInput(VclInputFlags nType) { return false; } +bool Qt5Instance::AnyInput(VclInputFlags /*nType*/) { return false; } SalSession* Qt5Instance::CreateSalSession() { return nullptr; } diff --git a/vcl/qt5/Qt5Object.cxx b/vcl/qt5/Qt5Object.cxx index 887b949e4c42..d00f3fc14719 100644 --- a/vcl/qt5/Qt5Object.cxx +++ b/vcl/qt5/Qt5Object.cxx @@ -56,7 +56,7 @@ void Qt5Object::EndSetClipRegion() m_pRegion = m_pRegion.intersected(m_pQWidget->geometry()); } -void Qt5Object::SetPosSize(long nX, long nY, long nWidth, long nHeight) {} +void Qt5Object::SetPosSize(long /*nX*/, long /*nY*/, long /*nWidth*/, long /*nHeight*/) {} void Qt5Object::Show(bool bVisible) { @@ -64,7 +64,7 @@ void Qt5Object::Show(bool bVisible) m_pQWidget->setVisible(bVisible); } -void Qt5Object::SetForwardKey(bool bEnable) {} +void Qt5Object::SetForwardKey(bool /*bEnable*/) {} const SystemEnvData* Qt5Object::GetSystemData() const { return nullptr; } commit 2b946181595d198809e8a6a3fb82fd965ac911fa Author: Noel Grandin <noel.gran...@collabora.co.uk> Date: Mon Jan 8 09:05:58 2018 +0200 fix qt5 plugin after commit b0fd921441e1e1066e232282843317514375c8ec Date: Fri Jan 5 13:24:28 2018 +0200 convert tolerance params to sal_uInt8 (second try) Change-Id: I15c2f0a3724976f17bb83e1d07639296cfbb3051 diff --git a/vcl/qt5/Qt5Bitmap.cxx b/vcl/qt5/Qt5Bitmap.cxx index 0f312e0057e2..49b7a22e6fb2 100644 --- a/vcl/qt5/Qt5Bitmap.cxx +++ b/vcl/qt5/Qt5Bitmap.cxx @@ -239,7 +239,7 @@ bool Qt5Bitmap::Scale(const double& rScaleX, const double& rScaleY, BmpScaleFlag return false; } -bool Qt5Bitmap::Replace(const Color& rSearchColor, const Color& rReplaceColor, sal_uLong nTol) +bool Qt5Bitmap::Replace(const Color& rSearchColor, const Color& rReplaceColor, sal_uInt8 nTol) { return false; } diff --git a/vcl/qt5/Qt5Bitmap.hxx b/vcl/qt5/Qt5Bitmap.hxx index c8d35e2050cc..6ecdebed5ca1 100644 --- a/vcl/qt5/Qt5Bitmap.hxx +++ b/vcl/qt5/Qt5Bitmap.hxx @@ -61,7 +61,7 @@ public: virtual bool Scale(const double& rScaleX, const double& rScaleY, BmpScaleFlag nScaleFlag) override; virtual bool Replace(const Color& rSearchColor, const Color& rReplaceColor, - sal_uLong nTol) override; + sal_uInt8 nTol) override; }; /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits