sc/source/ui/app/inputwin.cxx |    2 ++
 sc/source/ui/inc/inputwin.hxx |    7 ++++---
 2 files changed, 6 insertions(+), 3 deletions(-)

New commits:
commit 60fee02026f649536b1de4f8dd212f130636c7ec
Author:     Marco Cecchetti <marco.cecche...@collabora.com>
AuthorDate: Mon Apr 20 13:48:06 2020 +0200
Commit:     Andras Timar <andras.ti...@collabora.com>
CommitDate: Sun May 10 11:17:48 2020 +0200

    lok: calc: input bar: send number of text lines to client
    
    Change-Id: Iec919ef11e22ae5d02009570f446064e3f7bfe01
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/92690
    Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoff...@gmail.com>
    Reviewed-by: Andras Timar <andras.ti...@collabora.com>
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/93345
    Tested-by: Jenkins

diff --git a/sc/source/ui/app/inputwin.cxx b/sc/source/ui/app/inputwin.cxx
index c06efda5f978..485a4565e232 100644
--- a/sc/source/ui/app/inputwin.cxx
+++ b/sc/source/ui/app/inputwin.cxx
@@ -516,6 +516,7 @@ void ScInputWindow::Resize()
     {
         std::vector<vcl::LOKPayloadItem> aItems;
         aItems.emplace_back("size", GetSizePixel().toString());
+        aItems.emplace_back("lines", 
OString::number(aTextWindow.GetNumLines()));
         pNotifier->notifyWindow(GetLOKWindowId(), "size_changed", aItems);
     }
 
@@ -536,6 +537,7 @@ void ScInputWindow::NotifyLOKClient()
             aItems.emplace_back("type", "calc-input-win");
             aItems.emplace_back(std::make_pair("position", 
Point(GetOutOffXPixel(), GetOutOffYPixel()).toString()));
             aItems.emplace_back(std::make_pair("size", aSize.toString()));
+            aItems.emplace_back("lines", 
OString::number(aTextWindow.GetNumLines()));
             pNotifier->notifyWindow(GetLOKWindowId(), "created", aItems);
         }
 
diff --git a/sc/source/ui/inc/inputwin.hxx b/sc/source/ui/inc/inputwin.hxx
index e439f5066bde..584011fa4a59 100644
--- a/sc/source/ui/inc/inputwin.hxx
+++ b/sc/source/ui/inc/inputwin.hxx
@@ -57,6 +57,7 @@ public:
     virtual void            SetFormulaMode( bool bSet ) = 0;
     virtual bool            IsInputActive() = 0;
     virtual void            TextGrabFocus() = 0;
+    virtual long            GetNumLines() const = 0;
 };
 
 class ScTextWnd : public ScTextWndBase, public DragSourceHelper     // edit 
window
@@ -95,7 +96,7 @@ public:
     long GetPixelHeightForLines(long nLines);
     long GetEditEngTxtHeight() const;
 
-    long GetNumLines() const { return mnLines; }
+    virtual long GetNumLines() const override { return mnLines; }
     void SetNumLines(long nLines);
     long GetLastNumExpandedLines() const { return mnLastExpandedLines; }
 
@@ -198,7 +199,7 @@ public:
     virtual void            
InsertAccessibleTextData(ScAccessibleEditLineTextData& rTextData) override;
     virtual EditView*       GetEditView() override;
     long                    GetLastNumExpandedLines() const;
-    long                    GetNumLines() const;
+    virtual long            GetNumLines() const override;
     long                    GetPixelHeightForLines(long nLines);
     ScrollBar&              GetScrollBar();
     virtual const OUString& GetTextString() const override;
@@ -243,7 +244,7 @@ public:
     bool                    IsInputActive() override;
     void                    IncrementVerticalSize();
     void                    DecrementVerticalSize();
-    long                    GetNumLines() const { return 
maTextWndGroup->GetNumLines(); }
+    virtual long            GetNumLines() const override { return 
maTextWndGroup->GetNumLines(); }
     long                    GetVertOffset() const { return  mnVertOffset; }
 
 private:
_______________________________________________
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to