Skip to content

Commit 90f737a

Browse files
committed
android-navigation-drawer
android-navigation-drawer
1 parent ec16f3d commit 90f737a

13 files changed

Lines changed: 198 additions & 0 deletions

File tree

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
3+
package="com.hmkcode.android"
4+
android:versionCode="1"
5+
android:versionName="1.0" >
6+
7+
<uses-sdk
8+
android:minSdkVersion="11"
9+
android:targetSdkVersion="17" />
10+
11+
<application
12+
android:allowBackup="true"
13+
android:icon="@drawable/ic_launcher"
14+
android:label="@string/app_name"
15+
android:theme="@style/AppTheme" >
16+
<activity
17+
android:name="com.hmkcode.android.MainActivity"
18+
android:label="@string/app_name" >
19+
<intent-filter>
20+
<action android:name="android.intent.action.MAIN" />
21+
22+
<category android:name="android.intent.category.LAUNCHER" />
23+
</intent-filter>
24+
</activity>
25+
</application>
26+
27+
</manifest>
50.2 KB
Loading
171 Bytes
Loading
1.72 KB
Loading
2.78 KB
Loading
7.48 KB
Loading
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
<android.support.v4.widget.DrawerLayout
2+
xmlns:android="http://schemas.android.com/apk/res/android"
3+
android:id="@+id/drawer_layout"
4+
android:layout_width="match_parent"
5+
android:layout_height="match_parent">
6+
7+
<!-- The main content view -->
8+
<FrameLayout
9+
android:id="@+id/content_frame"
10+
android:layout_width="match_parent"
11+
android:layout_height="match_parent" />
12+
13+
14+
<!-- The navigation drawer -->
15+
<ListView android:id="@+id/left_drawer"
16+
android:layout_width="240dp"
17+
android:layout_height="match_parent"
18+
android:layout_gravity="start"
19+
android:choiceMode="singleChoice"
20+
android:divider="#666"
21+
android:dividerHeight="1dp"
22+
android:background="#333"
23+
android:paddingLeft="15sp"
24+
android:paddingRight="15sp"
25+
/>
26+
27+
</android.support.v4.widget.DrawerLayout>
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
3+
<TextView xmlns:android="http://schemas.android.com/apk/res/android"
4+
android:id="@android:id/text1"
5+
android:layout_width="match_parent"
6+
android:layout_height="wrap_content"
7+
android:textColor="#fff"
8+
android:textSize="20sp"
9+
android:gravity="center_vertical"
10+
android:paddingStart="14.5sp"
11+
android:paddingEnd="14.5sp"
12+
android:minHeight="35sp"
13+
/>
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
<menu xmlns:android="http://schemas.android.com/apk/res/android" >
2+
3+
<item
4+
android:id="@+id/action_settings"
5+
android:orderInCategory="100"
6+
android:showAsAction="always"
7+
android:icon="@drawable/ic_action_search"
8+
android:title="@string/action_settings"/>
9+
10+
</menu>
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
<resources>
2+
3+
<!-- Default screen margins, per the Android Design guidelines. -->
4+
<dimen name="activity_horizontal_margin">16dp</dimen>
5+
<dimen name="activity_vertical_margin">16dp</dimen>
6+
7+
</resources>

0 commit comments

Comments
 (0)