summaryrefslogtreecommitdiff
path: root/sfx2
diff options
context:
space:
mode:
authorMiklos Vajna <vmiklos@collabora.com>2022-09-16 09:12:43 +0200
committerMiklos Vajna <vmiklos@collabora.com>2022-09-16 10:21:41 +0200
commit08bce8eeb2e18c7cea4108dbfc2519ada56e8b61 (patch)
tree5e6eb6037316f1832ad119b3f74af29fbd97f86e /sfx2
parenta2aaa6b77457041e08610eb4bced2d050ea7fa4f (diff)
sw content controls: fix getString() and setString() on SwXContentControl
The setter was broken, it inserted the new content at the start, but didn't delete the old content. The getter was also broken, it returned an empty string, even if the content control had a non-empty content. This was always a problem since c4268efef25129b162884312b15527f1e5c3bcb0 (sw content controls: add UNO API to insert this, 2022-03-31) introduced SwXContentControl. Fix the problem by extending SwXTextCursor, so in case m_eType is CursorType::ContentControl, then it keeps the cursor's range inside the boundaries of the content control. This also allows changing the data binding code added in b5c616d10bff3213840d4893d13b4493de71fa56 (tdf#104823: support for sdt plain text fields, 2021-11-24) to use content controls, in a follow-up commit. Change-Id: Ic3ae47a4b26af090539d61035372f1784c8ffe3f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/140040 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
Diffstat (limited to 'sfx2')
0 files changed, 0 insertions, 0 deletions