From 5ae9f47a834282a745852f7ad22232878e9d378e Mon Sep 17 00:00:00 2001 From: Romain Guy Date: Fri, 8 Jan 2010 15:07:04 -0800 Subject: [PATCH] Deprecate fill_parent and introduce match_parent. Bug: #2361749. --- res/layout-finger/album_appwidget.xml | 18 ++++++++-------- res/layout-finger/audio_player.xml | 18 ++++++++-------- res/layout-finger/audio_player_common.xml | 6 +++--- res/layout-finger/buttonbar.xml | 10 ++++----- res/layout-finger/confirm_delete.xml | 6 +++--- res/layout-finger/edit_track_list_item.xml | 6 +++--- res/layout-finger/media_picker_activity.xml | 8 ++++---- .../media_picker_activity_expanding.xml | 8 ++++---- res/layout-finger/music_library.xml | 22 ++++++++++---------- res/layout-finger/nowplaying.xml | 10 ++++----- res/layout-finger/streamstarter.xml | 2 +- res/layout-finger/track_list_item.xml | 2 +- res/layout-finger/track_list_item_child.xml | 2 +- res/layout-finger/track_list_item_group.xml | 2 +- res/layout-finger/weekpicker.xml | 4 ++-- res/layout-keysexposed/create_playlist.xml | 8 ++++---- res/layout-keyshidden/create_playlist.xml | 10 ++++----- res/layout-land-finger/audio_player.xml | 20 +++++++++--------- res/layout-land-finger/buttonbar.xml | 12 +++++------ res/layout-land-finger/media_picker_activity.xml | 8 ++++---- .../media_picker_activity_expanding.xml | 8 ++++---- res/layout-land-finger/music_library.xml | 18 ++++++++-------- res/layout-port-finger-854x480/audio_player.xml | 16 +++++++-------- res/layout/music_picker.xml | 24 +++++++++++----------- res/layout/music_picker_item.xml | 2 +- res/layout/query_activity.xml | 8 ++++---- res/layout/statusbar.xml | 6 +++--- src/com/android/music/CreatePlaylist.java | 4 +--- src/com/android/music/DeleteItems.java | 13 +----------- src/com/android/music/RenamePlaylist.java | 5 +---- src/com/android/music/WeekSelector.java | 12 +---------- 31 files changed, 136 insertions(+), 162 deletions(-) diff --git a/res/layout-finger/album_appwidget.xml b/res/layout-finger/album_appwidget.xml index dada130..b5d0908 100644 --- a/res/layout-finger/album_appwidget.xml +++ b/res/layout-finger/album_appwidget.xml @@ -15,8 +15,8 @@ --> @@ -24,7 +24,7 @@ android:id="@+id/album_appwidget" android:layout_width="0dip" android:layout_weight="3" - android:layout_height="fill_parent" + android:layout_height="match_parent" android:orientation="vertical" android:gravity="center_vertical" android:clickable="true" @@ -36,7 +36,7 @@ @@ -70,7 +70,7 @@ android:id="@+id/control_play" android:layout_width="0dip" android:layout_weight="1" - android:layout_height="fill_parent" + android:layout_height="match_parent" android:src="@drawable/ic_appwidget_music_play" android:background="@drawable/appwidget_button_center" android:scaleType="center" @@ -78,7 +78,7 @@ @@ -86,7 +86,7 @@ android:id="@+id/control_next" android:layout_width="0dip" android:layout_weight="1" - android:layout_height="fill_parent" + android:layout_height="match_parent" android:src="@drawable/ic_appwidget_music_next" android:background="@drawable/appwidget_button_right" android:scaleType="center" diff --git a/res/layout-finger/audio_player.xml b/res/layout-finger/audio_player.xml index da11163..1c7390b 100644 --- a/res/layout-finger/audio_player.xml +++ b/res/layout-finger/audio_player.xml @@ -15,12 +15,12 @@ --> diff --git a/res/layout-finger/audio_player_common.xml b/res/layout-finger/audio_player_common.xml index 8297fa3..4a7ceca 100644 --- a/res/layout-finger/audio_player_common.xml +++ b/res/layout-finger/audio_player_common.xml @@ -17,12 +17,12 @@ diff --git a/res/layout-finger/confirm_delete.xml b/res/layout-finger/confirm_delete.xml index 1fdf3fc..508fbdb 100644 --- a/res/layout-finger/confirm_delete.xml +++ b/res/layout-finger/confirm_delete.xml @@ -16,11 +16,11 @@ diff --git a/res/layout-finger/edit_track_list_item.xml b/res/layout-finger/edit_track_list_item.xml index 4b5c02f..5dfa0aa 100644 --- a/res/layout-finger/edit_track_list_item.xml +++ b/res/layout-finger/edit_track_list_item.xml @@ -17,19 +17,19 @@ */ --> diff --git a/res/layout-finger/media_picker_activity.xml b/res/layout-finger/media_picker_activity.xml index 6513dcb..af3d992 100644 --- a/res/layout-finger/media_picker_activity.xml +++ b/res/layout-finger/media_picker_activity.xml @@ -15,8 +15,8 @@ --> @@ -26,8 +26,8 @@ @@ -26,8 +26,8 @@ @@ -71,7 +71,7 @@ @@ -109,20 +109,20 @@ @@ -139,7 +139,7 @@ android:textAppearance="?android:attr/textAppearanceMedium" android:singleLine="true" android:ellipsize="end" - android:layout_width="fill_parent" + android:layout_width="match_parent" android:layout_height="wrap_content" /> diff --git a/res/layout-finger/nowplaying.xml b/res/layout-finger/nowplaying.xml index 86dde1f..cb780bf 100644 --- a/res/layout-finger/nowplaying.xml +++ b/res/layout-finger/nowplaying.xml @@ -19,7 +19,7 @@ diff --git a/res/layout-finger/streamstarter.xml b/res/layout-finger/streamstarter.xml index 025d889..1f21f7b 100644 --- a/res/layout-finger/streamstarter.xml +++ b/res/layout-finger/streamstarter.xml @@ -16,7 +16,7 @@ diff --git a/res/layout-finger/track_list_item.xml b/res/layout-finger/track_list_item.xml index aa2cd5d..9b1d703 100644 --- a/res/layout-finger/track_list_item.xml +++ b/res/layout-finger/track_list_item.xml @@ -17,7 +17,7 @@ */ --> diff --git a/res/layout-finger/track_list_item_child.xml b/res/layout-finger/track_list_item_child.xml index 5c1a07b..9398182 100644 --- a/res/layout-finger/track_list_item_child.xml +++ b/res/layout-finger/track_list_item_child.xml @@ -17,7 +17,7 @@ */ --> diff --git a/res/layout-keysexposed/create_playlist.xml b/res/layout-keysexposed/create_playlist.xml index 9a91a46..ce25d4b 100644 --- a/res/layout-keysexposed/create_playlist.xml +++ b/res/layout-keysexposed/create_playlist.xml @@ -16,11 +16,11 @@ diff --git a/res/layout-keyshidden/create_playlist.xml b/res/layout-keyshidden/create_playlist.xml index 675228b..6c8c8b6 100644 --- a/res/layout-keyshidden/create_playlist.xml +++ b/res/layout-keyshidden/create_playlist.xml @@ -16,12 +16,12 @@ @@ -49,7 +49,7 @@ diff --git a/res/layout-land-finger/audio_player.xml b/res/layout-land-finger/audio_player.xml index a9c17f1..675f430 100644 --- a/res/layout-land-finger/audio_player.xml +++ b/res/layout-land-finger/audio_player.xml @@ -15,14 +15,14 @@ --> @@ -44,7 +44,7 @@ android:orientation="vertical"> @@ -68,7 +68,7 @@ diff --git a/res/layout-land-finger/buttonbar.xml b/res/layout-land-finger/buttonbar.xml index c7f610f..f27907d 100644 --- a/res/layout-land-finger/buttonbar.xml +++ b/res/layout-land-finger/buttonbar.xml @@ -19,7 +19,7 @@ diff --git a/res/layout-land-finger/media_picker_activity.xml b/res/layout-land-finger/media_picker_activity.xml index 5277356..77a9919 100644 --- a/res/layout-land-finger/media_picker_activity.xml +++ b/res/layout-land-finger/media_picker_activity.xml @@ -15,8 +15,8 @@ --> @@ -26,8 +26,8 @@ @@ -26,8 +26,8 @@ @@ -126,7 +126,7 @@ android:textAppearance="?android:attr/textAppearanceMedium" android:singleLine="true" android:ellipsize="end" - android:layout_width="fill_parent" + android:layout_width="match_parent" android:layout_height="wrap_content" /> diff --git a/res/layout-port-finger-854x480/audio_player.xml b/res/layout-port-finger-854x480/audio_player.xml index fcb54dd..15b10ea 100644 --- a/res/layout-port-finger-854x480/audio_player.xml +++ b/res/layout-port-finger-854x480/audio_player.xml @@ -15,8 +15,8 @@ --> diff --git a/res/layout/music_picker.xml b/res/layout/music_picker.xml index f9df172..0f97fcf 100644 --- a/res/layout/music_picker.xml +++ b/res/layout/music_picker.xml @@ -17,18 +17,18 @@ + android:layout_width="match_parent" + android:layout_height="match_parent"> + android:layout_width="match_parent" + android:layout_height="match_parent"> @@ -64,7 +64,7 @@ diff --git a/res/layout/music_picker_item.xml b/res/layout/music_picker_item.xml index b6e40fe..0d0ae21 100644 --- a/res/layout/music_picker_item.xml +++ b/res/layout/music_picker_item.xml @@ -18,7 +18,7 @@ --> diff --git a/res/layout/query_activity.xml b/res/layout/query_activity.xml index 72c3513..7575364 100644 --- a/res/layout/query_activity.xml +++ b/res/layout/query_activity.xml @@ -15,16 +15,16 @@ --> diff --git a/res/layout/statusbar.xml b/res/layout/statusbar.xml index 32fdc0b..eee4762 100644 --- a/res/layout/statusbar.xml +++ b/res/layout/statusbar.xml @@ -17,8 +17,8 @@ */ --> diff --git a/src/com/android/music/CreatePlaylist.java b/src/com/android/music/CreatePlaylist.java index 9005023..bb541aa 100644 --- a/src/com/android/music/CreatePlaylist.java +++ b/src/com/android/music/CreatePlaylist.java @@ -28,8 +28,6 @@ import android.os.Bundle; import android.provider.MediaStore; import android.text.Editable; import android.text.TextWatcher; -import android.util.Log; -import android.view.KeyEvent; import android.view.View; import android.view.Window; import android.view.WindowManager; @@ -50,7 +48,7 @@ public class CreatePlaylist extends Activity requestWindowFeature(Window.FEATURE_NO_TITLE); setContentView(R.layout.create_playlist); - getWindow().setLayout(WindowManager.LayoutParams.FILL_PARENT, + getWindow().setLayout(WindowManager.LayoutParams.MATCH_PARENT, WindowManager.LayoutParams.WRAP_CONTENT); mPrompt = (TextView)findViewById(R.id.prompt); diff --git a/src/com/android/music/DeleteItems.java b/src/com/android/music/DeleteItems.java index 6cb2527..def8a42 100644 --- a/src/com/android/music/DeleteItems.java +++ b/src/com/android/music/DeleteItems.java @@ -17,24 +17,13 @@ package com.android.music; import android.app.Activity; -import android.content.ContentResolver; -import android.content.ContentValues; -import android.content.Intent; -import android.database.Cursor; import android.media.AudioManager; -import android.net.Uri; import android.os.Bundle; -import android.provider.MediaStore; -import android.text.TextWatcher; -import android.util.Log; -import android.view.KeyEvent; import android.view.View; import android.view.Window; import android.view.WindowManager; import android.widget.Button; -import android.widget.EditText; import android.widget.TextView; -import android.widget.Toast; public class DeleteItems extends Activity { @@ -49,7 +38,7 @@ public class DeleteItems extends Activity requestWindowFeature(Window.FEATURE_NO_TITLE); setContentView(R.layout.confirm_delete); - getWindow().setLayout(WindowManager.LayoutParams.FILL_PARENT, + getWindow().setLayout(WindowManager.LayoutParams.MATCH_PARENT, WindowManager.LayoutParams.WRAP_CONTENT); mPrompt = (TextView)findViewById(R.id.prompt); diff --git a/src/com/android/music/RenamePlaylist.java b/src/com/android/music/RenamePlaylist.java index f81e2af..96ceada 100644 --- a/src/com/android/music/RenamePlaylist.java +++ b/src/com/android/music/RenamePlaylist.java @@ -18,17 +18,14 @@ package com.android.music; import android.app.Activity; import android.content.ContentResolver; -import android.content.ContentUris; import android.content.ContentValues; import android.database.Cursor; import android.media.AudioManager; -import android.net.Uri; import android.os.Bundle; import android.provider.MediaStore; import android.text.Editable; import android.text.TextWatcher; import android.util.Log; -import android.view.KeyEvent; import android.view.View; import android.view.Window; import android.view.WindowManager; @@ -52,7 +49,7 @@ public class RenamePlaylist extends Activity requestWindowFeature(Window.FEATURE_NO_TITLE); setContentView(R.layout.create_playlist); - getWindow().setLayout(WindowManager.LayoutParams.FILL_PARENT, + getWindow().setLayout(WindowManager.LayoutParams.MATCH_PARENT, WindowManager.LayoutParams.WRAP_CONTENT); mPrompt = (TextView)findViewById(R.id.prompt); diff --git a/src/com/android/music/WeekSelector.java b/src/com/android/music/WeekSelector.java index 69b819f..3288c8a 100644 --- a/src/com/android/music/WeekSelector.java +++ b/src/com/android/music/WeekSelector.java @@ -17,22 +17,12 @@ package com.android.music; import android.app.Activity; -import android.content.ContentResolver; -import android.content.ContentValues; -import android.database.Cursor; import android.media.AudioManager; -import android.net.Uri; import android.os.Bundle; -import android.provider.MediaStore; -import android.text.TextWatcher; -import android.util.Log; -import android.view.KeyEvent; import android.view.View; import android.view.Window; import android.view.WindowManager; import android.widget.Button; -import android.widget.EditText; -import android.widget.TextView; public class WeekSelector extends Activity { @@ -45,7 +35,7 @@ public class WeekSelector extends Activity requestWindowFeature(Window.FEATURE_NO_TITLE); setContentView(R.layout.weekpicker); - getWindow().setLayout(WindowManager.LayoutParams.FILL_PARENT, + getWindow().setLayout(WindowManager.LayoutParams.MATCH_PARENT, WindowManager.LayoutParams.WRAP_CONTENT); mWeeks = (VerticalTextSpinner)findViewById(R.id.weeks); -- 2.11.0