Merge "Revise welcome screen video and still image"

main
Tadashi G. Takaoka 2013-05-14 12:01:46 +00:00 committed by Android (Google) Code Review
commit 8b56ad7814
15 changed files with 54 additions and 40 deletions

View File

@ -27,7 +27,9 @@
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="@integer/setup_title_weight_in_screen"
android:orientation="vertical">
android:orientation="vertical"
android:layout_marginEnd="@dimen/setup_title_end_margin"
android:layout_marginRight="@dimen/setup_title_end_margin">
<include layout="@layout/setup_steps_title" />
</LinearLayout>
<LinearLayout

View File

@ -27,7 +27,9 @@
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="@integer/setup_title_weight_in_screen"
android:orientation="vertical">
android:orientation="vertical"
android:layout_marginEnd="@dimen/setup_title_end_margin"
android:layout_marginRight="@dimen/setup_title_end_margin">
<include layout="@layout/setup_welcome_title" />
</LinearLayout>
<LinearLayout

View File

@ -25,24 +25,27 @@
android:orientation="horizontal"
android:paddingTop="@dimen/setup_welcome_video_vertical_margin"
android:paddingBottom="@dimen/setup_welcome_video_vertical_margin">
<View
android:layout_weight="@integer/setup_welcome_video_left_padding_weight_in_screen"
<LinearLayout
android:id="@+id/setup_welcome_video_frame"
android:layout_weight="@integer/setup_welcome_video_weight_in_screen"
android:layout_width="0dp"
android:layout_height="0dp" />
android:layout_height="wrap_content"
android:orientation="horizontal"
android:padding="1dp"
android:background="@color/setup_welcome_video_margin_color" >
<VideoView
android:id="@+id/setup_welcome_video"
android:background="@color/setup_background"
android:layout_weight="@integer/setup_welcome_video_weight_in_screen"
android:layout_width="0dp"
android:layout_height="wrap_content" />
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="@color/setup_background" />
<ImageView
android:id="@+id/setup_welcome_image"
android:visibility="gone"
android:layout_weight="@integer/setup_welcome_video_weight_in_screen"
android:layout_width="0dp"
android:layout_height="wrap_content" />
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:visibility="gone" />
</LinearLayout>
<View
android:layout_weight="@integer/setup_welcome_video_right_padding_weight_in_screen"
android:layout_weight="@integer/setup_welcome_video_end_padding_weight_in_screen"
android:layout_width="0dp"
android:layout_height="0dp" />
</LinearLayout>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 48 KiB

After

Width:  |  Height:  |  Size: 46 KiB

Binary file not shown.

View File

@ -33,8 +33,8 @@
<dimen name="setup_step_horizontal_line_height">2dp</dimen>
<integer name="setup_title_weight_in_screen">40</integer>
<integer name="setup_body_weight_in_screen">60</integer>
<dimen name="setup_title_end_margin">24dp</dimen>
<dimen name="setup_welcome_video_vertical_margin">24dp</dimen>
<integer name="setup_welcome_video_weight_in_screen">50</integer>
<integer name="setup_welcome_video_left_padding_weight_in_screen">25</integer>
<integer name="setup_welcome_video_right_padding_weight_in_screen">25</integer>
<integer name="setup_welcome_video_weight_in_screen">70</integer>
<integer name="setup_welcome_video_end_padding_weight_in_screen">30</integer>
</resources>

View File

@ -33,8 +33,8 @@
<dimen name="setup_step_horizontal_line_height">2dp</dimen>
<integer name="setup_title_weight_in_screen">40</integer>
<integer name="setup_body_weight_in_screen">60</integer>
<dimen name="setup_title_end_margin">24dp</dimen>
<dimen name="setup_welcome_video_vertical_margin">24dp</dimen>
<integer name="setup_welcome_video_weight_in_screen">80</integer>
<integer name="setup_welcome_video_left_padding_weight_in_screen">10</integer>
<integer name="setup_welcome_video_right_padding_weight_in_screen">10</integer>
<integer name="setup_welcome_video_weight_in_screen">70</integer>
<integer name="setup_welcome_video_end_padding_weight_in_screen">30</integer>
</resources>

View File

@ -33,8 +33,8 @@
<dimen name="setup_step_horizontal_line_height">2dp</dimen>
<integer name="setup_title_weight_in_screen">40</integer>
<integer name="setup_body_weight_in_screen">60</integer>
<dimen name="setup_title_end_margin">24dp</dimen>
<dimen name="setup_welcome_video_vertical_margin">24dp</dimen>
<integer name="setup_welcome_video_weight_in_screen">60</integer>
<integer name="setup_welcome_video_left_padding_weight_in_screen">20</integer>
<integer name="setup_welcome_video_right_padding_weight_in_screen">20</integer>
<integer name="setup_welcome_video_end_padding_weight_in_screen">40</integer>
</resources>

View File

