main menu buttons changed with images
authordrizea <danielrizea27@gmail.com>
Mon, 6 Aug 2012 10:22:14 +0000 (13:22 +0300)
committerdrizea <danielrizea27@gmail.com>
Mon, 6 Aug 2012 10:22:14 +0000 (13:22 +0300)
21 files changed:
Open-ILS/src/Android/res/drawable/advanced_search.png [new file with mode: 0644]
Open-ILS/src/Android/res/drawable/barcode_scan.png [new file with mode: 0644]
Open-ILS/src/Android/res/drawable/header_rounded_corners.xml
Open-ILS/src/Android/res/drawable/library_hours.png [new file with mode: 0644]
Open-ILS/src/Android/res/drawable/one_header_rounded_corner.xml
Open-ILS/src/Android/res/drawable/preferences.png [new file with mode: 0644]
Open-ILS/src/Android/res/layout-land/search_result_list.xml
Open-ILS/src/Android/res/layout/search_result_item.xml
Open-ILS/src/Android/res/layout/search_result_list.xml
Open-ILS/src/Android/res/layout/simple_actionbar.xml
Open-ILS/src/Android/res/values/colors.xml
Open-ILS/src/Android/res/values/styles.xml
Open-ILS/src/Android/src/org/evergreen/android/accountAccess/bookbags/BookBagDetails.java
Open-ILS/src/Android/src/org/evergreen/android/accountAccess/bookbags/BookbagsListView.java
Open-ILS/src/Android/src/org/evergreen/android/accountAccess/checkout/ItemsCheckOutListView.java
Open-ILS/src/Android/src/org/evergreen/android/accountAccess/fines/FinesActivity.java
Open-ILS/src/Android/src/org/evergreen/android/accountAccess/holds/HoldDetails.java
Open-ILS/src/Android/src/org/evergreen/android/accountAccess/holds/HoldsListView.java
Open-ILS/src/Android/src/org/evergreen/android/accountAccess/holds/PlaceHold.java
Open-ILS/src/Android/src/org/evergreen/android/searchCatalog/SampleUnderlinesNoFade.java
Open-ILS/src/Android/src/org/evergreen/android/searchCatalog/SearchCatalogListView.java

diff --git a/Open-ILS/src/Android/res/drawable/advanced_search.png b/Open-ILS/src/Android/res/drawable/advanced_search.png
new file mode 100644 (file)
index 0000000..133fb2a
Binary files /dev/null and b/Open-ILS/src/Android/res/drawable/advanced_search.png differ
diff --git a/Open-ILS/src/Android/res/drawable/barcode_scan.png b/Open-ILS/src/Android/res/drawable/barcode_scan.png
new file mode 100644 (file)
index 0000000..e5b0024
Binary files /dev/null and b/Open-ILS/src/Android/res/drawable/barcode_scan.png differ
index 723a013..171d967 100644 (file)
@@ -1,7 +1,10 @@
 <?xml version="1.0" encoding="UTF-8"?> 
 <shape xmlns:android="http://schemas.android.com/apk/res/android" 
      android:shape="rectangle"> 
-     <gradient android:startColor="@color/header_gradient_stop" android:endColor="@color/header_gradient_stop" 
+     <gradient 
+         
+         android:startColor="@color/header_gradient_start" android:endColor="@color/header_gradient_stop" 
+
             android:angle="270"/> 
 
     <corners android:bottomRightRadius="8dp" android:bottomLeftRadius="8dp" /> 
diff --git a/Open-ILS/src/Android/res/drawable/library_hours.png b/Open-ILS/src/Android/res/drawable/library_hours.png
new file mode 100644 (file)
index 0000000..5eac49d
Binary files /dev/null and b/Open-ILS/src/Android/res/drawable/library_hours.png differ
index f081f7b..f4da0d5 100644 (file)
@@ -1,7 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?> 
 <shape xmlns:android="http://schemas.android.com/apk/res/android" 
      android:shape="rectangle"> 
-     <gradient android:startColor="@color/header_gradient_start" android:endColor="@color/header_gradient_stop" 
+     <gradient android:startColor="@color/header_gradient_stop" android:endColor="@color/header_gradient_stop" 
             android:angle="270"/> 
 
     <corners android:bottomLeftRadius="8dp"/> 
