Skip to content

Commit

Permalink
Merge branch 'master' of git://github.com/AliceCengal/guide-android
Browse files Browse the repository at this point in the history
  • Loading branch information
nking-1 committed Dec 27, 2012
2 parents 6a0dd21 + a8debe6 commit 861627c
Show file tree
Hide file tree
Showing 8 changed files with 294 additions and 205 deletions.
66 changes: 66 additions & 0 deletions GuideAndroid/res/layout-land/fragment_place_detailer.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="horizontal" >

<LinearLayout
android:layout_width="0dip"
android:layout_height="match_parent"
android:layout_weight="50"
android:orientation="vertical" >

<TextView
android:id="@+id/PlaceName"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="16dp"
android:gravity="center_vertical"
android:text="Place name"
android:textSize="20sp"
android:textStyle="bold" />

<ImageView
android:id="@+id/PlaceImage"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="5dp"
android:gravity="top|left" />
</LinearLayout>

<ScrollView
android:layout_width="0dip"
android:layout_height="match_parent"
android:layout_weight="50" >

<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:paddingLeft="8dp"
android:paddingRight="8dp" >

<TextView
android:id="@+id/PlaceDescription"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="8dp"
android:text="Place description text" />

<View
android:layout_width="match_parent"
android:layout_height="2dp"
android:layout_marginBottom="1dp"
android:layout_marginTop="1dp"
android:background="@android:color/darker_gray" />

<TextView
android:id="@+id/PlaceHours"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="8dp"
android:text="Hours of operation: " />
</LinearLayout>
</ScrollView>

</LinearLayout>
54 changes: 4 additions & 50 deletions GuideAndroid/res/layout/activity_place_detail.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,56 +4,10 @@
android:layout_height="match_parent"
android:orientation="vertical" >

<ImageView
android:id="@+id/PlaceImage"
<fragment
android:name="edu.vanderbilt.vm.guide.ui.PlaceDetailer$PlaceDetailerFragment"
android:tag="detailer_fragment"
android:layout_width="match_parent"
android:layout_height="0dip"
android:layout_weight="40"
android:gravity="top|left"
android:layout_margin="5dp" />
android:layout_height="match_parent" />

<TextView
android:id="@+id/PlaceName"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center_vertical"
android:textSize="20sp"
android:textStyle="bold"
android:text="Place name"
android:layout_margin="16dp" />

<ScrollView
android:layout_width="match_parent"
android:layout_height="0dip"
android:layout_weight="50" >

<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:paddingLeft="8dp"
android:paddingRight="8dp" >

<TextView
android:id="@+id/PlaceDescription"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="Place description text"
android:layout_margin="8dp" />

<View
android:layout_width="match_parent"
android:background="@android:color/darker_gray"
android:layout_height="2dp"
android:layout_marginTop="1dp"
android:layout_marginBottom="1dp"/>

<TextView
android:id="@+id/PlaceHours"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="Hours of operation: "
android:layout_margin="8dp" />
</LinearLayout>
</ScrollView>
</LinearLayout>
59 changes: 59 additions & 0 deletions GuideAndroid/res/layout/fragment_place_detailer.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical" >

<ImageView
android:id="@+id/PlaceImage"
android:layout_width="match_parent"
android:layout_height="0dip"
android:layout_weight="40"
android:gravity="top|left"
android:layout_margin="5dp" />

<TextView
android:id="@+id/PlaceName"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center_vertical"
android:textSize="20sp"
android:textStyle="bold"
android:text="Place name"
android:layout_margin="16dp" />

<ScrollView
android:layout_width="match_parent"
android:layout_height="0dip"
android:layout_weight="50" >

<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:paddingLeft="8dp"
android:paddingRight="8dp" >

<TextView
android:id="@+id/PlaceDescription"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="Place description text"
android:layout_margin="8dp" />

<View
android:layout_width="match_parent"
android:background="@android:color/darker_gray"
android:layout_height="2dp"
android:layout_marginTop="1dp"
android:layout_marginBottom="1dp"/>

<TextView
android:id="@+id/PlaceHours"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="Hours of operation: "
android:layout_margin="8dp" />
</LinearLayout>
</ScrollView>
</LinearLayout>
Original file line number Diff line number Diff line change
Expand Up @@ -139,4 +139,8 @@ public int compare(Place arg0, Place arg1) {

}

public void addToTop(Place plc) {
mPlaces.add(0, plc);
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ public void onActivityCreated(Bundle savedInstanceState) {
super.onActivityCreated(savedInstanceState);
setListAdapter(new AgendaAdapter(getActivity(),
GlobalState.getUserAgenda()));
setHasOptionsMenu(true);
}

public boolean onOptionsItemSelected(MenuItem item) {
Expand Down
Loading

0 comments on commit 861627c

Please sign in to comment.