Hello!

To see the file structure, click on "tree".

Note that updates take place every 10 minutes, commits may not be seen immediately.
set up information passing infrastructure
authormiles <miles@localhost>
Thu, 19 Sep 2013 23:03:43 +0000 (23:03 +0000)
committermiles <miles@localhost>
Thu, 19 Sep 2013 23:03:43 +0000 (23:03 +0000)
svn path=/; revision=503

16 files changed:
Personnel/justin/lab inventory/AndroidManifest.xml
Personnel/justin/lab inventory/bin/AndroidManifest.xml [new file with mode: 0644]
Personnel/justin/lab inventory/bin/AndroidManifest.xml.svntmp [new file with mode: 0644]
Personnel/justin/lab inventory/bin/classes.dex [new file with mode: 0644]
Personnel/justin/lab inventory/bin/lab inventory.apk [new file with mode: 0644]
Personnel/justin/lab inventory/bin/res/crunch/drawable-hdpi/ic_action_search.png [new file with mode: 0644]
Personnel/justin/lab inventory/bin/res/crunch/drawable-hdpi/ic_launcher.png [new file with mode: 0644]
Personnel/justin/lab inventory/bin/res/crunch/drawable-ldpi/ic_launcher.png [new file with mode: 0644]
Personnel/justin/lab inventory/bin/res/crunch/drawable-mdpi/ic_action_search.png [new file with mode: 0644]
Personnel/justin/lab inventory/bin/res/crunch/drawable-mdpi/ic_launcher.png [new file with mode: 0644]
Personnel/justin/lab inventory/bin/res/crunch/drawable-xhdpi/ic_action_search.png [new file with mode: 0644]
Personnel/justin/lab inventory/bin/res/crunch/drawable-xhdpi/ic_launcher.png [new file with mode: 0644]
Personnel/justin/lab inventory/bin/resources.ap_ [new file with mode: 0644]
Personnel/justin/lab inventory/res/layout/activity_main.xml
Personnel/justin/lab inventory/res/values/strings.xml
Personnel/justin/lab inventory/src/com/jaiswallab/lab/inventory/MainActivity.java

index 133dfcb3910885126d302fe302d5e8f6043f08f1..e3220b61f602a2dcdb0724af62c0055168417e22 100644 (file)
@@ -22,4 +22,5 @@
         </activity>
     </application>
 
+    
 </manifest>
