diff options
author | Miklos Vajna <vmiklos@collabora.com> | 2019-05-06 14:27:04 +0200 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.com> | 2019-05-06 15:16:58 +0200 |
commit | b86ca947115f2ef61dd71c7a43e7a3ec1f1cf3b0 (patch) | |
tree | bf9fdd1b8c45f3f12c8f42e776a3f6d10c3149a2 /desktop | |
parent | 8c71d28069acffa2d4590a4acf95a98d1415b563 (diff) |
desktop: turn on clang-format for lokclipboard
This had manual consistent formatting. Recently it was broken, so bring
back consisency by using clang-format.
Change-Id: If4303e379ddc77e5190f8e8e42737b4f7d680a71
Reviewed-on: https://gerrit.libreoffice.org/71857
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Tested-by: Jenkins
Diffstat (limited to 'desktop')
-rw-r--r-- | desktop/source/lib/lokclipboard.cxx | 31 | ||||
-rw-r--r-- | desktop/source/lib/lokclipboard.hxx | 6 |
2 files changed, 19 insertions, 18 deletions
diff --git a/desktop/source/lib/lokclipboard.cxx b/desktop/source/lib/lokclipboard.cxx index b02dc3ca172b..e8c8644eff84 100644 --- a/desktop/source/lib/lokclipboard.cxx +++ b/desktop/source/lib/lokclipboard.cxx @@ -17,26 +17,25 @@ uno::Reference<datatransfer::XTransferable> SAL_CALL LOKClipboard::getContents() return m_xTransferable; } -void SAL_CALL LOKClipboard::setContents(const uno::Reference<datatransfer::XTransferable>& xTransferable, - const uno::Reference<datatransfer::clipboard::XClipboardOwner>& /*xClipboardOwner*/) +void SAL_CALL LOKClipboard::setContents( + const uno::Reference<datatransfer::XTransferable>& xTransferable, + const uno::Reference<datatransfer::clipboard::XClipboardOwner>& /*xClipboardOwner*/) { m_xTransferable = xTransferable; } -OUString SAL_CALL LOKClipboard::getName() -{ - return OUString(); -} +OUString SAL_CALL LOKClipboard::getName() { return OUString(); } LOKTransferable::LOKTransferable(const char* pMimeType, const char* pData, std::size_t nSize) - : m_aMimeType(OUString::fromUtf8(pMimeType)), - m_aSequence(reinterpret_cast<const sal_Int8*>(pData), nSize) + : m_aMimeType(OUString::fromUtf8(pMimeType)) + , m_aSequence(reinterpret_cast<const sal_Int8*>(pData), nSize) { } -LOKTransferable::LOKTransferable(const OUString& sMimeType, const css::uno::Sequence<sal_Int8>& aSequence) - : m_aMimeType(sMimeType), - m_aSequence(aSequence) +LOKTransferable::LOKTransferable(const OUString& sMimeType, + const css::uno::Sequence<sal_Int8>& aSequence) + : m_aMimeType(sMimeType) + , m_aSequence(aSequence) { } @@ -58,7 +57,7 @@ std::vector<datatransfer::DataFlavor> LOKTransferable::getTransferDataFlavorsAsV std::vector<datatransfer::DataFlavor> aRet; datatransfer::DataFlavor aFlavor; aFlavor.MimeType = m_aMimeType; - aFlavor.DataType = cppu::UnoType< uno::Sequence<sal_Int8> >::get(); + aFlavor.DataType = cppu::UnoType<uno::Sequence<sal_Int8>>::get(); sal_Int32 nIndex(0); if (m_aMimeType.getToken(0, ';', nIndex) == "text/plain") @@ -80,10 +79,10 @@ uno::Sequence<datatransfer::DataFlavor> SAL_CALL LOKTransferable::getTransferDat sal_Bool SAL_CALL LOKTransferable::isDataFlavorSupported(const datatransfer::DataFlavor& rFlavor) { const std::vector<datatransfer::DataFlavor> aFlavors = getTransferDataFlavorsAsVector(); - return std::any_of(aFlavors.begin(), aFlavors.end(), [&rFlavor](const datatransfer::DataFlavor& i) - { - return i.MimeType == rFlavor.MimeType && i.DataType == rFlavor.DataType; - }); + return std::any_of(aFlavors.begin(), aFlavors.end(), + [&rFlavor](const datatransfer::DataFlavor& i) { + return i.MimeType == rFlavor.MimeType && i.DataType == rFlavor.DataType; + }); } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/desktop/source/lib/lokclipboard.hxx b/desktop/source/lib/lokclipboard.hxx index ae83eb6dd2e6..c8896d01e739 100644 --- a/desktop/source/lib/lokclipboard.hxx +++ b/desktop/source/lib/lokclipboard.hxx @@ -23,8 +23,10 @@ class LOKClipboard : public cppu::WeakImplHelper<css::datatransfer::clipboard::X public: css::uno::Reference<css::datatransfer::XTransferable> SAL_CALL getContents() override; - void SAL_CALL setContents(const css::uno::Reference<css::datatransfer::XTransferable>& xTransferable, - const css::uno::Reference<css::datatransfer::clipboard::XClipboardOwner>& xClipboardOwner) override; + void SAL_CALL setContents( + const css::uno::Reference<css::datatransfer::XTransferable>& xTransferable, + const css::uno::Reference<css::datatransfer::clipboard::XClipboardOwner>& xClipboardOwner) + override; OUString SAL_CALL getName() override; }; |