[Libreoffice-commits] core.git: Branch 'feature/gsoc14-draw-chained-text-boxes' - include/svx svx/source
matteocam
matteo.campanelli at gmail.com
Mon Jul 6 13:37:13 PDT 2015
include/svx/textchainflow.hxx | 3 +++
svx/source/svdraw/textchainflow.cxx | 20 ++++++++++++++++++++
2 files changed, 23 insertions(+)
New commits:
commit bbe782455d41af44bb42f39b7f0a2ffc73af1fb5
Author: matteocam <matteo.campanelli at gmail.com>
Date: Mon Jul 6 16:35:38 2015 -0400
Update cursor event
Change-Id: Iad5429e73e8a5fdf3ffd6c88759cbcaf772a5a31
diff --git a/include/svx/textchainflow.hxx b/include/svx/textchainflow.hxx
index 5489bb1..aa17f1e 100644
--- a/include/svx/textchainflow.hxx
+++ b/include/svx/textchainflow.hxx
@@ -76,6 +76,9 @@ class TextChainFlow {
// -- Private Members --
private:
+
+ void impUpdateCursorEvent(SdrOutliner *, bool);
+
SdrTextObj *mpTargetLink;
SdrTextObj *mpNextLink;
diff --git a/svx/source/svdraw/textchainflow.cxx b/svx/source/svdraw/textchainflow.cxx
index 1e63cc7..74f15a1 100644
--- a/svx/source/svdraw/textchainflow.cxx
+++ b/svx/source/svdraw/textchainflow.cxx
@@ -73,6 +73,8 @@ void TextChainFlow::impCheckForFlowEvents(SdrOutliner *pFlowOutl, SdrOutliner *p
bool bIsPageOverflow = pFlowOutl->IsPageOverflow();
+ impUpdateCursorEvent(pFlowOutl, bIsPageOverflow);
+
if (pParamOutl != NULL)
{
pFlowOutl->SetUpdateMode(bOldUpdateMode); // XXX: Plausibly should be the prev. state
@@ -90,6 +92,24 @@ void TextChainFlow::impCheckForFlowEvents(SdrOutliner *pFlowOutl, SdrOutliner *p
}
+void TextChainFlow::impUpdateCursorEvent(SdrOutliner *pFlowOutl, bool bIsOverflow)
+{
+ // XXX: Current implementation might create problems with UF-
+ // In fact UF causes a
+
+
+ if (bIsOverflow) {
+ bool bCursorOut = true; // XXX: Should have real check
+ if (bCursorOut) {
+ GetTextChain()->SetCursorEvent(GetLinkTarget(),
+ CursorChainingEvent::TO_NEXT_LINK);
+ }
+ } else {
+ GetTextChain()->SetCursorEvent(GetLinkTarget(),
+ CursorChainingEvent::UNCHANGED);
+ }
+}
+
void TextChainFlow::CheckForFlowEvents(SdrOutliner *pFlowOutl)
{
impCheckForFlowEvents(pFlowOutl, NULL);
More information about the Libreoffice-commits
mailing list