From 141526450d9d24eba234a657919543c4563fd444 Mon Sep 17 00:00:00 2001 From: serso Date: Sun, 2 Oct 2011 14:12:13 +0400 Subject: [PATCH] var activity --- res/layout/var.xml | 9 + res/layout/var_edit.xml | 6 +- res/menu/main_menu.xml | 7 +- res/menu/var_menu.xml | 13 ++ res/values/colors.xml | 3 +- res/values/strings.xml | 4 + res/values/styles.xml | 2 +- .../{preferences.xml => main_preferences.xml} | 0 .../calculator/CalculatorActivity.java | 8 +- .../CalculatorPreferencesActivity.java | 4 +- .../calculator/CalculatorVarsActivity.java | 200 ++++++++++++++---- .../org/solovyev/android/calculator/Var.java | 86 ++++++-- .../org/solovyev/android/calculator/Vars.java | 2 +- .../android/calculator/VarsRegister.java | 46 ++-- .../calculator/math/MathEntityType.java | 9 +- .../android/view/widgets/ColorButton.java | 3 +- 16 files changed, 312 insertions(+), 90 deletions(-) create mode 100644 res/menu/var_menu.xml rename res/xml/{preferences.xml => main_preferences.xml} (100%) diff --git a/res/layout/var.xml b/res/layout/var.xml index cba3dbf8..0c6b0707 100644 --- a/res/layout/var.xml +++ b/res/layout/var.xml @@ -29,4 +29,13 @@ + + + \ No newline at end of file diff --git a/res/layout/var_edit.xml b/res/layout/var_edit.xml index 5bf580ab..f5350a67 100644 --- a/res/layout/var_edit.xml +++ b/res/layout/var_edit.xml @@ -16,7 +16,7 @@ a:layout_width="wrap_content" a:text="Name"/> - @@ -26,7 +26,7 @@ a:layout_width="wrap_content" a:text="Value"/> - - diff --git a/res/menu/main_menu.xml b/res/menu/main_menu.xml index 3998aa42..511a8f1b 100644 --- a/res/menu/main_menu.xml +++ b/res/menu/main_menu.xml @@ -2,9 +2,12 @@ - - + + \ No newline at end of file diff --git a/res/menu/var_menu.xml b/res/menu/var_menu.xml new file mode 100644 index 00000000..e7ed20bb --- /dev/null +++ b/res/menu/var_menu.xml @@ -0,0 +1,13 @@ + + + + + + + + \ No newline at end of file diff --git a/res/values/colors.xml b/res/values/colors.xml index 56cc6b39..dcae5b06 100644 --- a/res/values/colors.xml +++ b/res/values/colors.xml @@ -1,4 +1,5 @@ #00ffffff - #ffffffff + #ffffffff + #ffffffff \ No newline at end of file diff --git a/res/values/strings.xml b/res/values/strings.xml index 03689a1c..cce93c68 100644 --- a/res/values/strings.xml +++ b/res/values/strings.xml @@ -33,4 +33,8 @@ Color expressions Precision of result + Exit + Add + Cancel + Save diff --git a/res/values/styles.xml b/res/values/styles.xml index eb061e64..a51fe817 100644 --- a/res/values/styles.xml +++ b/res/values/styles.xml @@ -29,7 +29,7 @@