[Libreoffice-commits] core.git: android/Bootstrap android/source

Mert Tumer merttumer at outlook.com
Sun Mar 19 21:45:42 UTC 2017


 android/Bootstrap/src/org/libreoffice/kit/Document.java           |    2 ++
 android/source/src/java/org/libreoffice/FormattingController.java |    6 ++++++
 android/source/src/java/org/libreoffice/InvalidationHandler.java  |    4 ++++
 3 files changed, 12 insertions(+)

New commits:
commit 088fb93a7b178b076d293d15c049132ba2975a26
Author: Mert Tumer <merttumer at outlook.com>
Date:   Sun Mar 19 14:55:24 2017 +0200

    tdf#106369 added toggle status ability for the list buttons
    
    Change-Id: Ic3132441bac57abf36e3588e6871c5b14a47c25d
    Reviewed-on: https://gerrit.libreoffice.org/35427
    Tested-by: Jenkins <ci at libreoffice.org>
    Reviewed-by: Tomaž Vajngerl <quikee at gmail.com>

diff --git a/android/Bootstrap/src/org/libreoffice/kit/Document.java b/android/Bootstrap/src/org/libreoffice/kit/Document.java
index dcc315faca4c..a7d3f04938bb 100644
--- a/android/Bootstrap/src/org/libreoffice/kit/Document.java
+++ b/android/Bootstrap/src/org/libreoffice/kit/Document.java
@@ -49,6 +49,8 @@ public class Document {
     public static final int ALIGN_CENTER = 5;
     public static final int ALIGN_RIGHT= 6;
     public static final int ALIGN_JUSTIFY= 7;
+    public static final int NUMBERED_LIST= 8;
+    public static final int BULLET_LIST= 9;
 
     /**
      * Callback message types
diff --git a/android/source/src/java/org/libreoffice/FormattingController.java b/android/source/src/java/org/libreoffice/FormattingController.java
index fd2e007416cf..ea8b6fb54e85 100644
--- a/android/source/src/java/org/libreoffice/FormattingController.java
+++ b/android/source/src/java/org/libreoffice/FormattingController.java
@@ -105,6 +105,12 @@ import org.libreoffice.kit.Document;
                     case Document.ALIGN_JUSTIFY:
                         buttonId = R.id.button_align_justify;
                         break;
+                    case Document.BULLET_LIST:
+                        buttonId = R.id.button_insertFormatListBullets;
+                        break;
+                    case Document.NUMBERED_LIST:
+                        buttonId = R.id.button_insertFormatListNumbering;
+                        break;
                     default:
                         Log.e(LOGTAG, "Uncaptured state change type: " + type);
                         return;
diff --git a/android/source/src/java/org/libreoffice/InvalidationHandler.java b/android/source/src/java/org/libreoffice/InvalidationHandler.java
index 4edef18c21d0..c4316c50a119 100644
--- a/android/source/src/java/org/libreoffice/InvalidationHandler.java
+++ b/android/source/src/java/org/libreoffice/InvalidationHandler.java
@@ -113,6 +113,10 @@ public class InvalidationHandler implements Document.MessageCallback {
             mContext.getFormattingController().onToggleStateChanged(Document.ALIGN_RIGHT, pressed);
         } else if (parts[0].equals(".uno:JustifyPara")) {
             mContext.getFormattingController().onToggleStateChanged(Document.ALIGN_JUSTIFY, pressed);
+        } else if (parts[0].equals(".uno:DefaultBullet")) {
+            mContext.getFormattingController().onToggleStateChanged(Document.BULLET_LIST, pressed);
+        } else if (parts[0].equals(".uno:DefaultNumbering")) {
+            mContext.getFormattingController().onToggleStateChanged(Document.NUMBERED_LIST, pressed);
         } else {
             Log.d(LOGTAG, "LOK_CALLBACK_STATE_CHANGED type uncatched: " + payload);
         }


More information about the Libreoffice-commits mailing list