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

Libreoffice Gerrit user logerrit at kemper.freedesktop.org
Fri Nov 2 06:04:00 UTC 2018


 android/source/src/java/org/libreoffice/FontController.java      |    5 ++++-
 android/source/src/java/org/libreoffice/InvalidationHandler.java |    6 +++++-
 2 files changed, 9 insertions(+), 2 deletions(-)

New commits:
commit 2f88877af05e1a277f68b07faabba0ccc3d86b3b
Author:     Mert Tumer <merttumer at outlook.com>
AuthorDate: Thu Nov 1 19:49:35 2018 +0300
Commit:     Gülşah Köse <gulsah.1004 at gmail.com>
CommitDate: Fri Nov 2 07:03:27 2018 +0100

    [Pardus] fix highlight color in Presentation On Android
    
    This patch is sponsored by ULAKBIM/Pardus project.
    Signed-off-by: Mert Tumer <merttumer at outlook.com>
    
    Change-Id: Ic56991b2957be91822d040d776a3dfcef2d5b451
    Reviewed-on: https://gerrit.libreoffice.org/62753
    Tested-by: Jenkins
    Reviewed-by: Gülşah Köse <gulsah.1004 at gmail.com>

diff --git a/android/source/src/java/org/libreoffice/FontController.java b/android/source/src/java/org/libreoffice/FontController.java
index 250a67bbd8c9..1ac8fd6cf90f 100644
--- a/android/source/src/java/org/libreoffice/FontController.java
+++ b/android/source/src/java/org/libreoffice/FontController.java
@@ -160,7 +160,10 @@ public class FontController implements AdapterView.OnItemSelectedListener {
             if(mActivity.isSpreadsheet()){
                 json.put("BackgroundColor", valueJson);
                 LOKitShell.sendEvent(new LOEvent(LOEvent.UNO_COMMAND, ".uno:BackgroundColor", json.toString()));
-            } else {
+            }else if(mActivity.getTileProvider().isPresentation()){
+                json.put("CharBackColor", valueJson);
+                LOKitShell.sendEvent(new LOEvent(LOEvent.UNO_COMMAND, ".uno:CharBackColor", json.toString()));
+            }else {
                 json.put("BackColor", valueJson);
                 LOKitShell.sendEvent(new LOEvent(LOEvent.UNO_COMMAND, ".uno:BackColor", json.toString()));
             }
diff --git a/android/source/src/java/org/libreoffice/InvalidationHandler.java b/android/source/src/java/org/libreoffice/InvalidationHandler.java
index 0f72e7272004..436b5c513c3b 100644
--- a/android/source/src/java/org/libreoffice/InvalidationHandler.java
+++ b/android/source/src/java/org/libreoffice/InvalidationHandler.java
@@ -320,7 +320,11 @@ public class InvalidationHandler implements Document.MessageCallback, Office.Mes
             mContext.getFormattingController().onToggleStateChanged(Document.NUMBERED_LIST, pressed);
         } else if (parts[0].equals(".uno:Color")) {
             mContext.getFontController().colorPaletteListener.updateColorPickerPosition(Integer.parseInt(value));
-        } else if (parts[0].equals(".uno:BackColor")) {
+        } else if (mContext.getTileProvider().isTextDocument() && parts[0].equals(".uno:BackColor")) {
+            mContext.getFontController().backColorPaletteListener.updateColorPickerPosition(Integer.parseInt(value));
+        } else if (mContext.getTileProvider().isPresentation() && parts[0].equals(".uno:CharBackColor")) {
+            mContext.getFontController().backColorPaletteListener.updateColorPickerPosition(Integer.parseInt(value));
+        } else if (mContext.getTileProvider().isSpreadsheet() && parts[0].equals(".uno:BackgroundColor")) {
             mContext.getFontController().backColorPaletteListener.updateColorPickerPosition(Integer.parseInt(value));
         } else if (parts[0].equals(".uno:StatePageNumber")) {
             // get the total page number and compare to the current value and update accordingly


More information about the Libreoffice-commits mailing list