\ No newline at end of file
diff --git a/Personnel/justin/lab inventory/bin/AndroidManifest.xml b/Personnel/justin/lab inventory/bin/AndroidManifest.xml
new file mode 100644 (file)
index 0000000..e3220b6
--- /dev/null
@@ -0,0 +1,26 @@
+<manifest xmlns:android="http://schemas.android.com/apk/res/android"
+    package="com.jaiswallab.lab.inventory"
+    android:versionCode="1"
+    android:versionName="1.0" >
+
+    <uses-sdk
+        android:minSdkVersion="8"
+        android:targetSdkVersion="18" />
+
+    <application
+        android:icon="@drawable/ic_launcher"
+        android:label="@string/app_name"
+        android:theme="@style/AppTheme" >
+        <activity
+            android:name=".MainActivity"
+            android:label="@string/title_activity_main" >
+            <intent-filter>
+                <action android:name="android.intent.action.MAIN" />
+
+                <category android:name="android.intent.category.LAUNCHER" />
+            </intent-filter>
+        </activity>
+    </application>
+
+    
+</manifest>
\ No newline at end of file
diff --git a/Personnel/justin/lab inventory/bin/AndroidManifest.xml.svntmp b/Personnel/justin/lab inventory/bin/AndroidManifest.xml.svntmp
new file mode 100644 (file)
index 0000000..133dfcb
--- /dev/null
@@ -0,0 +1,25 @@
+<manifest xmlns:android="http://schemas.android.com/apk/res/android"
+    package="com.jaiswallab.lab.inventory"
+    android:versionCode="1"
+    android:versionName="1.0" >
+
+    <uses-sdk
+        android:minSdkVersion="8"
+        android:targetSdkVersion="18" />
+
+    <application
+        android:icon="@drawable/ic_launcher"
+        android:label="@string/app_name"
+        android:theme="@style/AppTheme" >
+        <activity
+            android:name=".MainActivity"
+            android:label="@string/title_activity_main" >
+            <intent-filter>
+                <action android:name="android.intent.action.MAIN" />
+
+                <category android:name="android.intent.category.LAUNCHER" />
+            </intent-filter>
+        </activity>
+    </application>
+
+</manifest>
\ No newline at end of file
diff --git a/Personnel/justin/lab inventory/bin/classes.dex b/Personnel/justin/lab inventory/bin/classes.dex
new file mode 100644 (file)
index 0000000..f0f7b11
Binary files /dev/null and b/Personnel/justin/lab inventory/bin/classes.dex differ
diff --git a/Personnel/justin/lab inventory/bin/lab inventory.apk b/Personnel/justin/lab inventory/bin/lab inventory.apk
new file mode 100644 (file)
index 0000000..575a65b
Binary files /dev/null and b/Personnel/justin/lab inventory/bin/lab inventory.apk differ
diff --git a/Personnel/justin/lab inventory/bin/res/crunch/drawable-hdpi/ic_action_search.png b/Personnel/justin/lab inventory/bin/res/crunch/drawable-hdpi/ic_action_search.png
new file mode 100644 (file)
index 0000000..ffec9be
Binary files /dev/null and b/Personnel/justin/lab inventory/bin/res/crunch/drawable-hdpi/ic_action_search.png differ
diff --git a/Personnel/justin/lab inventory/bin/res/crunch/drawable-hdpi/ic_launcher.png b/Personnel/justin/lab inventory/bin/res/crunch/drawable-hdpi/ic_launcher.png
new file mode 100644 (file)
index 0000000..498a287
Binary files /dev/null and b/Personnel/justin/lab inventory/bin/res/crunch/drawable-hdpi/ic_launcher.png differ
diff --git a/Personnel/justin/lab inventory/bin/res/crunch/drawable-ldpi/ic_launcher.png b/Personnel/justin/lab inventory/bin/res/crunch/drawable-ldpi/ic_launcher.png
new file mode 100644 (file)
index 0000000..7d9eba3
Binary files /dev/null and b/Personnel/justin/lab inventory/bin/res/crunch/drawable-ldpi/ic_launcher.png differ
diff --git a/Personnel/justin/lab inventory/bin/res/crunch/drawable-mdpi/ic_action_search.png b/Personnel/justin/lab inventory/bin/res/crunch/drawable-mdpi/ic_action_search.png
new file mode 100644 (file)
index 0000000..ce9399c
Binary files /dev/null and b/Personnel/justin/lab inventory/bin/res/crunch/drawable-mdpi/ic_action_search.png differ
diff --git a/Personnel/justin/lab inventory/bin/res/crunch/drawable-mdpi/ic_launcher.png b/Personnel/justin/lab inventory/bin/res/crunch/drawable-mdpi/ic_launcher.png
new file mode 100644 (file)
index 0000000..9eb7580
Binary files /dev/null and b/Personnel/justin/lab inventory/bin/res/crunch/drawable-mdpi/ic_launcher.png differ
diff --git a/Personnel/justin/lab inventory/bin/res/crunch/drawable-xhdpi/ic_action_search.png b/Personnel/justin/lab inventory/bin/res/crunch/drawable-xhdpi/ic_action_search.png
new file mode 100644 (file)
index 0000000..b2d7b2d
Binary files /dev/null and b/Personnel/justin/lab inventory/bin/res/crunch/drawable-xhdpi/ic_action_search.png differ
diff --git a/Personnel/justin/lab inventory/bin/res/crunch/drawable-xhdpi/ic_launcher.png b/Personnel/justin/lab inventory/bin/res/crunch/drawable-xhdpi/ic_launcher.png
new file mode 100644 (file)
index 0000000..cd07610
Binary files /dev/null and b/Personnel/justin/lab inventory/bin/res/crunch/drawable-xhdpi/ic_launcher.png differ
diff --git a/Personnel/justin/lab inventory/bin/resources.ap_ b/Personnel/justin/lab inventory/bin/resources.ap_
new file mode 100644 (file)
index 0000000..626024f
Binary files /dev/null and b/Personnel/justin/lab inventory/bin/resources.ap_ differ
index f3c7910decb9c15b207ba6a9afc07ba23d449a4e..d41352c3754e38d678bf85b4ba79f13cd2511138 100644 (file)
@@ -3,25 +3,6 @@
     android:layout_width="match_parent"
     android:layout_height="match_parent" >
 
