[Libreoffice-commits] core.git: Branch 'feature/tiled-editing' - android/experimental

Siqi Liu me at siqi.fr
Mon Apr 6 05:07:17 PDT 2015


 android/experimental/LOAndroid3/res/drawable-hdpi/action_strikeout.png                |binary
 android/experimental/LOAndroid3/res/drawable-mdpi/action_strikeout.png                |binary
 android/experimental/LOAndroid3/res/drawable-xhdpi/action_strikeout.png               |binary
 android/experimental/LOAndroid3/res/drawable-xxxhdpi/action_strikeout.png             |binary
 android/experimental/LOAndroid3/res/menu/main.xml                                     |    6 ++++++
 android/experimental/LOAndroid3/res/values/strings.xml                                |    1 +
 android/experimental/LOAndroid3/src/java/org/libreoffice/LibreOfficeMainActivity.java |    6 +++++-
 7 files changed, 12 insertions(+), 1 deletion(-)

New commits:
commit c2418ab28f5593593468100549cf81e96d99b221
Author: Siqi Liu <me at siqi.fr>
Date:   Mon Apr 6 14:03:35 2015 +0200

    implement strike out and .uno:Save
    
    .uno:Save works out of box for when tested against documents (impress,
    calc) loaded directly from dropbox for example. However, it doesn't work with
    impress/calc documents loaded from local files. Writer documents won't
    save, either locally or from network resources. More research needed.
    
    Change-Id: Ibdcc209a71f14ec91ba9c1152b305e0278787713

diff --git a/android/experimental/LOAndroid3/res/drawable-hdpi/action_strikeout.png b/android/experimental/LOAndroid3/res/drawable-hdpi/action_strikeout.png
new file mode 100644
index 0000000..f7682ab
Binary files /dev/null and b/android/experimental/LOAndroid3/res/drawable-hdpi/action_strikeout.png differ
diff --git a/android/experimental/LOAndroid3/res/drawable-mdpi/action_strikeout.png b/android/experimental/LOAndroid3/res/drawable-mdpi/action_strikeout.png
new file mode 100644
index 0000000..955f1cb
Binary files /dev/null and b/android/experimental/LOAndroid3/res/drawable-mdpi/action_strikeout.png differ
diff --git a/android/experimental/LOAndroid3/res/drawable-xhdpi/action_strikeout.png b/android/experimental/LOAndroid3/res/drawable-xhdpi/action_strikeout.png
new file mode 100644
index 0000000..e9eccc8
Binary files /dev/null and b/android/experimental/LOAndroid3/res/drawable-xhdpi/action_strikeout.png differ
diff --git a/android/experimental/LOAndroid3/res/drawable-xxxhdpi/action_strikeout.png b/android/experimental/LOAndroid3/res/drawable-xxxhdpi/action_strikeout.png
new file mode 100644
index 0000000..0b2c39f
Binary files /dev/null and b/android/experimental/LOAndroid3/res/drawable-xxxhdpi/action_strikeout.png differ
diff --git a/android/experimental/LOAndroid3/res/menu/main.xml b/android/experimental/LOAndroid3/res/menu/main.xml
index 979bbd1..09314f5 100644
--- a/android/experimental/LOAndroid3/res/menu/main.xml
+++ b/android/experimental/LOAndroid3/res/menu/main.xml
@@ -16,6 +16,12 @@
           android:orderInCategory="100"
           app:showAsAction="always"/>
 
+    <item android:id="@+id/action_strikeout"
+          android:title="@string/action_strikeout"
+          android:icon="@drawable/action_strikeout"
+          android:orderInCategory="100"
+          app:showAsAction="always"/>
+
     <item android:id="@+id/action_underline"
           android:title="@string/action_underline"
           android:icon="@drawable/action_underline"
diff --git a/android/experimental/LOAndroid3/res/values/strings.xml b/android/experimental/LOAndroid3/res/values/strings.xml
index 0b9e7a2..ffce3d8 100644
--- a/android/experimental/LOAndroid3/res/values/strings.xml
+++ b/android/experimental/LOAndroid3/res/values/strings.xml
@@ -37,6 +37,7 @@
     <string name="action_bold">Bold</string>
     <string name="action_underline">Underline</string>
     <string name="action_italic">Italic</string>
+    <string name="action_strikeout">Strike Out</string>
     <string name="action_keyboard">Show keyboard</string>
     <string name="action_save">Save</string>
 
diff --git a/android/experimental/LOAndroid3/src/java/org/libreoffice/LibreOfficeMainActivity.java b/android/experimental/LOAndroid3/src/java/org/libreoffice/LibreOfficeMainActivity.java
index 4664687..c831977 100644
--- a/android/experimental/LOAndroid3/src/java/org/libreoffice/LibreOfficeMainActivity.java
+++ b/android/experimental/LOAndroid3/src/java/org/libreoffice/LibreOfficeMainActivity.java
@@ -85,6 +85,9 @@ public class LibreOfficeMainActivity extends ActionBarActivity {
             case R.id.action_underline:
                 LOKitShell.sendEvent(new LOEvent(LOEvent.UNO_COMMAND, ".uno:Underline"));
                 return true;
+            case R.id.action_strikeout:
+                LOKitShell.sendEvent(new LOEvent(LOEvent.UNO_COMMAND, ".uno:StrikeOut"));
+                return true;
             case R.id.action_keyboard:
                 showSoftKeyboard();
                 break;
@@ -92,7 +95,8 @@ public class LibreOfficeMainActivity extends ActionBarActivity {
                 mAbout.showAbout();
                 return true;
             case R.id.action_save:
-                Toast.makeText(this, "saving the document...", Toast.LENGTH_SHORT).show();
+                Toast.makeText(this, "Saving the document...", Toast.LENGTH_SHORT).show();
+                LOKitShell.sendEvent(new LOEvent(LOEvent.UNO_COMMAND, ".uno:Save"));
                 return true;
             case R.id.action_parts:
                 mDrawerLayout.openDrawer(mDrawerList);


More information about the Libreoffice-commits mailing list