Permalink
Browse files

Upgraded to SDK 2.2

Launch the Plus version of the Level Editor instead of the free version
when available.

Allow for installing the game on the SD card on Froyo.


git-svn-id: http://frozenbubbleandroid.googlecode.com/svn@15 349699ee-d245-11de-ad95-0f97ff1b57b8
  • Loading branch information...
1 parent aafe55c commit 42f813a74f877a863354ada8c221fbf971cfeff4 Pawel Aleksander Fedorynski committed Sep 18, 2010
Showing with 25 additions and 13 deletions.
  1. +3 −2 AndroidManifest.xml
  2. +1 −1 default.properties
  3. +21 −10 src/org/jfedor/frozenbubble/FrozenBubble.java
View
@@ -1,8 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="org.jfedor.frozenbubble"
- android:versionCode="7"
- android:versionName="1.6">
+ android:installLocation="preferExternal"
+ android:versionCode="8"
+ android:versionName="1.7">
<supports-screens
android:smallScreens="true"
android:normalScreens="true"
View
@@ -8,4 +8,4 @@
# project structure.
# Project target.
-target=android-5
+target=android-8
@@ -386,22 +386,33 @@ protected void onNewIntent(Intent intent) {
private void startEditor()
{
Intent i = new Intent();
- i.setClassName("sk.halmi.fbedit", "sk.halmi.fbedit.EditorActivity");
+ // First try to run the plus version of Editor.
+ i.setClassName("sk.halmi.fbeditplus",
+ "sk.halmi.fbeditplus.EditorActivity");
try {
startActivity(i);
finish();
} catch (ActivityNotFoundException e) {
- // But if user doesn't have Frozen Bubble Editor take him to market.
+ // If not found, try to run the normal version.
+ i.setClassName("sk.halmi.fbedit",
+ "sk.halmi.fbedit.EditorActivity");
try {
- Toast.makeText(getApplicationContext(), R.string.install_editor, 1000).
- show();
- i = new Intent(Intent.ACTION_VIEW,
- Uri.parse("market://search?q=pname:sk.halmi.fbedit"));
startActivity(i);
- } catch (Exception ex) {
- // Damn you don't have market?
- Toast.makeText(getApplicationContext(), R.string.market_missing, 1000).
- show();
+ finish();
+ } catch (ActivityNotFoundException ex) {
+ // If user doesnt have Frozen Bubble Editor take him to market.
+ try {
+ Toast.makeText(getApplicationContext(),
+ R.string.install_editor, 1000).show();
+ i = new Intent(Intent.ACTION_VIEW,
+ Uri.parse(
+ "market://search?q=frozen bubble level editor"));
+ startActivity(i);
+ } catch (Exception exc) {
+ // Damn you don't have market?
+ Toast.makeText(getApplicationContext(),
+ R.string.market_missing, 1000).show();
+ }
}
}
}

0 comments on commit 42f813a

Please sign in to comment.