summaryrefslogtreecommitdiff
path: root/android
diff options
context:
space:
mode:
authorSiqi Liu <me@siqi.fr>2015-04-06 11:58:49 +0200
committerMiklos Vajna <vmiklos@collabora.co.uk>2015-04-07 09:18:20 +0200
commit26afe0a3392060257ccfeaa92545c39fcab880f5 (patch)
tree2241da6241c1177ed6d8f80d099dc932b10d288c /android
parentfa9b324f8eff93e05bd9ba3813b93e1bdc35aa30 (diff)
add italic/underline button with icons for different screen res
Change-Id: Ib158f32af7ef8d65d4ddd822839b260161a74343
Diffstat (limited to 'android')
-rw-r--r--android/experimental/LOAndroid3/res/drawable-hdpi/action_bold.pngbin0 -> 1281 bytes
-rw-r--r--android/experimental/LOAndroid3/res/drawable-hdpi/action_italic.pngbin0 -> 903 bytes
-rw-r--r--android/experimental/LOAndroid3/res/drawable-hdpi/action_underline.pngbin0 -> 926 bytes
-rw-r--r--android/experimental/LOAndroid3/res/drawable-mdpi/action_bold.pngbin0 -> 851 bytes
-rw-r--r--android/experimental/LOAndroid3/res/drawable-mdpi/action_italic.pngbin0 -> 661 bytes
-rw-r--r--android/experimental/LOAndroid3/res/drawable-mdpi/action_underline.pngbin0 -> 684 bytes
-rw-r--r--android/experimental/LOAndroid3/res/drawable-xhdpi/action_bold.pngbin0 -> 1670 bytes
-rw-r--r--android/experimental/LOAndroid3/res/drawable-xhdpi/action_italic.pngbin0 -> 1320 bytes
-rw-r--r--android/experimental/LOAndroid3/res/drawable-xhdpi/action_underline.pngbin0 -> 1337 bytes
-rw-r--r--android/experimental/LOAndroid3/res/drawable-xxxhdpi/action_bold.pngbin0 -> 3610 bytes
-rw-r--r--android/experimental/LOAndroid3/res/drawable-xxxhdpi/action_italic.pngbin0 -> 2570 bytes
-rw-r--r--android/experimental/LOAndroid3/res/drawable-xxxhdpi/action_underline.pngbin0 -> 2940 bytes
-rw-r--r--android/experimental/LOAndroid3/res/drawable-xxxhdpi/ic_format_bold_grey600_24dp.pngbin719 -> 0 bytes
-rw-r--r--android/experimental/LOAndroid3/res/menu/main.xml14
-rw-r--r--android/experimental/LOAndroid3/res/values/strings.xml2
-rw-r--r--android/experimental/LOAndroid3/src/java/org/libreoffice/LibreOfficeMainActivity.java6
16 files changed, 21 insertions, 1 deletions
diff --git a/android/experimental/LOAndroid3/res/drawable-hdpi/action_bold.png b/android/experimental/LOAndroid3/res/drawable-hdpi/action_bold.png
new file mode 100644
index 000000000000..950d61556c6a
--- /dev/null
+++ b/android/experimental/LOAndroid3/res/drawable-hdpi/action_bold.png
Binary files differ
diff --git a/android/experimental/LOAndroid3/res/drawable-hdpi/action_italic.png b/android/experimental/LOAndroid3/res/drawable-hdpi/action_italic.png
new file mode 100644
index 000000000000..399bb9c3cb00
--- /dev/null
+++ b/android/experimental/LOAndroid3/res/drawable-hdpi/action_italic.png
Binary files differ
diff --git a/android/experimental/LOAndroid3/res/drawable-hdpi/action_underline.png b/android/experimental/LOAndroid3/res/drawable-hdpi/action_underline.png
new file mode 100644
index 000000000000..09f8b20b41d4
--- /dev/null
+++ b/android/experimental/LOAndroid3/res/drawable-hdpi/action_underline.png
Binary files differ
diff --git a/android/experimental/LOAndroid3/res/drawable-mdpi/action_bold.png b/android/experimental/LOAndroid3/res/drawable-mdpi/action_bold.png
new file mode 100644
index 000000000000..bc60968c6fcf
--- /dev/null
+++ b/android/experimental/LOAndroid3/res/drawable-mdpi/action_bold.png
Binary files differ
diff --git a/android/experimental/LOAndroid3/res/drawable-mdpi/action_italic.png b/android/experimental/LOAndroid3/res/drawable-mdpi/action_italic.png
new file mode 100644
index 000000000000..6394cf9066b8
--- /dev/null
+++ b/android/experimental/LOAndroid3/res/drawable-mdpi/action_italic.png
Binary files differ
diff --git a/android/experimental/LOAndroid3/res/drawable-mdpi/action_underline.png b/android/experimental/LOAndroid3/res/drawable-mdpi/action_underline.png
new file mode 100644
index 000000000000..3b6c7f607700
--- /dev/null
+++ b/android/experimental/LOAndroid3/res/drawable-mdpi/action_underline.png
Binary files differ
diff --git a/android/experimental/LOAndroid3/res/drawable-xhdpi/action_bold.png b/android/experimental/LOAndroid3/res/drawable-xhdpi/action_bold.png
new file mode 100644
index 000000000000..95c985edd4c7
--- /dev/null
+++ b/android/experimental/LOAndroid3/res/drawable-xhdpi/action_bold.png
Binary files differ
diff --git a/android/experimental/LOAndroid3/res/drawable-xhdpi/action_italic.png b/android/experimental/LOAndroid3/res/drawable-xhdpi/action_italic.png
new file mode 100644
index 000000000000..e4366f4e0b96
--- /dev/null
+++ b/android/experimental/LOAndroid3/res/drawable-xhdpi/action_italic.png
Binary files differ
diff --git a/android/experimental/LOAndroid3/res/drawable-xhdpi/action_underline.png b/android/experimental/LOAndroid3/res/drawable-xhdpi/action_underline.png
new file mode 100644
index 000000000000..421a7505b915
--- /dev/null
+++ b/android/experimental/LOAndroid3/res/drawable-xhdpi/action_underline.png
Binary files differ
diff --git a/android/experimental/LOAndroid3/res/drawable-xxxhdpi/action_bold.png b/android/experimental/LOAndroid3/res/drawable-xxxhdpi/action_bold.png
new file mode 100644
index 000000000000..c5256f51a049
--- /dev/null
+++ b/android/experimental/LOAndroid3/res/drawable-xxxhdpi/action_bold.png
Binary files differ
diff --git a/android/experimental/LOAndroid3/res/drawable-xxxhdpi/action_italic.png b/android/experimental/LOAndroid3/res/drawable-xxxhdpi/action_italic.png
new file mode 100644
index 000000000000..a5e921fb8a10
--- /dev/null
+++ b/android/experimental/LOAndroid3/res/drawable-xxxhdpi/action_italic.png
Binary files differ
diff --git a/android/experimental/LOAndroid3/res/drawable-xxxhdpi/action_underline.png b/android/experimental/LOAndroid3/res/drawable-xxxhdpi/action_underline.png
new file mode 100644
index 000000000000..4cd7971937d8
--- /dev/null
+++ b/android/experimental/LOAndroid3/res/drawable-xxxhdpi/action_underline.png
Binary files differ
diff --git a/android/experimental/LOAndroid3/res/drawable-xxxhdpi/ic_format_bold_grey600_24dp.png b/android/experimental/LOAndroid3/res/drawable-xxxhdpi/ic_format_bold_grey600_24dp.png
deleted file mode 100644
index 2d7688a9aadc..000000000000
--- a/android/experimental/LOAndroid3/res/drawable-xxxhdpi/ic_format_bold_grey600_24dp.png
+++ /dev/null
Binary files differ
diff --git a/android/experimental/LOAndroid3/res/menu/main.xml b/android/experimental/LOAndroid3/res/menu/main.xml
index 8670ed3658fc..1a1c22a14cb6 100644
--- a/android/experimental/LOAndroid3/res/menu/main.xml
+++ b/android/experimental/LOAndroid3/res/menu/main.xml
@@ -6,7 +6,19 @@
<item android:id="@+id/action_bold"
android:title="@string/action_bold"
- android:icon="@drawable/ic_format_bold_grey600_24dp"
+ android:icon="@drawable/action_bold"
+ android:orderInCategory="100"
+ app:showAsAction="always"/>
+
+ <item android:id="@+id/action_italic"
+ android:title="@string/action_italic"
+ android:icon="@drawable/action_italic"
+ android:orderInCategory="100"
+ app:showAsAction="always"/>
+
+ <item android:id="@+id/action_underline"
+ android:title="@string/action_underline"
+ android:icon="@drawable/action_underline"
android:orderInCategory="100"
app:showAsAction="always"/>
diff --git a/android/experimental/LOAndroid3/res/values/strings.xml b/android/experimental/LOAndroid3/res/values/strings.xml
index 3d8c3aa6f9ef..939804dbb93e 100644
--- a/android/experimental/LOAndroid3/res/values/strings.xml
+++ b/android/experimental/LOAndroid3/res/values/strings.xml
@@ -35,6 +35,8 @@
<string name="local_documents">Local documents</string>
<string name="local_file_system">Local file system</string>
<string name="action_bold">Bold</string>
+ <string name="action_underline">Underline</string>
+ <string name="action_italic">Italic</string>
<string name="action_keyboard">Show keyboard</string>
</resources>
diff --git a/android/experimental/LOAndroid3/src/java/org/libreoffice/LibreOfficeMainActivity.java b/android/experimental/LOAndroid3/src/java/org/libreoffice/LibreOfficeMainActivity.java
index 3aaa2b204257..ed87f8c4ac74 100644
--- a/android/experimental/LOAndroid3/src/java/org/libreoffice/LibreOfficeMainActivity.java
+++ b/android/experimental/LOAndroid3/src/java/org/libreoffice/LibreOfficeMainActivity.java
@@ -78,6 +78,12 @@ public class LibreOfficeMainActivity extends ActionBarActivity {
case R.id.action_bold:
LOKitShell.sendEvent(new LOEvent(LOEvent.UNO_COMMAND, ".uno:Bold"));
return true;
+ case R.id.action_italic:
+ LOKitShell.sendEvent(new LOEvent(LOEvent.UNO_COMMAND, ".uno:Italic"));
+ return true;
+ case R.id.action_underline:
+ LOKitShell.sendEvent(new LOEvent(LOEvent.UNO_COMMAND, ".uno:Underline"));
+ return true;
case R.id.action_keyboard:
showSoftKeyboard();
break;