diff --git a/Open-ILS/src/Android/res/drawable/preferences.png b/Open-ILS/src/Android/res/drawable/preferences.png
new file mode 100644 (file)
index 0000000..819cb8d
Binary files /dev/null and b/Open-ILS/src/Android/res/drawable/preferences.png differ
index ab0dd08..f245754 100644 (file)
@@ -1,7 +1,9 @@
 <?xml version="1.0" encoding="utf-8"?>
 <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
     android:layout_width="fill_parent"
-    android:layout_height="fill_parent">
+    android:layout_height="fill_parent"
+    android:background="@color/background"
+    >
 
     <RelativeLayout
         android:id="@+id/header"
         android:paddingTop="3dip"
         >
         
-        <ImageButton 
+                <Button
             android:id="@+id/library_logo"
+            style="@style/LibraryLogoText"
             android:layout_width="wrap_content"
             android:layout_height="wrap_content"
-            style="@style/LibraryLogoText"
             android:layout_alignParentLeft="true"
-            android:src="@drawable/evergreen_launcher_icon_48"
             android:layout_marginLeft="5dip"
+            android:drawableLeft="@drawable/evergreen_launcher_icon_48"
+            android:text="@string/library_text_logo" 
+            android:textColor="@color/white"
+            android:textSize="16dp"
+            android:typeface="monospace"
+            android:textStyle="bold"
+            android:paddingLeft="5dip"
             />
 
         <Button
-            android:id="@+id/my_acount_button"
+            android:id="@+id/my_account_button"
             android:layout_width="wrap_content"
             android:layout_height="wrap_content"
             android:text="@string/my_account_button_text"
          >
 
              
-             <Button 
-                android:id="@+id/menu_advanced_search_button"
-             android:layout_width="100dip"
-             android:layout_height="wrap_content"
-             android:text="@string/menu_button_advanced_search"
-             android:drawableTop="@drawable/settings_small"
-             style="@style/MenuListButton"
-             />
-         
-            <Button 
-             android:id="@+id/library_hours_button"
-             android:layout_width="100dip"
-             android:layout_height="wrap_content"
-             android:text="@string/menu_button_library_hours"
-             android:drawableTop="@drawable/settings_small"
-             style="@style/MenuListButton"
-             />    
-                 
+             <ImageButton
+                android:id="@+id/menu_advanced_search_button"
+                style="@style/MenuListButton"
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:src="@drawable/advanced_search" />
+
+            <ImageButton
+                android:id="@+id/library_hours_button"
+                style="@style/MenuListButton"
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:src="@drawable/library_hours" />
+            
+
+            <ImageButton
+                android:id="@+id/preference_button"
+                style="@style/MenuListButton"
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:src="@drawable/preferences"
+                />
+            
+                <ImageButton
+                android:id="@+id/barcode_scan_button"
+                style="@style/MenuListButton"
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:src="@drawable/barcode_scan"/>
             
-                 
-             <Button
-             android:id="@+id/preference_button" 
-             android:layout_width="100dip"
-             android:layout_height="wrap_content"
-             android:text="@string/menu_button_application_preferences"
-             android:drawableTop="@drawable/settings_small"
-             style="@style/MenuListButton"
-             />
             
      </LinearLayout>
           <LinearLayout android:layout_width="fill_parent"
index 2b3270d..3629f7d 100644 (file)
@@ -6,7 +6,9 @@
        android:paddingBottom="3px"
        android:paddingTop="3px" 
        android:paddingLeft="3px" 
-    android:orientation="horizontal" >
+    android:orientation="horizontal"
+    android:background="@color/background"
+     >
 
        <ImageView
                android:id="@+id/search_record_img"
index 79d6372..b170788 100644 (file)
@@ -2,6 +2,7 @@
 <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
     android:layout_width="fill_parent"
     android:layout_height="fill_parent"
+    android:background="@color/background"
      >
 
     <RelativeLayout
         android:paddingBottom="2dip"
          >
 
-        <ImageButton
+        <Button
             android:id="@+id/library_logo"
             style="@style/LibraryLogoText"
             android:layout_width="wrap_content"
             android:layout_height="wrap_content"
             android:layout_alignParentLeft="true"
             android:layout_marginLeft="5dip"
-            android:src="@drawable/evergreen_launcher_icon_48" />
-
+            android:drawableLeft="@drawable/evergreen_launcher_icon_48"
+            android:text="@string/library_text_logo" 
+            android:textColor="@color/white"
+            android:textSize="16dp"
+            android:typeface="monospace"
+            android:textStyle="bold"
+            android:paddingLeft="5dip"
+            />
+        
         <Button
