fixed bug in onCreateDialog preventing the ProgressDialog from being properly displayed
authorbongo <bongo@bird.localdomain>
Wed, 5 Oct 2011 15:09:33 +0000 (17:09 +0200)
committerbongo <bongo@bird.localdomain>
Wed, 5 Oct 2011 15:09:33 +0000 (17:09 +0200)
16 files changed:
bin/HQBeamer.apk
bin/classes.dex
bin/de/bongo/android/hqbeamer/HQBeamerActivity$1.class
bin/de/bongo/android/hqbeamer/HQBeamerActivity$2.class
bin/de/bongo/android/hqbeamer/HQBeamerActivity$3.class
bin/de/bongo/android/hqbeamer/HQBeamerActivity$4.class
bin/de/bongo/android/hqbeamer/HQBeamerActivity$5.class
bin/de/bongo/android/hqbeamer/HQBeamerActivity$6.class
bin/de/bongo/android/hqbeamer/HQBeamerActivity$7.class
bin/de/bongo/android/hqbeamer/HQBeamerActivity$8.class
bin/de/bongo/android/hqbeamer/HQBeamerActivity$ConnectThread.class
bin/de/bongo/android/hqbeamer/HQBeamerActivity$ConnectedThread.class
bin/de/bongo/android/hqbeamer/HQBeamerActivity.class
bin/resources.ap_
res/layout/main.xml
src/de/bongo/android/hqbeamer/HQBeamerActivity.java

index eb7a8bb..6ea10d4 100644 (file)
Binary files a/bin/HQBeamer.apk and b/bin/HQBeamer.apk differ
index bda68ec..4dee843 100644 (file)
Binary files a/bin/classes.dex and b/bin/classes.dex differ
index 5cd4e5e..36aabf3 100644 (file)
Binary files a/bin/de/bongo/android/hqbeamer/HQBeamerActivity$1.class and b/bin/de/bongo/android/hqbeamer/HQBeamerActivity$1.class differ
index 02cc03d..1ee8101 100644 (file)
Binary files a/bin/de/bongo/android/hqbeamer/HQBeamerActivity$2.class and b/bin/de/bongo/android/hqbeamer/HQBeamerActivity$2.class differ
index 2c888b0..7301e07 100644 (file)
Binary files a/bin/de/bongo/android/hqbeamer/HQBeamerActivity$3.class and b/bin/de/bongo/android/hqbeamer/HQBeamerActivity$3.class differ
index 5a04bac..4b7b1f3 100644 (file)
Binary files a/bin/de/bongo/android/hqbeamer/HQBeamerActivity$4.class and b/bin/de/bongo/android/hqbeamer/HQBeamerActivity$4.class differ
index 780e241..92f004f 100644 (file)
Binary files a/bin/de/bongo/android/hqbeamer/HQBeamerActivity$5.class and b/bin/de/bongo/android/hqbeamer/HQBeamerActivity$5.class differ
index 1b782ab..3d325f2 100644 (file)
Binary files a/bin/de/bongo/android/hqbeamer/HQBeamerActivity$6.class and b/bin/de/bongo/android/hqbeamer/HQBeamerActivity$6.class differ
index 51780f2..6ad6538 100644 (file)
Binary files a/bin/de/bongo/android/hqbeamer/HQBeamerActivity$7.class and b/bin/de/bongo/android/hqbeamer/HQBeamerActivity$7.class differ
index 01a7cd6..3bb639b 100644 (file)
Binary files a/bin/de/bongo/android/hqbeamer/HQBeamerActivity$8.class and b/bin/de/bongo/android/hqbeamer/HQBeamerActivity$8.class differ
index 3a805c1..e2b6d2e 100644 (file)
Binary files a/bin/de/bongo/android/hqbeamer/HQBeamerActivity$ConnectThread.class and b/bin/de/bongo/android/hqbeamer/HQBeamerActivity$ConnectThread.class differ
index 0ae5bb0..f14fb04 100644 (file)
Binary files a/bin/de/bongo/android/hqbeamer/HQBeamerActivity$ConnectedThread.class and b/bin/de/bongo/android/hqbeamer/HQBeamerActivity$ConnectedThread.class differ
index 78a8260..71a98db 100644 (file)
Binary files a/bin/de/bongo/android/hqbeamer/HQBeamerActivity.class and b/bin/de/bongo/android/hqbeamer/HQBeamerActivity.class differ
index e837854..6363b43 100644 (file)
Binary files a/bin/resources.ap_ and b/bin/resources.ap_ differ
index 9864fd3..d23190c 100644 (file)
@@ -4,7 +4,6 @@
                                android:layout_height="fill_parent"
                                xmlns:android="http://schemas.android.com/apk/res/android">
         <ToggleButton android:layout_height="wrap_content"
-                                 android:text="powerToggle"
                                  android:layout_width="match_parent"
                                  android:id="@+id/powerToggle"
                                  android:layout_centerHorizontal="true"
index 9d13a99..e5efab5 100644 (file)
@@ -40,6 +40,7 @@ public class HQBeamerActivity extends Activity {
        private static final int ERROR_CONNECTING = 1;
        private static final int WARN_CHOOSE_DEVICE = 2;
        private static final int ERROR_BLUETOOTH_NOT_SUPPORTED = 3;
+       private static final int CONNECTING = 4;
        private BluetoothAdapter mBluetoothAdapter;
        private ConnectThread connectThread;
        private ConnectedThread connectedThread;
@@ -267,9 +268,14 @@ public class HQBeamerActivity extends Activity {
        }
     }
     
-protected Dialog onCreateDialog(int id){
+    protected Dialog onCreateDialog(int id){
        Dialog dialog;
        switch(id){
+        case CONNECTING:
+            dialog = new ProgressDialog(this);
+            ((ProgressDialog)dialog).setMessage("Connecting");
+            dialog.setTitle("");
+            return dialog;
        case ERROR_CONNECTING:
                dialog = new AlertDialog.Builder(HQBeamerActivity.this)
                                                                .setTitle("Connection Error")
@@ -348,6 +354,7 @@ protected Dialog onCreateDialog(int id){
                             // Get the BluetoothDevice object
                             beamer = mBluetoothAdapter.getRemoteDevice(address);
                             // Attempt to connect to the device
+                            showDialog(CONNECTING);
                             connectThread = new ConnectThread(beamer);
                             connectThread.start();
                        }