Haitao Zhang | 32232f5 | 2017-03-12 01:27:15 -0800 | [diff] [blame^] | 1 | <?xml version="1.0" encoding="utf-8"?> |
| 2 | <LinearLayout |
| 3 | android:layout_height="wrap_content" |
| 4 | android:layout_width="match_parent" |
| 5 | android:orientation="vertical" |
| 6 | android:layout_margin="20dp" |
| 7 | xmlns:android="http://schemas.android.com/apk/res/android" |
| 8 | xmlns:tools="http://schemas.android.com/tools"> |
| 9 | <ScrollView |
| 10 | android:layout_height="wrap_content" |
| 11 | android:layout_width="match_parent"> |
| 12 | <LinearLayout |
| 13 | android:layout_width="match_parent" |
| 14 | android:layout_height="wrap_content" |
| 15 | android:orientation="vertical" |
| 16 | tools:context="net.named_data.nfd.WiFiDirectFragment"> |
| 17 | |
| 18 | <!-- Row with title and on/off switch --> |
| 19 | <RelativeLayout |
| 20 | android:layout_width="wrap_content" |
| 21 | android:layout_height="wrap_content" |
| 22 | android:layout_marginBottom="10dp"> |
| 23 | <TextView |
| 24 | android:text="@string/fragment_wifidirect_title" |
| 25 | android:layout_width="wrap_content" |
| 26 | android:layout_height="wrap_content" /> |
| 27 | |
| 28 | <Switch |
| 29 | android:layout_width="wrap_content" |
| 30 | android:layout_height="wrap_content" |
| 31 | android:id="@+id/wd_switch" |
| 32 | android:layout_alignParentRight="true" /> |
| 33 | </RelativeLayout> |
| 34 | |
| 35 | <LinearLayout |
| 36 | android:layout_width="match_parent" |
| 37 | android:layout_height="wrap_content" |
| 38 | android:orientation="horizontal" |
| 39 | android:weightSum="1"> |
| 40 | |
| 41 | <TextView |
| 42 | android:layout_width="wrap_content" |
| 43 | android:layout_height="wrap_content" |
| 44 | android:text="@string/fragment_wifidirect_label_me" |
| 45 | android:layout_weight="0.10" /> |
| 46 | |
| 47 | <TextView |
| 48 | android:layout_width="wrap_content" |
| 49 | android:layout_height="wrap_content" |
| 50 | android:id="@+id/wd_this_device_name_textview" /> |
| 51 | </LinearLayout> |
| 52 | |
| 53 | <View |
| 54 | android:layout_width="fill_parent" |
| 55 | android:layout_height="1dp" |
| 56 | android:gravity="center_vertical" |
| 57 | android:background="@color/android_color_gray" /> |
| 58 | |
| 59 | <!-- Row for Group connection status --> |
| 60 | <LinearLayout |
| 61 | android:layout_width="match_parent" |
| 62 | android:layout_height="wrap_content" |
| 63 | android:orientation="horizontal" |
| 64 | android:weightSum="1"> |
| 65 | |
| 66 | <TextView |
| 67 | android:layout_width="wrap_content" |
| 68 | android:layout_height="wrap_content" |
| 69 | android:text="@string/fragment_wifidirect_group_conn_status" |
| 70 | android:layout_weight="0.10" /> |
| 71 | |
| 72 | <TextView |
| 73 | android:layout_width="wrap_content" |
| 74 | android:layout_height="wrap_content" |
| 75 | android:id="@+id/wd_group_conn_status_textview" /> |
| 76 | </LinearLayout> |
| 77 | |
| 78 | <!-- Row for IP address display --> |
| 79 | <LinearLayout |
| 80 | android:layout_width="match_parent" |
| 81 | android:layout_height="wrap_content" |
| 82 | android:orientation="horizontal" |
| 83 | android:weightSum="1"> |
| 84 | <TextView |
| 85 | android:layout_width="wrap_content" |
| 86 | android:layout_height="wrap_content" |
| 87 | android:text="@string/fragment_wifidirect_curr_ip" |
| 88 | android:layout_weight="0.10"/> |
| 89 | |
| 90 | <TextView |
| 91 | android:layout_width="wrap_content" |
| 92 | android:layout_height="wrap_content" |
| 93 | android:id="@+id/wd_ip_address_textview" /> |
| 94 | </LinearLayout> |
| 95 | |
| 96 | <!-- Row for group owner indicator --> |
| 97 | <LinearLayout |
| 98 | android:layout_width="match_parent" |
| 99 | android:layout_height="wrap_content" |
| 100 | android:orientation="horizontal" |
| 101 | android:weightSum="1"> |
| 102 | <TextView |
| 103 | android:layout_width="wrap_content" |
| 104 | android:layout_height="wrap_content" |
| 105 | android:text="@string/fragment_wifidirect_is_group_own" |
| 106 | android:layout_weight="0.10"/> |
| 107 | |
| 108 | <TextView |
| 109 | android:layout_width="wrap_content" |
| 110 | android:layout_height="wrap_content" |
| 111 | android:id="@+id/wd_group_owner_textview" /> |
| 112 | </LinearLayout> |
| 113 | </LinearLayout> |
| 114 | </ScrollView> |
| 115 | |
| 116 | <!-- Column of currently connected peers --> |
| 117 | <TextView |
| 118 | android:layout_width="wrap_content" |
| 119 | android:layout_height="wrap_content" |
| 120 | android:text="@string/fragment_wifidirect_connected_peers" |
| 121 | android:layout_marginTop="10dp"/> |
| 122 | <View |
| 123 | android:layout_width="fill_parent" |
| 124 | android:layout_height="1dp" |
| 125 | android:gravity="center_vertical" |
| 126 | android:background="@color/android_color_gray" /> |
| 127 | <ListView |
| 128 | android:layout_width="match_parent" |
| 129 | android:layout_height="wrap_content" |
| 130 | android:id="@+id/wd_connected_peers_listview"/> |
| 131 | |
| 132 | <!-- Column of discovered peers --> |
| 133 | <TextView |
| 134 | android:layout_width="wrap_content" |
| 135 | android:layout_height="wrap_content" |
| 136 | android:text="@string/fragment_wifidirect_discovered_peers" |
| 137 | android:layout_marginTop="10dp"/> |
| 138 | <View |
| 139 | android:layout_width="fill_parent" |
| 140 | android:layout_height="1dp" |
| 141 | android:gravity="center_vertical" |
| 142 | android:background="@color/android_color_gray" /> |
| 143 | <ListView |
| 144 | android:layout_width="match_parent" |
| 145 | android:layout_height="wrap_content" |
| 146 | android:id="@+id/wd_discovered_peers_listview"/> |
| 147 | |
| 148 | </LinearLayout> |