-            android:id="@+id/my_acount_button"
+            android:id="@+id/my_account_button"
             android:layout_width="wrap_content"
             android:layout_height="wrap_content"
             android:layout_alignParentRight="true"
 
         <LinearLayout
             android:layout_width="fill_parent"
-            android:layout_height="wrap_content" >
+            android:layout_height="wrap_content"
+            android:gravity="center"
+             >
 
-            <Button
+            <ImageButton
                 android:id="@+id/menu_advanced_search_button"
-                style="@style/MenuListOrangeButton"
-                android:layout_width="150dip"
+                style="@style/MenuListButton"
+                android:layout_width="wrap_content"
                 android:layout_height="wrap_content"
-                android:drawableTop="@drawable/settings_small"
-                android:text="@string/menu_button_advanced_search" />
+                android:src="@drawable/advanced_search" />
 
-            <Button
+            <ImageButton
                 android:id="@+id/library_hours_button"
-                style="@style/MenuListBlueButton"
-                android:layout_width="150dip"
+                style="@style/MenuListButton"
+                android:layout_width="wrap_content"
                 android:layout_height="wrap_content"
-                android:drawableTop="@drawable/settings_small"
-                android:text="@string/menu_button_library_hours" />
+                android:src="@drawable/library_hours" />
         </LinearLayout>
 
         <LinearLayout
             android:layout_height="wrap_content"
             android:gravity="center" >
 
-            <Button
+            <ImageButton
                 android:id="@+id/preference_button"
-                style="@style/MenuListPurpleButton"
-                android:layout_width="150dip"
+                style="@style/MenuListButton"
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:src="@drawable/preferences"
+                />
+            
+                <ImageButton
+                android:id="@+id/barcode_scan_button"
+                style="@style/MenuListButton"
+                android:layout_width="wrap_content"
                 android:layout_height="wrap_content"
-                android:drawableTop="@drawable/settings_small"
-                android:text="@string/menu_button_application_preferences" />
+                android:src="@drawable/barcode_scan"/>
+            
         </LinearLayout>
     </LinearLayout>
 
index 0efa592..990fad7 100644 (file)
@@ -6,35 +6,40 @@
     android:layout_height="wrap_content"
     >
 
-<RelativeLayout
+ <RelativeLayout
         android:id="@+id/header"
         android:layout_width="fill_parent"
         android:layout_height="wrap_content"
-        android:orientation="horizontal"
         android:background="@drawable/one_header_rounded_corner"
+        android:orientation="horizontal"
         android:paddingTop="3dip"
-        android:paddingBottom="3dip"
-        >
-        
-                <ImageButton 
+        android:paddingBottom="2dip"
+         >
+
+        <Button
             android:id="@+id/library_logo"
+            style="@style/LibraryLogoText"
             android:layout_width="wrap_content"
             android:layout_height="wrap_content"
-            style="@style/LibraryLogoText"
             android:layout_alignParentLeft="true"
-            android:src="@drawable/evergreen_launcher_icon_48"
             android:layout_marginLeft="5dip"
+            android:drawableLeft="@drawable/evergreen_launcher_icon_48"
+            android:text="@string/library_text_logo" 
+            android:textColor="@color/white"
+            android:textSize="16dp"
+            android:typeface="monospace"
+            android:textStyle="bold"
+            android:paddingLeft="5dip"
             />
-
+        
         <Button
             android:id="@+id/my_account_button"
             android:layout_width="wrap_content"
             android:layout_height="wrap_content"
-            android:text="@string/my_account_button_text"
             android:layout_alignParentRight="true"
-            android:padding="10dip"
             android:layout_marginTop="5dip"
-            />
+            android:padding="10dip"
+            android:text="@string/my_account_button_text" />
     </RelativeLayout>
     
         <TextView 
index f549a0b..ef9737b 100644 (file)
@@ -65,6 +65,9 @@
     
     <color name="button_stroke">#aaa</color>
     
+    
+    <color name="background">#333</color>
+    
     <!-- Search Details -->
     <color name="dark">#000</color>
 </resources>
index ae7544e..61d608f 100644 (file)
     
     <!--  Menu List Buttons -->
    <style name="MenuListButton">
-               <item name="android:background">@drawable/menu_button</item>
+               <item name="android:background">@android:color/transparent</item>
                <item name="android:layout_margin">5dip</item>
    </style>
     
index 4519399..b1a53e6 100644 (file)
@@ -63,7 +63,7 @@ private String TAG = "BookBags";
        
        private Button delete_bookbag_button;
        
-       private ImageButton homeButton;
+       private Button homeButton;
        
        private Button myAccountButton;
        
