修訂 | f037273000e25360e295c4792542c6930c4f023e (tree) |
---|---|
時間 | 2010-04-16 21:15:24 |
作者 | Swan Wang <swandle@gmai...> |
Commiter | Chih-Wei Huang |
make music player ok and make preview size 352*288
@@ -10,6 +10,10 @@ | ||
10 | 10 | <uses-permission android:name="android.permission.WAKE_LOCK" /> |
11 | 11 | <uses-permission android:name="android.permission.SET_WALLPAPER" /> |
12 | 12 | <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" /> |
13 | + <uses-permission android:name="android.permission.RECORD_AUDIO" /> | |
14 | + <!-- Needed by the ZoomRingController to set the bit saying we've already shown the | |
15 | + tutorial toast. --> | |
16 | + <uses-permission android:name="android.permission.WRITE_SETTINGS"/> | |
13 | 17 | <uses-permission android:name="android.permission.READ_SMS" /> |
14 | 18 | |
15 | 19 | <application android:icon="@drawable/ic_launcher_camera" |
@@ -50,6 +54,11 @@ | ||
50 | 54 | android:clearTaskOnLaunch="true" |
51 | 55 | android:taskAffinity="android.task.camcorder"> |
52 | 56 | <intent-filter> |
57 | + <action android:name="android.intent.action.MAIN" /> | |
58 | + <category android:name="android.intent.category.DEFAULT" /> | |
59 | + <category android:name="android.intent.category.LAUNCHER" /> | |
60 | + </intent-filter> | |
61 | + <intent-filter> | |
53 | 62 | <action android:name="android.media.action.VIDEO_CAMERA" /> |
54 | 63 | <category android:name="android.intent.category.DEFAULT" /> |
55 | 64 | </intent-filter> |
@@ -63,15 +72,65 @@ | ||
63 | 72 | android:icon="@drawable/ic_launcher_gallery" |
64 | 73 | android:clearTaskOnLaunch="true" |
65 | 74 | android:taskAffinity="android.task.pictures"> |
75 | + <intent-filter> | |
76 | + <action android:name="android.intent.action.MAIN" /> | |
77 | + <category android:name="android.intent.category.DEFAULT" /> | |
78 | + <category android:name="android.intent.category.LAUNCHER" /> | |
79 | + </intent-filter> | |
66 | 80 | </activity> |
67 | 81 | <activity android:name="ImageGallery" android:label="@string/gallery_label" |
68 | 82 | android:configChanges="orientation|keyboardHidden" |
69 | 83 | android:icon="@drawable/ic_launcher_gallery"> |
84 | + <intent-filter> | |
85 | + <action android:name="android.intent.action.MAIN" /> | |
86 | + <category android:name="android.intent.category.DEFAULT" /> | |
87 | + </intent-filter> | |
88 | + <intent-filter> | |
89 | + <action android:name="android.intent.action.VIEW" /> | |
90 | + <category android:name="android.intent.category.DEFAULT" /> | |
91 | + <data android:mimeType="vnd.android.cursor.dir/image" /> | |
92 | + </intent-filter> | |
93 | + <intent-filter> | |
94 | + <action android:name="android.intent.action.VIEW" /> | |
95 | + <category android:name="android.intent.category.DEFAULT" /> | |
96 | + <data android:mimeType="vnd.android.cursor.dir/video" /> | |
97 | + </intent-filter> | |
98 | + <intent-filter> | |
99 | + <action android:name="android.intent.action.GET_CONTENT" /> | |
100 | + <category android:name="android.intent.category.OPENABLE" /> | |
101 | + <data android:mimeType="vnd.android.cursor.dir/image" /> | |
102 | + </intent-filter> | |
103 | + <intent-filter> | |
104 | + <action android:name="android.intent.action.GET_CONTENT" /> | |
105 | + <category android:name="android.intent.category.OPENABLE" /> | |
106 | + <category android:name="android.intent.category.DEFAULT" /> | |
107 | + <data android:mimeType="image/*" /> | |
108 | + <data android:mimeType="video/*" /> | |
109 | + </intent-filter> | |
110 | + <intent-filter> | |
111 | + <action android:name="android.intent.action.PICK" /> | |
112 | + <category android:name="android.intent.category.DEFAULT" /> | |
113 | + <data android:mimeType="image/*" /> | |
114 | + <data android:mimeType="video/*" /> | |
115 | + </intent-filter> | |
116 | + <intent-filter> | |
117 | + <action android:name="android.intent.action.PICK" /> | |
118 | + <category android:name="android.intent.category.DEFAULT" /> | |
119 | + <data android:mimeType="vnd.android.cursor.dir/image" /> | |
120 | + </intent-filter> | |
70 | 121 | </activity> |
122 | + | |
71 | 123 | <activity android:name="CropImage" |
72 | 124 | android:process=":CropImage" |
73 | 125 | android:configChanges="orientation|keyboardHidden" |
74 | 126 | android:label="@string/crop_label"> |
127 | + <intent-filter android:label="@string/crop_label"> | |
128 | + <action android:name="com.android.camera.action.CROP" /> | |
129 | + <data android:mimeType="image/*" /> | |
130 | + <category android:name="android.intent.category.DEFAULT" /> | |
131 | + <category android:name="android.intent.category.ALTERNATIVE" /> | |
132 | + <category android:name="android.intent.category.SELECTED_ALTERNATIVE" /> | |
133 | + </intent-filter> | |
75 | 134 | </activity> |
76 | 135 | <activity android:name="ReviewImage" |
77 | 136 | android:label="@string/view_label" |
@@ -84,33 +143,90 @@ | ||
84 | 143 | android:label="@string/view_label" |
85 | 144 | android:screenOrientation="behind" |
86 | 145 | android:configChanges="orientation|keyboardHidden"> |
146 | + <intent-filter> | |
147 | + <action android:name="android.intent.action.VIEW" /> | |
148 | + <category android:name="android.intent.category.DEFAULT" /> | |
149 | + <data android:mimeType="image/*" /> | |
150 | + </intent-filter> | |
87 | 151 | </activity> |
88 | 152 | <activity android:name="MovieView" |
89 | 153 | android:label="@string/movieviewlabel" |
90 | 154 | android:screenOrientation="landscape" |
91 | 155 | android:configChanges="orientation|keyboardHidden" |
92 | 156 | android:theme="@android:style/Theme.Black.NoTitleBar.Fullscreen"> |
157 | + <intent-filter> | |
158 | + <action android:name="android.intent.action.VIEW" /> | |
159 | + <category android:name="android.intent.category.DEFAULT" /> | |
160 | + <category android:name="android.intent.category.BROWSABLE" /> | |
161 | + <data android:scheme="rtsp" /> | |
162 | + </intent-filter> | |
163 | + <intent-filter> | |
164 | + <action android:name="android.intent.action.VIEW" /> | |
165 | + <category android:name="android.intent.category.DEFAULT" /> | |
166 | + <data android:mimeType="video/*" /> | |
167 | + <data android:mimeType="application/sdp" /> | |
168 | + </intent-filter> | |
169 | + <intent-filter> | |
170 | + <action android:name="android.intent.action.VIEW" /> | |
171 | + <category android:name="android.intent.category.DEFAULT" /> | |
172 | + <category android:name="android.intent.category.BROWSABLE" /> | |
173 | + <data android:scheme="http" /> | |
174 | + <data android:mimeType="video/mp4" /> | |
175 | + <data android:mimeType="video/3gp" /> | |
176 | + <data android:mimeType="video/3gpp" /> | |
177 | + <data android:mimeType="video/3gpp2" /> | |
178 | + </intent-filter> | |
93 | 179 | </activity> |
94 | 180 | <activity android:name=".DeleteImage" |
95 | 181 | android:label="@string/delete_images_message" |
96 | 182 | android:theme="@style/Theme.DeleteImageDialog"> |
97 | 183 | </activity> |
98 | 184 | |
185 | + <activity android:name="CameraSettings" android:label="@string/preferences_label"> | |
186 | + <intent-filter> | |
187 | + <action android:name="android.intent.action.MAIN" /> | |
188 | + <category android:name="android.intent.category.DEVELOPMENT_PREFERENCE" /> | |
189 | + </intent-filter> | |
190 | + </activity> | |
191 | + | |
99 | 192 | <activity android:name="GallerySettings" android:label="@string/preferences_label"> |
193 | + <intent-filter> | |
194 | + <action android:name="android.intent.action.MAIN" /> | |
195 | + <category android:name="android.intent.category.DEVELOPMENT_PREFERENCE" /> | |
196 | + </intent-filter> | |
100 | 197 | </activity> |
101 | 198 | |
102 | 199 | <activity android:name=".Wallpaper" |
103 | 200 | android:label="@string/camera_setas_wallpaper" |
104 | 201 | android:icon="@drawable/ic_launcher_gallery"> |
202 | + <intent-filter> | |
203 | + <action android:name="android.intent.action.ATTACH_DATA" /> | |
204 | + <data android:mimeType="image/*" /> | |
205 | + <category android:name="android.intent.category.DEFAULT" /> | |
206 | + </intent-filter> | |
105 | 207 | </activity> |
106 | 208 | |
107 | 209 | <activity android:name=".PickWallpaper" |
108 | 210 | android:label="@string/camera_pick_wallpaper" |
109 | 211 | android:icon="@drawable/ic_launcher_gallery"> |
212 | + <intent-filter> | |
213 | + <action android:name="android.intent.action.SET_WALLPAPER" /> | |
214 | + <category android:name="android.intent.category.DEFAULT" /> | |
215 | + </intent-filter> | |
110 | 216 | </activity> |
111 | 217 | |
218 | + <receiver android:name="PhotoAppWidgetProvider" android:label="@string/gadget_title"> | |
219 | + <intent-filter> | |
220 | + <action android:name="android.appwidget.action.APPWIDGET_UPDATE" /> | |
221 | + </intent-filter> | |
222 | + <meta-data android:name="android.appwidget.provider" android:resource="@xml/appwidget_info" /> | |
223 | + </receiver> | |
224 | + | |
112 | 225 | <!-- We configure a widget by asking to pick a photo, then crop it, and store the config internally --> |
113 | 226 | <activity android:name="PhotoAppWidgetConfigure"> |
227 | + <intent-filter> | |
228 | + <action android:name="android.appwidget.action.APPWIDGET_CONFIGURE" /> | |
229 | + </intent-filter> | |
114 | 230 | </activity> |
115 | 231 | |
116 | 232 | <!-- We also allow direct binding where the caller provides a bitmap and |
@@ -30,16 +30,17 @@ | ||
30 | 30 | android:layout_width="wrap_content" |
31 | 31 | android:layout_height="wrap_content"/> |
32 | 32 | <FrameLayout android:id="@+id/frame" |
33 | - android:layout_width="fill_parent" | |
34 | - android:layout_height="fill_parent" | |
33 | + android:layout_width="wrap_content" | |
34 | + android:layout_height="wrap_content" | |
35 | + android:layout_gravity="center" | |
35 | 36 | android:background="@drawable/border_view_finder"> |
36 | 37 | <SurfaceView android:id="@+id/camera_preview" |
37 | - android:layout_width="fill_parent" | |
38 | - android:layout_height="fill_parent"/> | |
38 | + android:layout_width="352dp" | |
39 | + android:layout_height="288dp"/> | |
39 | 40 | <com.android.camera.FocusRectangle |
40 | 41 | android:id="@+id/focus_rectangle" |
41 | - android:layout_width="fill_parent" | |
42 | - android:layout_height="fill_parent"/> | |
42 | + android:layout_width="352dp" | |
43 | + android:layout_height="288dp"/> | |
43 | 44 | <LinearLayout android:id="@+id/indicator_bar" |
44 | 45 | android:orientation="vertical" |
45 | 46 | android:visibility="visible" |
@@ -30,12 +30,13 @@ | ||
30 | 30 | android:layout_width="wrap_content" |
31 | 31 | android:layout_height="wrap_content"/> |
32 | 32 | <FrameLayout android:id="@+id/frame" |
33 | - android:layout_width="fill_parent" | |
34 | - android:layout_height="fill_parent" | |
33 | + android:layout_width="wrap_content" | |
34 | + android:layout_height="wrap_content" | |
35 | + android:layout_gravity="center" | |
35 | 36 | android:background="@drawable/border_view_finder"> |
36 | 37 | <SurfaceView android:id="@+id/camera_preview" |
37 | - android:layout_width="fill_parent" | |
38 | - android:layout_height="fill_parent"/> | |
38 | + android:layout_width="352dp" | |
39 | + android:layout_height="288dp"/> | |
39 | 40 | <ImageView android:id="@+id/video_frame" |
40 | 41 | android:layout_width="fill_parent" |
41 | 42 | android:layout_height="fill_parent" |