-    <Button
-        android:id="@+id/button2"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_centerHorizontal="true"
-        android:layout_centerVertical="true"
-        android:text="@string/inventory_button"
-        android:onClick="inventoryClick" />
-
-    <Button
-        android:id="@+id/button1"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_alignParentTop="true"
-        android:layout_centerHorizontal="true"
-        android:layout_marginTop="64dp"
-        android:text="@string/qr_button"
-        android:onClick="qrClick" />
-
     <EditText
         android:id="@+id/editText1"
         android:layout_width="wrap_content"
         android:layout_marginLeft="24dp"
         android:ems="10"
         android:text="@string/hello_world" >
+    </EditText>
+
+    <EditText
+        android:id="@+id/editText2"
+        android:layout_width="wrap_content"
+        android:layout_height="wrap_content"
+        android:layout_alignLeft="@+id/button2"
+        android:layout_alignParentRight="true"
+        android:layout_alignParentTop="true"
+        android:layout_marginTop="154dp"
+        android:ems="10"
+        android:hint="new data:" >
 
         <requestFocus />
     </EditText>
 
-</RelativeLayout>
+    <Button
+        android:id="@+id/button2"
+        android:layout_width="wrap_content"
+        android:layout_height="wrap_content"
+        android:layout_alignBottom="@+id/editText2"
+        android:layout_alignParentRight="true"
+        android:layout_marginBottom="66dp"
+        android:onClick="scanQRClick"
+        android:text="@string/scan_qr_button" />
+
+    <Button
+        android:id="@+id/button1"
+        android:layout_width="wrap_content"
+        android:layout_height="wrap_content"
+        android:layout_alignBaseline="@+id/button2"
+        android:layout_alignBottom="@+id/button2"
+        android:layout_alignParentLeft="true"
+        android:onClick="recognizeQRClick"
+        android:text="@string/recognize_qr_button" />
+
+</RelativeLayout>
\ No newline at end of file
index 69ffbf21ecdde0fcdc97e5822808c3784c36a88b..5011e9938661f41ac5bc68f106a1a64243197c97 100644 (file)
@@ -6,5 +6,7 @@
     <string name="title_activity_main">Lab Inventory</string>
     <string name="qr_button">Start QR code scanner</string>
     <string name="inventory_button">Check inventory</string>
-
+    <string name="recognize_qr_button">Recognize QR</string>
+    <string name="scan_qr_button">Scan in QR</string>
+    
 </resources>
\ No newline at end of file
index 31e19938adfd9f168383a98132f7447b708ab322..2fbb3be0ba842b7d507a45018c7638177a3af2ff 100644 (file)
@@ -11,7 +11,13 @@ import android.view.View;
 import android.widget.EditText;
 
 
+
+
+
 public class MainActivity extends Activity {
+
+       boolean scanningNewQR = false;
+       boolean recognizingQR = false;
        private EditText text;
 
     @Override
@@ -28,8 +34,10 @@ public class MainActivity extends Activity {
     }
     
     // This method is called at click of the QR code button
-    public void qrClick(View view) { 
-       text.setText("QR button clicked again");
+    public void recognizeQRClick(View view) { 
+       scanningNewQR = false;
+       recognizingQR = true;
+       text.setText("Recognize QR button clicked");
        IntentIntegrator intentIntegrator = new IntentIntegrator(this);
        intentIntegrator.initiateScan();
        //startActivityForResult(intentIntegrator, 0);
@@ -39,6 +47,11 @@ public class MainActivity extends Activity {
        IntentResult scanResult = IntentIntegrator.parseActivityResult(requestCode, resultCode, intent);
        if (scanResult != null) {
                String contents = scanResult.getContents();
+               if(scanningNewQR) {
+                       addNewQR(contents);
+               } else if(recognizingQR){
+                       displayQRInfo(contents);
+               }
                text.setText(contents);
                // handle scan result
        }
@@ -46,9 +59,27 @@ public class MainActivity extends Activity {
        }
     
     // This method is called at click of the check inventory button
-    public void inventoryClick(View view) {
-       text.setText("Inventory button clicked");
+    public void scanQRClick(View view) {
+       scanningNewQR = true;
+       recognizingQR = false;
+       text.setText("Scan QR button clicked");
+       IntentIntegrator intentIntegrator = new IntentIntegrator(this);
+       intentIntegrator.initiateScan();
     }
+    
+    //this will use the information passed to it to create a new ID in the databse
+    //it will also use any input from a variety of text edits in order to populate the database entry
+    //can we store pictures in the database if desired?
+    public void addNewQR(String id) {
+       return;
+    }
+    
+    //this will use the information passed to it to reference an existing ID in the database
+    //it will display the database information in a useful format
+    public void displayQRInfo(String id) {
+       return;
+    }
+    
 }