summaryrefslogtreecommitdiff
path: root/sw/inc
diff options
context:
space:
mode:
authorMike Kaganski <mike.kaganski@collabora.com>2022-08-17 08:40:31 +0300
committerMike Kaganski <mike.kaganski@collabora.com>2022-08-17 11:59:38 +0200
commitb34577840b679b428490ae24fd644645ca5c76f0 (patch)
tree33526d766cbdef36f57f04bd11ca6591cd236025 /sw/inc
parent1433a0e3ebfe43d9f1aeb07d37facb4a529163df (diff)
Return std::optional instead of using bool* argument
Change-Id: I47f03411a6677f22291bea4dc06920ab9052349a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138399 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com> (cherry picked from commit 364e8272329ba893af4141ac054fdc71816bd44a) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138291 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Diffstat (limited to 'sw/inc')
-rw-r--r--sw/inc/view.hxx2
-rw-r--r--sw/inc/viscrs.hxx6
2 files changed, 5 insertions, 3 deletions
diff --git a/sw/inc/view.hxx b/sw/inc/view.hxx
index d074f0d552a7..514074e603c9 100644
--- a/sw/inc/view.hxx
+++ b/sw/inc/view.hxx
@@ -693,7 +693,7 @@ public:
virtual tools::Rectangle getLOKVisibleArea() const override;
virtual void flushPendingLOKInvalidateTiles() override;
- virtual OString getLOKPayload(int nType, int nViewId, bool* ignore) const override;
+ virtual std::optional<OString> getLOKPayload(int nType, int nViewId) const override;
};
inline tools::Long SwView::GetXScroll() const
diff --git a/sw/inc/viscrs.hxx b/sw/inc/viscrs.hxx
index 6126f5ffa0c0..123ff61b2303 100644
--- a/sw/inc/viscrs.hxx
+++ b/sw/inc/viscrs.hxx
@@ -26,6 +26,8 @@
#include "swregion.hxx"
#include "swdllapi.h"
+#include <optional>
+
namespace sdr::overlay { class OverlayObject; }
class SwCursorShell;
@@ -61,7 +63,7 @@ public:
void SetPosAndShow(SfxViewShell const * pViewShell);
const vcl::Cursor& GetTextCursor() const;
- OString getLOKPayload(int nType, int nViewId, bool* ignore) const;
+ std::optional<OString> getLOKPayload(int nType, int nViewId) const;
};
// From here classes/methods for selections.
@@ -123,7 +125,7 @@ public:
static void Get1PixelInLogic( const SwViewShell& rSh,
tools::Long* pX = nullptr, tools::Long* pY = nullptr );
- OString getLOKPayload(int nType, int nViewId, bool* ignore) const;
+ std::optional<OString> getLOKPayload(int nType, int nViewId) const;
};
class SW_DLLPUBLIC SwShellCursor : public virtual SwCursor, public SwSelPaintRects