@@ -77,7 +77,7 @@ private String TAG = "BookBags";
                
                setContentView(R.layout.bookbagitem_list);
                 //header portion actions
-        homeButton = (ImageButton) findViewById(R.id.library_logo);
+        homeButton = (Button) findViewById(R.id.library_logo);
         myAccountButton = (Button) findViewById(R.id.my_account_button);
         headerTitle = (TextView) findViewById(R.id.header_title);
         headerTitle.setText(R.string.bookbag_details_title);
index ac3bb80..f47e0b2 100644 (file)
@@ -55,7 +55,7 @@ public class BookbagsListView extends Activity{
        
        private Runnable getBookbagsRunnable;
        
-       private ImageButton homeButton;
+       private Button homeButton;
        
        private Button myAccountButton;
        
@@ -69,7 +69,7 @@ public class BookbagsListView extends Activity{
                setContentView(R.layout.bookbag_list);
                
                 //header portion actions
-        homeButton = (ImageButton) findViewById(R.id.library_logo);
+        homeButton = (Button) findViewById(R.id.library_logo);
         myAccountButton = (Button) findViewById(R.id.my_account_button);
         headerTitle = (TextView) findViewById(R.id.header_title);
         headerTitle.setText(R.string.bookbag_items_title);
index 0877dce..c0319d0 100644 (file)
@@ -49,7 +49,7 @@ public class ItemsCheckOutListView extends Activity{
        
        private ProgressDialog progressDialog;
        
-       private ImageButton homeButton;
+       private Button homeButton;
        
        private Button myAccountButton;
        
@@ -64,7 +64,7 @@ public class ItemsCheckOutListView extends Activity{
                setTitle("Checkout items");
                
                 //header portion actions
-        homeButton = (ImageButton) findViewById(R.id.library_logo);
+        homeButton = (Button) findViewById(R.id.library_logo);
         myAccountButton = (Button) findViewById(R.id.my_account_button);
         headerTitle = (TextView) findViewById(R.id.header_title);
         headerTitle.setText(R.string.checkout_items_title);
index 9313839..743733a 100644 (file)
@@ -48,7 +48,7 @@ public class FinesActivity extends Activity{
        
        private OverdueMaterialsArrayAdapter  listAdapter;
        
-       private ImageButton homeButton;
+       private Button homeButton;
        
        private Button myAccountButton;
        
@@ -62,7 +62,7 @@ public class FinesActivity extends Activity{
                setContentView(R.layout.fines);
                
                 //header portion actions
-        homeButton = (ImageButton) findViewById(R.id.library_logo);
+        homeButton = (Button) findViewById(R.id.library_logo);
         myAccountButton = (Button) findViewById(R.id.my_account_button);
         headerTitle = (TextView) findViewById(R.id.header_title);
         headerTitle.setText(R.string.fines_title);
index 4d37c18..f043482 100644 (file)
@@ -99,7 +99,7 @@ public class HoldDetails extends Activity {
 
        private GlobalConfigs globalConfigs;
 
-       private ImageButton homeButton;
+       private Button homeButton;
        
        private Button myAccountButton;
        
@@ -113,7 +113,7 @@ public class HoldDetails extends Activity {
                globalConfigs = GlobalConfigs.getGlobalConfigs(this);
 
                
-               homeButton = (ImageButton) findViewById(R.id.library_logo);
+               homeButton = (Button) findViewById(R.id.library_logo);
                myAccountButton = (Button) findViewById(R.id.my_account_button);
                headerTitle = (TextView) findViewById(R.id.header_title);
                headerTitle.setText(R.string.hold_details_title);
index 36e04da..999c652 100644 (file)
@@ -47,7 +47,7 @@ public class HoldsListView extends Activity{
        
        Runnable getHoldsRunnable= null;
        
-       private ImageButton homeButton;
+       private Button homeButton;
        
        private Button myAccountButton;
        
@@ -61,7 +61,7 @@ public class HoldsListView extends Activity{
                setContentView(R.layout.holds_list);
                
                 //header portion actions
-        homeButton = (ImageButton) findViewById(R.id.library_logo);
+        homeButton = (Button) findViewById(R.id.library_logo);
         myAccountButton = (Button) findViewById(R.id.my_account_button);
         headerTitle = (TextView) findViewById(R.id.header_title);
         headerTitle.setText(R.string.hold_items_title);
index f886cfd..edd58e1 100644 (file)
@@ -86,7 +86,7 @@ public class PlaceHold extends Activity{
        
        private int selectedOrgPos = 0;
        
-       private ImageButton homeButton;
+       private Button homeButton;
        
        private Button myAccountButton;
        
@@ -104,7 +104,7 @@ public class PlaceHold extends Activity{
                globalConfigs = GlobalConfigs.getGlobalConfigs(this);
                RecordInfo record = (RecordInfo) getIntent().getSerializableExtra("recordInfo");
                
-               homeButton = (ImageButton) findViewById(R.id.library_logo);
+               homeButton = (Button) findViewById(R.id.library_logo);
                myAccountButton = (Button) findViewById(R.id.my_account_button);
                headerTitle = (TextView) findViewById(R.id.header_title);
                headerTitle.setText(R.string.hold_place_title);
index 6fdb4f1..d76d2e9 100644 (file)
@@ -26,7 +26,7 @@ public class SampleUnderlinesNoFade extends BaseSampleActivity {
        
        private Button myAccountButton;
        
-       private ImageButton homeButton;
+       private Button homeButton;
        
        private TextView headerTitle;
        
@@ -42,7 +42,7 @@ public class SampleUnderlinesNoFade extends BaseSampleActivity {
         
         
         //header portion actions
-        homeButton = (ImageButton) findViewById(R.id.library_logo);
+        homeButton = (Button) findViewById(R.id.library_logo);
         myAccountButton = (Button) findViewById(R.id.my_account_button);
         headerTitle = (TextView) findViewById(R.id.header_title);
         headerTitle.setText(R.string.search_details_title);
index 3804917..7eb318c 100644 (file)
@@ -95,13 +95,15 @@ public class SearchCatalogListView extends Activity{
        
        private View searchOptionsMenu = null;
        
-       private Button advancedSearchButton = null;
+       private ImageButton advancedSearchButton = null;
        
-       private Button libraryHoursButton = null;
+       private ImageButton libraryHoursButton = null;
        
-       private Button preferenceButton = null;
+       private ImageButton preferenceButton = null;
        
-       private ImageButton homeButton = null;
+       private ImageButton barcodeScanButton = null;
+       
+       private Button homeButton = null;
        
        private Button myAccountButton = null;
        
@@ -113,7 +115,7 @@ public class SearchCatalogListView extends Activity{
         setContentView(R.layout.search_result_list);
         setTitle("Browse catalog");
         
-        myAccountButton = (Button) findViewById(R.id.my_acount_button);
+        myAccountButton = (Button) findViewById(R.id.my_account_button);
         
         myAccountButton.setOnClickListener(new OnClickListener() {
                        @Override
@@ -123,7 +125,7 @@ public class SearchCatalogListView extends Activity{
                        }
                });
 
-        homeButton = (ImageButton) findViewById(R.id.library_logo);
+        homeButton = (Button) findViewById(R.id.library_logo);
         
         homeButton.setOnClickListener(new OnClickListener() {
                        @Override
@@ -134,7 +136,7 @@ public class SearchCatalogListView extends Activity{
                });
         //end header portion actions
 
-        advancedSearchButton = (Button) findViewById(R.id.menu_advanced_search_button);
+        advancedSearchButton = (ImageButton) findViewById(R.id.menu_advanced_search_button);
         
         advancedSearchButton.setOnClickListener(new OnClickListener() {
                        @Override
@@ -148,7 +150,7 @@ public class SearchCatalogListView extends Activity{
         AccountAccess ac = AccountAccess.getAccountAccess();
         bookBags = ac.bookBags;
         
-        libraryHoursButton = (Button) findViewById(R.id.library_hours_button);
+        libraryHoursButton = (ImageButton) findViewById(R.id.library_hours_button);
         libraryHoursButton.setOnClickListener(new OnClickListener() {
                        @Override
                        public void onClick(View v) {
@@ -156,7 +158,7 @@ public class SearchCatalogListView extends Activity{
                        }
                });
         
-        preferenceButton = (Button) findViewById(R.id.preference_button);
+        preferenceButton = (ImageButton) findViewById(R.id.preference_button);
         preferenceButton.setOnClickListener(new OnClickListener() {
                        @Override
                        public void onClick(View v) {
@@ -165,6 +167,8 @@ public class SearchCatalogListView extends Activity{
                        }
                });
         
+        barcodeScanButton = (ImageButton) findViewById(R.id.barcode_scan_button);
+        
         //singleton initialize necessary IDL and Org data
         globalConfigs = GlobalConfigs.getGlobalConfigs(this);