diff --git a/app/src/main/java/org/solovyev/android/calculator/keyboard/PartialKeyboardUi.java b/app/src/main/java/org/solovyev/android/calculator/keyboard/PartialKeyboardUi.java
index cfd4d868..2c98b27c 100644
--- a/app/src/main/java/org/solovyev/android/calculator/keyboard/PartialKeyboardUi.java
+++ b/app/src/main/java/org/solovyev/android/calculator/keyboard/PartialKeyboardUi.java
@@ -9,9 +9,10 @@ import android.support.annotation.Nullable;
import android.text.TextUtils;
import android.util.Log;
import android.view.View;
-import android.widget.Button;
import android.widget.ImageButton;
-
+import butterknife.Bind;
+import butterknife.ButterKnife;
+import jscl.NumeralBase;
import org.solovyev.android.calculator.Engine;
import org.solovyev.android.calculator.Preferences;
import org.solovyev.android.calculator.R;
@@ -19,30 +20,25 @@ import org.solovyev.android.calculator.buttons.CppSpecialButton;
import org.solovyev.android.calculator.view.EditorLongClickEraser;
import org.solovyev.android.calculator.view.NumeralBasesButton;
import org.solovyev.android.views.dragbutton.DirectionDragButton;
+import org.solovyev.android.views.dragbutton.DirectionDragImageButton;
import org.solovyev.android.views.dragbutton.DragDirection;
import javax.annotation.Nonnull;
import javax.inject.Inject;
-import butterknife.Bind;
-import butterknife.ButterKnife;
-import jscl.NumeralBase;
-
import static org.solovyev.android.calculator.Engine.Preferences.numeralBase;
import static org.solovyev.android.calculator.Preferences.Gui.showEqualsButton;
import static org.solovyev.android.calculator.Preferences.Gui.vibrateOnKeypress;
-import static org.solovyev.android.views.dragbutton.DragDirection.down;
-import static org.solovyev.android.views.dragbutton.DragDirection.left;
-import static org.solovyev.android.views.dragbutton.DragDirection.up;
+import static org.solovyev.android.views.dragbutton.DragDirection.*;
public class PartialKeyboardUi extends BaseKeyboardUi {
@Nullable
@Bind(R.id.cpp_button_right)
- DirectionDragButton rightButton;
+ DirectionDragImageButton rightButton;
@Nullable
@Bind(R.id.cpp_button_left)
- DirectionDragButton leftButton;
+ DirectionDragImageButton leftButton;
@Nullable
@Bind(R.id.cpp_button_clear)
NumeralBasesButton clearButton;
@@ -140,8 +136,10 @@ public class PartialKeyboardUi extends BaseKeyboardUi {
public void onClick(View v) {
switch (v.getId()) {
case R.id.cpp_button_left:
+ onClick(v, CppSpecialButton.cursor_left);
+ break;
case R.id.cpp_button_right:
- onClick(v, ((Button) v).getText().toString());
+ onClick(v, CppSpecialButton.cursor_right);
break;
case R.id.cpp_button_clear:
onClick(v, CppSpecialButton.clear);
diff --git a/app/src/main/res/drawable-hdpi/ic_keyboard_arrow_left_white_48dp.png b/app/src/main/res/drawable-hdpi/ic_keyboard_arrow_left_white_48dp.png
new file mode 100644
index 00000000..d8af01c8
Binary files /dev/null and b/app/src/main/res/drawable-hdpi/ic_keyboard_arrow_left_white_48dp.png differ
diff --git a/app/src/main/res/drawable-hdpi/ic_keyboard_arrow_right_white_48dp.png b/app/src/main/res/drawable-hdpi/ic_keyboard_arrow_right_white_48dp.png
new file mode 100644
index 00000000..e9bc3889
Binary files /dev/null and b/app/src/main/res/drawable-hdpi/ic_keyboard_arrow_right_white_48dp.png differ
diff --git a/app/src/main/res/drawable-mdpi/ic_keyboard_arrow_left_white_48dp.png b/app/src/main/res/drawable-mdpi/ic_keyboard_arrow_left_white_48dp.png
new file mode 100644
index 00000000..2b4d614a
Binary files /dev/null and b/app/src/main/res/drawable-mdpi/ic_keyboard_arrow_left_white_48dp.png differ
diff --git a/app/src/main/res/drawable-mdpi/ic_keyboard_arrow_right_white_48dp.png b/app/src/main/res/drawable-mdpi/ic_keyboard_arrow_right_white_48dp.png
new file mode 100644
index 00000000..aa55964e
Binary files /dev/null and b/app/src/main/res/drawable-mdpi/ic_keyboard_arrow_right_white_48dp.png differ
diff --git a/app/src/main/res/drawable-xhdpi/ic_keyboard_arrow_left_white_48dp.png b/app/src/main/res/drawable-xhdpi/ic_keyboard_arrow_left_white_48dp.png
new file mode 100644
index 00000000..36cfbc9a
Binary files /dev/null and b/app/src/main/res/drawable-xhdpi/ic_keyboard_arrow_left_white_48dp.png differ
diff --git a/app/src/main/res/drawable-xhdpi/ic_keyboard_arrow_right_white_48dp.png b/app/src/main/res/drawable-xhdpi/ic_keyboard_arrow_right_white_48dp.png
new file mode 100644
index 00000000..13341cbb
Binary files /dev/null and b/app/src/main/res/drawable-xhdpi/ic_keyboard_arrow_right_white_48dp.png differ
diff --git a/app/src/main/res/drawable-xxhdpi/ic_keyboard_arrow_left_white_48dp.png b/app/src/main/res/drawable-xxhdpi/ic_keyboard_arrow_left_white_48dp.png
new file mode 100644
index 00000000..76004a9e
Binary files /dev/null and b/app/src/main/res/drawable-xxhdpi/ic_keyboard_arrow_left_white_48dp.png differ
diff --git a/app/src/main/res/drawable-xxhdpi/ic_keyboard_arrow_right_white_48dp.png b/app/src/main/res/drawable-xxhdpi/ic_keyboard_arrow_right_white_48dp.png
new file mode 100644
index 00000000..25503d1b
Binary files /dev/null and b/app/src/main/res/drawable-xxhdpi/ic_keyboard_arrow_right_white_48dp.png differ
diff --git a/app/src/main/res/drawable-xxxhdpi/ic_keyboard_arrow_left_white_48dp.png b/app/src/main/res/drawable-xxxhdpi/ic_keyboard_arrow_left_white_48dp.png
new file mode 100644
index 00000000..598eb81a
Binary files /dev/null and b/app/src/main/res/drawable-xxxhdpi/ic_keyboard_arrow_left_white_48dp.png differ
diff --git a/app/src/main/res/drawable-xxxhdpi/ic_keyboard_arrow_right_white_48dp.png b/app/src/main/res/drawable-xxxhdpi/ic_keyboard_arrow_right_white_48dp.png
new file mode 100644
index 00000000..034a3eff
Binary files /dev/null and b/app/src/main/res/drawable-xxxhdpi/ic_keyboard_arrow_right_white_48dp.png differ
diff --git a/app/src/main/res/layout/cpp_app_button_left.xml b/app/src/main/res/layout/cpp_app_button_left.xml
index a186743d..f616ebbd 100644
--- a/app/src/main/res/layout/cpp_app_button_left.xml
+++ b/app/src/main/res/layout/cpp_app_button_left.xml
@@ -22,12 +22,11 @@
~ Site: http://se.solovyev.org
-->
-
\ No newline at end of file
diff --git a/app/src/main/res/layout/cpp_app_button_right.xml b/app/src/main/res/layout/cpp_app_button_right.xml
index 07e39ae8..6983f4ce 100644
--- a/app/src/main/res/layout/cpp_app_button_right.xml
+++ b/app/src/main/res/layout/cpp_app_button_right.xml
@@ -22,12 +22,11 @@
~ Site: http://se.solovyev.org
-->
-
\ No newline at end of file