From d59f7b8b5039de866b10b8a58c41cf835c6d08f3 Mon Sep 17 00:00:00 2001 From: Sergey Solovyev Date: Wed, 21 Nov 2012 00:23:54 +0400 Subject: [PATCH] Calculator overlay added --- calculatorpp/AndroidManifest.xml | 19 ++ calculatorpp/res/layout/overlay_layout.xml | 34 ++++ calculatorpp/res/values/theme_gray.xml | 5 + .../calculator/CalculatorApplication.java | 7 +- ...efaultExternalCalculatorIntentHandler.java | 90 ++++++++++ .../external/ExternalCalculatorHelper.java | 69 ++++++++ .../ExternalCalculatorIntentHandler.java | 15 ++ .../ExternalCalculatorStateUpdater.java | 18 ++ .../CalculatorOverlayBroadcastReceiver.java | 25 +++ .../overlay/CalculatorOverlayService.java | 163 ++++++++++++++++++ .../AbstractCalculatorWidgetProvider.java | 131 ++------------ .../widget/CalculatorWidgetHelper.java | 5 +- .../widget/CalculatorWidgetIntentHandler.java | 37 ++++ .../calculator/widget/WidgetButton.java | 2 +- 14 files changed, 499 insertions(+), 121 deletions(-) create mode 100644 calculatorpp/res/layout/overlay_layout.xml create mode 100644 calculatorpp/src/main/java/org/solovyev/android/calculator/external/DefaultExternalCalculatorIntentHandler.java create mode 100644 calculatorpp/src/main/java/org/solovyev/android/calculator/external/ExternalCalculatorHelper.java create mode 100644 calculatorpp/src/main/java/org/solovyev/android/calculator/external/ExternalCalculatorIntentHandler.java create mode 100644 calculatorpp/src/main/java/org/solovyev/android/calculator/external/ExternalCalculatorStateUpdater.java create mode 100644 calculatorpp/src/main/java/org/solovyev/android/calculator/overlay/CalculatorOverlayBroadcastReceiver.java create mode 100644 calculatorpp/src/main/java/org/solovyev/android/calculator/overlay/CalculatorOverlayService.java create mode 100644 calculatorpp/src/main/java/org/solovyev/android/calculator/widget/CalculatorWidgetIntentHandler.java diff --git a/calculatorpp/AndroidManifest.xml b/calculatorpp/AndroidManifest.xml index ef5ac5c9..5e5e471a 100644 --- a/calculatorpp/AndroidManifest.xml +++ b/calculatorpp/AndroidManifest.xml @@ -6,6 +6,9 @@ + + + @@ -48,6 +51,22 @@ + + + + + + + + + + + + + + + + diff --git a/calculatorpp/res/layout/overlay_layout.xml b/calculatorpp/res/layout/overlay_layout.xml new file mode 100644 index 00000000..0d5bb932 --- /dev/null +++ b/calculatorpp/res/layout/overlay_layout.xml @@ -0,0 +1,34 @@ + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/calculatorpp/res/values/theme_gray.xml b/calculatorpp/res/values/theme_gray.xml index 19c56f35..1ffb78ea 100644 --- a/calculatorpp/res/values/theme_gray.xml +++ b/calculatorpp/res/values/theme_gray.xml @@ -86,6 +86,11 @@ match_parent + +