@ -33,8 +33,8 @@
<dimen name="setup_step_horizontal_line_height">2dp</dimen>
<integer name="setup_title_weight_in_screen">40</integer>
<integer name="setup_body_weight_in_screen">60</integer>
<dimen name="setup_title_end_margin">24dp</dimen>
<dimen name="setup_welcome_video_vertical_margin">24dp</dimen>
<integer name="setup_welcome_video_weight_in_screen">80</integer>
<integer name="setup_welcome_video_left_padding_weight_in_screen">10</integer>
<integer name="setup_welcome_video_right_padding_weight_in_screen">10</integer>
<integer name="setup_welcome_video_weight_in_screen">70</integer>
<integer name="setup_welcome_video_end_padding_weight_in_screen">30</integer>
</resources>

View File

@ -33,8 +33,8 @@
<dimen name="setup_step_horizontal_line_height">2dp</dimen>
<integer name="setup_title_weight_in_screen">40</integer>
<integer name="setup_body_weight_in_screen">60</integer>
<dimen name="setup_title_end_margin">24dp</dimen>
<dimen name="setup_welcome_video_vertical_margin">24dp</dimen>
<integer name="setup_welcome_video_weight_in_screen">50</integer>
<integer name="setup_welcome_video_left_padding_weight_in_screen">25</integer>
<integer name="setup_welcome_video_right_padding_weight_in_screen">25</integer>
<integer name="setup_welcome_video_weight_in_screen">70</integer>
<integer name="setup_welcome_video_end_padding_weight_in_screen">30</integer>
</resources>

View File

@ -33,8 +33,8 @@
<dimen name="setup_step_horizontal_line_height">2dp</dimen>
<integer name="setup_title_weight_in_screen">40</integer>
<integer name="setup_body_weight_in_screen">60</integer>
<dimen name="setup_title_end_margin">24dp</dimen>
<dimen name="setup_welcome_video_vertical_margin">24dp</dimen>
<integer name="setup_welcome_video_weight_in_screen">60</integer>
<integer name="setup_welcome_video_left_padding_weight_in_screen">20</integer>
<integer name="setup_welcome_video_right_padding_weight_in_screen">20</integer>
<integer name="setup_welcome_video_end_padding_weight_in_screen">40</integer>
</resources>

View File

@ -33,8 +33,8 @@
<dimen name="setup_step_horizontal_line_height">2dp</dimen>
<integer name="setup_title_weight_in_screen">40</integer>
<integer name="setup_body_weight_in_screen">60</integer>
<dimen name="setup_welcome_video_vertical_margin">24dp</dimen>
<integer name="setup_welcome_video_weight_in_screen">80</integer>
<integer name="setup_welcome_video_left_padding_weight_in_screen">10</integer>
<integer name="setup_welcome_video_right_padding_weight_in_screen">10</integer>
<dimen name="setup_title_end_margin">12dp</dimen>
<dimen name="setup_welcome_video_vertical_margin">12dp</dimen>
<integer name="setup_welcome_video_weight_in_screen">60</integer>
<integer name="setup_welcome_video_end_padding_weight_in_screen">40</integer>
</resources>

View File

@ -33,8 +33,8 @@
<dimen name="setup_step_horizontal_line_height">2dp</dimen>
<integer name="setup_title_weight_in_screen">40</integer>
<integer name="setup_body_weight_in_screen">60</integer>
<dimen name="setup_title_end_margin">16dp</dimen>
<dimen name="setup_welcome_video_vertical_margin">16dp</dimen>
<integer name="setup_welcome_video_weight_in_screen">80</integer>
<integer name="setup_welcome_video_left_padding_weight_in_screen">10</integer>
<integer name="setup_welcome_video_right_padding_weight_in_screen">10</integer>
<integer name="setup_welcome_video_weight_in_screen">70</integer>
<integer name="setup_welcome_video_end_padding_weight_in_screen">30</integer>
</resources>

View File

@ -58,4 +58,5 @@
<color name="setup_text_dark">#FF707070</color>
<color name="setup_text_action">@android:color/holo_blue_light</color>
<color name="setup_step_background">@android:color/background_light</color>
<color name="setup_welcome_video_margin_color">#FFCCCCCC</color>
</resources>

View File

@ -27,6 +27,7 @@ import android.os.Message;
import android.provider.Settings;
import android.util.Log;
import android.view.View;
import android.view.ViewGroup;
import android.view.inputmethod.InputMethodInfo;
import android.widget.ImageView;
import android.widget.TextView;
@ -199,6 +200,11 @@ public final class SetupWizardActivity extends Activity implements View.OnClickL
welcomeVideoView.setVisibility(View.GONE);
welcomeImageView.setImageResource(R.raw.setup_welcome_image);
welcomeImageView.setVisibility(View.VISIBLE);
// Remove unnecessary light gray background around still image.
final ViewGroup videoFrame = (ViewGroup)findViewById(
R.id.setup_welcome_video_frame);
videoFrame.setBackgroundColor(getResources().getColor(R.color.setup_background));
videoFrame.requestLayout();
return true;
}
});