Skip to content

Instantly share code, notes, and snippets.

@evanca
Created January 23, 2018 13:59
Show Gist options
  • Save evanca/acca2217c34a71b4fb1be698988e661e to your computer and use it in GitHub Desktop.
Save evanca/acca2217c34a71b4fb1be698988e661e to your computer and use it in GitHub Desktop.
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item>
<shape android:shape="oval">
<solid android:color="#7CDAF2"/>
<size android:width="50dp" android:height="50dp"/>
</shape>
</item>
</selector>
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item>
<shape android:shape="oval">
<solid android:color="#F29596"/>
<size android:width="50dp" android:height="50dp"/>
</shape>
</item>
</selector>
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item>
<shape android:shape="oval">
<solid android:color="#FFDF70"/>
<size android:width="50dp" android:height="50dp"/>
</shape>
</item>
</selector>
<?xml version="1.0" encoding="utf-8"?>
<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:id="@+id/main_scroll_view"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context=".MainActivity">
<LinearLayout
android:id="@+id/main_linear"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:focusable="true"
android:focusableInTouchMode="true"
android:orientation="vertical">
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="wrap_content">
<ImageView
android:id="@+id/bg_image"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_centerInParent="true"
android:scaleType="centerCrop"
android:src="@drawable/sitcom" />
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:layout_centerHorizontal="true"
android:layout_gravity="fill_vertical"
android:background="#00ffffff"
android:orientation="vertical"
android:padding="@dimen/answer_margin_start_16dp">
<TextView
style="@style/quiz_name"
android:background="#00ffffff"
android:text="@string/friends" />
<View
android:layout_width="match_parent"
android:layout_height="@dimen/large_button_width_200dp"
android:background="#00ffffff" />
<EditText
android:id="@+id/name_field"
style="@style/enter_your_name"
android:layout_width="wrap_content"
android:layout_gravity="center_horizontal"
android:layout_margin="@dimen/answer_margin_start_16dp"
android:hint="@string/please_enter_your_name_to_start_quiz"
android:padding="@dimen/answer_margin_start_16dp" />
<Button
android:id="@+id/start_quiz"
style="@style/start_button"
android:onClick="startQuiz"
android:text="@string/start_quiz" />
</LinearLayout>
</RelativeLayout>
<!-- ***** ***** ***** Question group 1-3 ***** ***** ***** -->
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
<LinearLayout
android:layout_width="@dimen/zero"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_weight="1"
android:orientation="vertical"
android:padding="@dimen/answer_margin_start_16dp">
<LinearLayout
android:id="@+id/question_1"
style="@style/question_layout">
<Button
style="@style/question_number_blush"
android:text="@string/_1_10" />
<TextView
style="@style/question_text"
android:text="@string/question_1" />
</LinearLayout>
<CheckBox
android:id="@+id/Q1A1"
style="@style/checkbox_answer"
android:text="@string/answer_11" />
<CheckBox
android:id="@+id/Q1A2"
style="@style/checkbox_answer"
android:text="@string/answer_12" />
<CheckBox
android:id="@+id/Q1A3"
style="@style/checkbox_answer"
android:text="@string/answer_13" />
<CheckBox
android:id="@+id/Q1A4"
style="@style/checkbox_answer"
android:text="@string/answer_14" />
</LinearLayout>
<LinearLayout
android:layout_width="@dimen/zero"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_weight="1"
android:orientation="vertical"
android:padding="@dimen/answer_margin_start_16dp">
<LinearLayout
android:id="@+id/question_2"
style="@style/question_layout">
<Button
style="@style/question_number_yellow"
android:text="@string/_2_10" />
<TextView
style="@style/question_text"
android:text="@string/question_2" />
</LinearLayout>
<RadioGroup
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="vertical">
<RadioButton
android:id="@+id/Q2A1"
style="@style/checkbox_answer"
android:text="@string/answer_21" />
<RadioButton
android:id="@+id/Q2A2"
style="@style/checkbox_answer"
android:text="@string/answer_22" />
<RadioButton
android:id="@+id/Q2A3"
style="@style/checkbox_answer"
android:text="@string/answer_23" />
<RadioButton
android:id="@+id/Q2A4"
style="@style/checkbox_answer"
android:text="@string/answer_24" />
</RadioGroup>
</LinearLayout>
<LinearLayout
android:layout_width="@dimen/zero"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_weight="1"
android:orientation="vertical"
android:padding="@dimen/answer_margin_start_16dp">
<LinearLayout
android:id="@+id/question_3"
style="@style/question_layout">
<Button
style="@style/question_number_blue"
android:text="@string/_3_10" />
<TextView
style="@style/question_text"
android:text="@string/question_3" />
</LinearLayout>
<RadioGroup
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="vertical">
<RadioButton
android:id="@+id/Q3A1"
style="@style/checkbox_answer"
android:text="@string/answer_31" />
<RadioButton
android:id="@+id/Q3A2"
style="@style/checkbox_answer"
android:text="@string/answer_32" />
<RadioButton
android:id="@+id/Q3A3"
style="@style/checkbox_answer"
android:text="@string/answer_33" />
<RadioButton
android:id="@+id/Q3A4"
style="@style/checkbox_answer"
android:text="@string/answer_34" />
</RadioGroup>
</LinearLayout>
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
<LinearLayout
android:layout_width="@dimen/zero"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_weight="1"
android:orientation="vertical"
android:padding="@dimen/answer_margin_start_16dp">
<Button
android:id="@+id/button_q1"
style="@style/main_button"
android:onClick="submitAnswer1"
android:text="@string/next" />
<View
android:id="@+id/end_of_1"
style="@style/blue_line" />
</LinearLayout>
<LinearLayout
android:layout_width="@dimen/zero"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_weight="1"
android:orientation="vertical"
android:padding="@dimen/answer_margin_start_16dp">
<Button
android:id="@+id/button_q2"
style="@style/main_button"
android:onClick="submitAnswer2"
android:text="@string/next" />
<View
android:id="@+id/end_of_2"
style="@style/blush_line" />
</LinearLayout>
<LinearLayout
android:layout_width="@dimen/zero"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_weight="1"
android:orientation="vertical"
android:padding="@dimen/answer_margin_start_16dp">
<Button
android:id="@+id/button_q3"
style="@style/main_button"
android:onClick="submitAnswer3"
android:text="@string/next" />
<View
android:id="@+id/end_of_3"
style="@style/yellow_line" />
</LinearLayout>
</LinearLayout>
<LinearLayout
android:id="@+id/group_456"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
<LinearLayout
android:layout_width="@dimen/zero"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_weight="1"
android:orientation="vertical"
android:padding="@dimen/answer_margin_start_16dp">
<LinearLayout
android:id="@+id/question_4"
style="@style/question_layout">
<Button
style="@style/question_number_blush"
android:text="@string/_4_10" />
<TextView
style="@style/question_text"
android:text="@string/question_4" />
</LinearLayout>
<CheckBox
android:id="@+id/Q4A1"
style="@style/checkbox_answer"
android:text="@string/answer_41" />
<CheckBox
android:id="@+id/Q4A2"
style="@style/checkbox_answer"
android:text="@string/answer_42" />
<CheckBox
android:id="@+id/Q4A3"
style="@style/checkbox_answer"
android:text="@string/answer_43" />
<CheckBox
android:id="@+id/Q4A4"
style="@style/checkbox_answer"
android:text="@string/answer_44" />
</LinearLayout>
<LinearLayout
android:layout_width="@dimen/zero"
android:layout_height="wrap_content"
android:layout_gravity="top"
android:layout_weight="1"
android:orientation="vertical"
android:padding="@dimen/answer_margin_start_16dp">
<LinearLayout
android:id="@+id/question_5"
style="@style/question_layout">
<Button
style="@style/question_number_yellow"
android:text="@string/_5_10" />
<TextView
style="@style/question_text"
android:text="@string/question_5" />
</LinearLayout>
<EditText
android:id="@+id/Q5A1"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginStart="@dimen/answer_margin_start_16dp"
android:hint="@string/type_in_the_answer"
android:imeOptions="actionDone"
android:inputType="textCapWords"
android:paddingStart="@dimen/answer_padding_start_24dp"
android:paddingTop="@dimen/answer_padding_start_24dp"
android:textAppearance="?android:textAppearanceMedium" />
</LinearLayout>
<LinearLayout
android:layout_width="@dimen/zero"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_weight="1"
android:orientation="vertical"
android:padding="@dimen/answer_margin_start_16dp">
<LinearLayout
android:id="@+id/question_6"
style="@style/question_layout">
<Button
style="@style/question_number_blue"
android:text="@string/_6_10" />
<TextView
style="@style/question_text"
android:text="@string/question_6" />
</LinearLayout>
<RadioGroup
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="vertical">
<RadioButton
android:id="@+id/Q6A1"
style="@style/checkbox_answer"
android:text="@string/answer_61" />
<RadioButton
android:id="@+id/Q6A2"
style="@style/checkbox_answer"
android:text="@string/answer_62" />
<RadioButton
android:id="@+id/Q6A3"
style="@style/checkbox_answer"
android:text="@string/answer_63" />
<RadioButton
android:id="@+id/Q6A4"
style="@style/checkbox_answer"
android:text="@string/answer_64" />
</RadioGroup>
</LinearLayout>
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
<LinearLayout
android:layout_width="@dimen/zero"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_weight="1"
android:orientation="vertical"
android:padding="@dimen/answer_margin_start_16dp">
<Button
android:id="@+id/button_q4"
style="@style/main_button"
android:onClick="submitAnswer4"
android:text="@string/next" />
<View
android:id="@+id/end_of_4"
style="@style/blue_line" />
</LinearLayout>
<LinearLayout
android:layout_width="@dimen/zero"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_weight="1"
android:orientation="vertical"
android:padding="@dimen/answer_margin_start_16dp">
<Button
android:id="@+id/button_q5"
style="@style/main_button"
android:onClick="submitAnswer5"
android:text="@string/next" />
<View
android:id="@+id/end_of_5"
style="@style/blush_line" />
</LinearLayout>
<LinearLayout
android:layout_width="@dimen/zero"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_weight="1"
android:orientation="vertical"
android:padding="@dimen/answer_margin_start_16dp">
<Button
android:id="@+id/button_q6"
style="@style/main_button"
android:onClick="submitAnswer6"
android:text="@string/next" />
<View
android:id="@+id/end_of_6"
style="@style/yellow_line" />
</LinearLayout>
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
<LinearLayout
android:layout_width="@dimen/zero"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_weight="1"
android:orientation="vertical"
android:padding="@dimen/answer_margin_start_16dp">
<LinearLayout
android:id="@+id/question_7"
style="@style/question_layout">
<Button
style="@style/question_number_blush"
android:text="@string/_7_10" />
<TextView
style="@style/question_text"
android:text="@string/question_7" />
</LinearLayout>
<RadioGroup
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="vertical">
<RadioButton
android:id="@+id/Q7A1"
style="@style/checkbox_answer"
android:text="@string/answer_71" />
<RadioButton
android:id="@+id/Q7A2"
style="@style/checkbox_answer"
android:text="@string/answer_72" />
<RadioButton
android:id="@+id/Q7A3"
style="@style/checkbox_answer"
android:text="@string/answer_73" />
<RadioButton
android:id="@+id/Q7A4"
style="@style/checkbox_answer"
android:text="@string/answer_74" />
</RadioGroup>
</LinearLayout>
<LinearLayout
android:layout_width="@dimen/zero"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_weight="1"
android:orientation="vertical"
android:padding="@dimen/answer_margin_start_16dp">
<LinearLayout
android:id="@+id/question_8"
style="@style/question_layout">
<Button
style="@style/question_number_yellow"
android:text="@string/_8_10" />
<TextView
style="@style/question_text"
android:text="@string/question_8" />
</LinearLayout>
<RadioGroup
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="vertical">
<RadioButton
android:id="@+id/Q8A1"
style="@style/checkbox_answer"
android:text="@string/answer_81" />
<RadioButton
android:id="@+id/Q8A2"
style="@style/checkbox_answer"
android:text="@string/answer_82" />
<RadioButton
android:id="@+id/Q8A3"
style="@style/checkbox_answer"
android:text="@string/answer_83" />
<RadioButton
android:id="@+id/Q8A4"
style="@style/checkbox_answer"
android:text="@string/answer_84" />
</RadioGroup>
</LinearLayout>
<LinearLayout
android:layout_width="@dimen/zero"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_weight="1"
android:orientation="vertical"
android:padding="@dimen/answer_margin_start_16dp">
<LinearLayout
android:id="@+id/question_9"
style="@style/question_layout">
<Button
style="@style/question_number_blue"
android:text="@string/_9_10" />
<TextView
style="@style/question_text"
android:text="@string/question_9" />
</LinearLayout>
<RadioGroup
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="vertical">
<RadioButton
android:id="@+id/Q9A1"
style="@style/checkbox_answer"
android:text="@string/answer_91" />
<RadioButton
android:id="@+id/Q9A2"
style="@style/checkbox_answer"
android:text="@string/answer_92" />
<RadioButton
android:id="@+id/Q9A3"
style="@style/checkbox_answer"
android:text="@string/answer_93" />
<RadioButton
android:id="@+id/Q9A4"
style="@style/checkbox_answer"
android:text="@string/answer_94" />
</RadioGroup>
</LinearLayout>
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
<LinearLayout
android:layout_width="@dimen/zero"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_weight="1"
android:orientation="vertical"
android:padding="@dimen/answer_margin_start_16dp">
<Button
android:id="@+id/button_q7"
style="@style/main_button"
android:onClick="submitAnswer7"
android:text="@string/next" />
<View
android:id="@+id/end_of_7"
style="@style/blue_line" />
</LinearLayout>
<LinearLayout
android:layout_width="@dimen/zero"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_weight="1"
android:orientation="vertical"
android:padding="@dimen/answer_margin_start_16dp">
<Button
android:id="@+id/button_q8"
style="@style/main_button"
android:onClick="submitAnswer8"
android:text="@string/next" />
<View
android:id="@+id/end_of_8"
style="@style/blush_line" />
</LinearLayout>
<LinearLayout
android:layout_width="@dimen/zero"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_weight="1"
android:orientation="vertical"
android:padding="@dimen/answer_margin_start_16dp">
<Button
android:id="@+id/button_q9"
style="@style/main_button"
android:onClick="submitAnswer9"
android:text="@string/next" />
<View
android:id="@+id/end_of_9"
style="@style/yellow_line" />
</LinearLayout>
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
<LinearLayout
android:layout_width="@dimen/zero"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_weight="1"
android:orientation="vertical"
android:padding="@dimen/answer_margin_start_16dp">
<LinearLayout
android:id="@+id/question_10"
style="@style/question_layout">
<Button
style="@style/question_number_blush"
android:text="@string/_10_10" />
<TextView
style="@style/question_text"
android:text="@string/question_10" />
</LinearLayout>
<RadioGroup
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="vertical">
<RadioButton
android:id="@+id/Q10A1"
style="@style/checkbox_answer"
android:text="@string/answer_101" />
<RadioButton
android:id="@+id/Q10A2"
style="@style/checkbox_answer"
android:text="@string/answer_102" />
<RadioButton
android:id="@+id/Q10A3"
style="@style/checkbox_answer"
android:text="@string/answer_103" />
<RadioButton
android:id="@+id/Q10A4"
style="@style/checkbox_answer"
android:text="@string/answer_104" />
</RadioGroup>
</LinearLayout>
<LinearLayout
android:layout_width="@dimen/zero"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_weight="2"
android:orientation="vertical"
android:padding="@dimen/answer_margin_start_16dp">
<TextView
android:id="@+id/show_name"
style="@style/show_your_name" />
<Button
android:id="@+id/button_score"
style="@style/large_button"
android:onClick="buttonScore"
android:text="@string/show_me_score" />
<Button
android:id="@+id/button_reset"
style="@style/large_button"
android:onClick="buttonReset"
android:text="@string/reset_try_again" />
</LinearLayout>
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
<LinearLayout
android:layout_width="@dimen/zero"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_weight="1"
android:orientation="vertical"
android:padding="@dimen/answer_margin_start_16dp">
<Button
android:id="@+id/button_q10"
style="@style/main_button"
android:onClick="submitAnswer10"
android:text="@string/submit" />
<View
android:id="@+id/end_of_10"
style="@style/blue_line" />
</LinearLayout>
<LinearLayout
android:layout_width="@dimen/zero"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_weight="2"
android:orientation="vertical"
android:padding="@dimen/answer_margin_start_16dp">
</LinearLayout>
</LinearLayout>
</LinearLayout>
</ScrollView>
package com.example.android.friendsquiz;
import android.content.Context;
import android.content.Intent;
import android.content.res.Configuration;
import android.os.Build;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.text.TextUtils;
import android.util.Log;
import android.view.Gravity;
import android.view.View;
import android.widget.Button;
import android.widget.CheckBox;
import android.widget.EditText;
import android.widget.RadioButton;
import android.widget.ScrollView;
import android.widget.TextView;
import android.widget.Toast;
public class MainActivity extends AppCompatActivity {
int quizScore = 0;
boolean isSmallestScreenWidthDp600;
boolean isPhonePortrait;
boolean isPhoneLandscape;
ScrollView scrollView;
EditText nameField;
TextView showName;
Button buttonStart;
Button buttonQ1;
Button buttonQ2;
Button buttonQ3;
Button buttonQ4;
Button buttonQ5;
Button buttonQ6;
Button buttonQ7;
Button buttonQ8;
Button buttonQ9;
Button buttonQ10;
View question1;
View question2;
View question3;
View question4;
View question5;
View question6;
View question7;
View question8;
View question9;
View question10;
View endOf1;
View endOf2;
View endOf3;
View endOf4;
View endOf5;
View endOf6;
View endOf7;
View endOf8;
View endOf9;
View endOf10;
CheckBox answerQ1A1;
CheckBox answerQ1A2;
CheckBox answerQ1A3;
CheckBox answerQ1A4;
RadioButton answerQ2A3;
RadioButton answerQ3A4;
CheckBox answerQ4A1;
CheckBox answerQ4A2;
CheckBox answerQ4A3;
CheckBox answerQ4A4;
EditText answerQ5A1;
RadioButton answerQ6A1;
RadioButton answerQ7A4;
RadioButton answerQ8A1;
RadioButton answerQ9A2;
RadioButton answerQ10A4;
View mainLinear;
View bgImage;
View group456;
/**
* "Q" is for Question
* "A" is for Answer
*/
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
scrollView = findViewById(R.id.main_scroll_view);
nameField = findViewById(R.id.name_field);
showName = findViewById(R.id.show_name);
buttonStart = findViewById(R.id.start_quiz);
buttonQ1 = findViewById(R.id.button_q1);
buttonQ2 = findViewById(R.id.button_q2);
buttonQ3 = findViewById(R.id.button_q3);
buttonQ4 = findViewById(R.id.button_q4);
buttonQ5 = findViewById(R.id.button_q5);
buttonQ6 = findViewById(R.id.button_q6);
buttonQ7 = findViewById(R.id.button_q7);
buttonQ8 = findViewById(R.id.button_q8);
buttonQ9 = findViewById(R.id.button_q9);
buttonQ10 = findViewById(R.id.button_q10);
question1 = findViewById(R.id.question_1);
question2 = findViewById(R.id.question_2);
question3 = findViewById(R.id.question_3);
question4 = findViewById(R.id.question_4);
question5 = findViewById(R.id.question_5);
question6 = findViewById(R.id.question_6);
question7 = findViewById(R.id.question_7);
question8 = findViewById(R.id.question_8);
question9 = findViewById(R.id.question_9);
question10 = findViewById(R.id.question_10);
endOf1 = findViewById(R.id.end_of_1);
endOf2 = findViewById(R.id.end_of_2);
endOf3 = findViewById(R.id.end_of_3);
endOf4 = findViewById(R.id.end_of_4);
endOf5 = findViewById(R.id.end_of_5);
endOf6 = findViewById(R.id.end_of_6);
endOf7 = findViewById(R.id.end_of_7);
endOf8 = findViewById(R.id.end_of_8);
endOf9 = findViewById(R.id.end_of_9);
endOf10 = findViewById(R.id.end_of_10);
answerQ1A1 = findViewById(R.id.Q1A1);
answerQ1A2 = findViewById(R.id.Q1A2);
answerQ1A3 = findViewById(R.id.Q1A3);
answerQ1A4 = findViewById(R.id.Q1A4);
answerQ2A3 = findViewById(R.id.Q2A3);
answerQ3A4 = findViewById(R.id.Q3A4);
answerQ4A1 = findViewById(R.id.Q4A1);
answerQ4A2 = findViewById(R.id.Q4A2);
answerQ4A3 = findViewById(R.id.Q4A3);
answerQ4A4 = findViewById(R.id.Q4A4);
answerQ5A1 = findViewById(R.id.Q5A1);
answerQ6A1 = findViewById(R.id.Q6A1);
answerQ7A4 = findViewById(R.id.Q7A4);
answerQ8A1 = findViewById(R.id.Q8A1);
answerQ9A2 = findViewById(R.id.Q9A2);
answerQ10A4 = findViewById(R.id.Q10A4);
mainLinear = findViewById(R.id.main_linear);
bgImage = findViewById(R.id.bg_image);
group456 = findViewById(R.id.group_456;
if (getResources().getConfiguration().smallestScreenWidthDp >= 600) {
isSmallestScreenWidthDp600 = true;
} else {
isSmallestScreenWidthDp600 = false;
}
if (getResources().getConfiguration().orientation == Configuration.ORIENTATION_PORTRAIT) {
isPhonePortrait = true;
} else {
isPhonePortrait = false;
}
if (getResources().getConfiguration().orientation == Configuration.ORIENTATION_LANDSCAPE) {
isPhoneLandscape = true;
} else {
isPhoneLandscape = false;
}
}
public void startQuiz(View view) {
// Get user submitted name to string:
String getNameField = nameField.getText().toString();
// Update the message shown at the end:
showName.setText(getString(R.string.are_you_ready) + " " + getNameField + '?');
// If there is no name, show error & disable first question
if (TextUtils.isEmpty(getNameField)) {
nameField.setError(getString(R.string.name_error));
buttonQ1.setEnabled(false);
// If there is a name, disable the start button & scroll to the first question
} else {
buttonStart.setEnabled(false);
buttonQ1.setEnabled(true);
if (isSmallestScreenWidthDp600)
{
scrollView.postDelayed(new Runnable() {
public void run() {
scrollView.scrollTo(0, (int) bgImage.getBottom());
}
}, 100);
} else {
if (isPhonePortrait)
{
scrollView.postDelayed(new Runnable() {
public void run() {
scrollView.scrollBy(0, (int) question1.getTop());
}
}, 100);
}
// If orientation is horizontal, scroll to the bottom (!) of first question:
else if (isPhoneLandscape)
{
scrollView.postDelayed(new Runnable() {
public void run() {
scrollView.scrollTo(0, (int) endOf1.getTop());
}
}, 100);
}
}
}
}
/**
* ***** ***** ***** Question nr. 1 ***** ***** *****
*/
public void submitAnswer1(View view) {
// Get user submitted answer:
boolean isCheckedQ1A1 = answerQ1A1.isChecked();
boolean isCheckedQ1A2 = answerQ1A2.isChecked();
boolean isCheckedQ1A3 = answerQ1A3.isChecked();
boolean isCheckedQ1A4 = answerQ1A4.isChecked();
// Check if the answer is correct & update the quiz score:
if ((isCheckedQ1A1 == false) && isCheckedQ1A2 && isCheckedQ1A3 && isCheckedQ1A4) {
quizScore = quizScore + 1;
Log.v("MainActivity", "Score is " + quizScore);
}
// Prevent multiple answer submitting:
buttonQ1.setEnabled(false);
// Finish here & scroll to the next question:
if (isSmallestScreenWidthDp600)
{
scrollView.postDelayed(new Runnable() {
public void run() {
scrollView.scrollTo(0, (int) bgImage.getBottom());
}
}, 100);
} else {
// If orientation is vertical, scroll to the top (!) of next question:
if (isPhonePortrait)
{
scrollView.postDelayed(new Runnable() {
public void run() {
scrollView.scrollTo(0, (int) question2.getTop());
}
}, 100);
}
// If orientation is horizontal, scroll to the bottom (!) of next question:
else if (isPhoneLandscape)
{
scrollView.postDelayed(new Runnable() {
public void run() {
scrollView.scrollTo(0, (int) endOf2.getBottom());
}
}, 100);
}
}
}
/**
* ***** ***** ***** Question nr. 2 ***** ***** *****
*/
public void submitAnswer2(View view) {
boolean isCheckedQ2A3 = answerQ2A3.isChecked();
// Check if the answer is correct & update the quiz score:
if (isCheckedQ2A3) {
quizScore = quizScore + 1;
Log.v("MainActivity", "Score is " + quizScore);
}
// Prevent multiple answer submitting:
buttonQ2.setEnabled(false);
// Finish here & scroll to the next question:
if (isSmallestScreenWidthDp600)
{
scrollView.postDelayed(new Runnable() {
public void run() {
scrollView.scrollTo(0, (int) bgImage.getBottom());
}
}, 100);
} else {
if (isPhonePortrait)
{
scrollView.postDelayed(new Runnable() {
public void run() {
scrollView.scrollTo(0, (int) question3.getTop());
}
}, 100);
} else if (isPhoneLandscape)
{
scrollView.postDelayed(new Runnable() {
public void run() {
scrollView.scrollTo(0, (int) endOf3.getTop());
}
}, 100);
}
}
}
/**
* ***** ***** ***** Question nr. 3 ***** ***** *****
*/
public void submitAnswer3(View view) {
boolean isCheckedQ3A4 = answerQ3A4.isChecked();
// Check if the answer is correct & update the quiz score:
if (isCheckedQ3A4) {
quizScore = quizScore + 1;
Log.v("MainActivity", "Score is " + quizScore);
}
// Prevent multiple answer submitting:
buttonQ3.setEnabled(false);
// Finish here & scroll to the next question:
if (isSmallestScreenWidthDp600)
{
scrollView.postDelayed(new Runnable() {
public void run() {
scrollView.scrollTo(0, (int) group456.getTop());
}
}, 100);
} else {
if (isPhonePortrait)
{
scrollView.postDelayed(new Runnable() {
public void run() {
scrollView.scrollTo(0, (int) question4.getTop());
}
}, 100);
} else if (isPhoneLandscape)
{
scrollView.postDelayed(new Runnable() {
public void run() {
scrollView.scrollTo(0, (int) endOf4.getBottom());
}
}, 100);
}
}
}
/**
* ***** ***** ***** Question nr. 4 ***** ***** *****
*/
public void submitAnswer4(View view) {
// Get user submitted answer:
boolean isCheckedQ4A1 = answerQ4A1.isChecked();
boolean isCheckedQ4A2 = answerQ4A2.isChecked();
boolean isCheckedQ4A3 = answerQ4A3.isChecked();
boolean isCheckedQ4A4 = answerQ4A4.isChecked();
// Check if the answer is correct & update the quiz score:
if (isCheckedQ4A1 && (isCheckedQ4A2 == false) && isCheckedQ4A3 && isCheckedQ4A4) {
quizScore = quizScore + 1;
Log.v("MainActivity", "Score is " + quizScore);
}
// Prevent multiple answer submitting:
buttonQ4.setEnabled(false);
// Finish here & scroll to the next question:
if (isSmallestScreenWidthDp600)
{
scrollView.postDelayed(new Runnable() {
public void run() {
scrollView.scrollTo(0, (int) group456.getTop());
}
}, 100);
} else {
if (isPhonePortrait)
{
scrollView.postDelayed(new Runnable() {
public void run() {
scrollView.scrollTo(0, (int) question5.getTop());
}
}, 100);
} else if (isPhoneLandscape)
{
scrollView.postDelayed(new Runnable() {
public void run() {
scrollView.scrollTo(0, (int) endOf5.getBottom());
}
}, 100);
}
}
}
/**
* ***** ***** ***** Question nr. 5 ***** ***** *****
*/
public void submitAnswer5(View view) {
// Check if the answer is correct & update the quiz score:
if (answerQ5A1.getText().toString().equals("Gunther")) {
quizScore = quizScore + 1;
Log.v("MainActivity", "Score is " + quizScore);
}
// Prevent multiple answer submitting:
buttonQ5.setEnabled(false);
// Finish here & scroll to the next question:
if (isSmallestScreenWidthDp600)
{
scrollView.postDelayed(new Runnable() {
public void run() {
scrollView.scrollTo(0, (int) group456.getTop());
}
}, 100);
} else {
if (isPhonePortrait)
{
scrollView.postDelayed(new Runnable() {
public void run() {
scrollView.scrollTo(0, (int) question6.getTop());
}
}, 100);
} else if (isPhoneLandscape)
{
scrollView.postDelayed(new Runnable() {
public void run() {
scrollView.scrollTo(0, (int) endOf6.getBottom());
}
}, 100);
}
}
}
/**
* ***** ***** ***** Question nr. 6 ***** ***** *****
*/
public void submitAnswer6(View view) {
boolean isCheckedQ6A1 = answerQ6A1.isChecked();
// Check if the answer is correct & update the quiz score:
if (isCheckedQ6A1) {
quizScore = quizScore + 1;
Log.v("MainActivity", "Score is " + quizScore);
}
// Prevent multiple answer submitting:
buttonQ6.setEnabled(false);
// Finish here & scroll to the next question:
if (isSmallestScreenWidthDp600)
{
scrollView.postDelayed(new Runnable() {
public void run() {
scrollView.scrollTo(0, group456.getBottom());
}
}, 100);
} else {
if (isPhonePortrait)
{
scrollView.postDelayed(new Runnable() {
public void run() {
scrollView.scrollTo(0, (int) question7.getTop());
}
}, 100);
} else if (isPhoneLandscape)
{
scrollView.postDelayed(new Runnable() {
public void run() {
scrollView.scrollTo(0, (int) endOf7.getBottom());
}
}, 100);
}
}
}
/**
* ***** ***** ***** Question nr. 7 ***** ***** *****
*/
public void submitAnswer7(View view) {
boolean isCheckedQ7A4 = answerQ7A4.isChecked();
// Check if the answer is correct & update the quiz score:
if (isCheckedQ7A4) {
quizScore = quizScore + 1;
Log.v("MainActivity", "Score is " + quizScore);
}
// Prevent multiple answer submitting:
buttonQ7.setEnabled(false);
// Finish here & scroll to the next question:
if (isSmallestScreenWidthDp600)
{
scrollView.postDelayed(new Runnable() {
public void run() {
scrollView.scrollTo(0, group456.getBottom());
}
}, 100);
} else {
if (isPhonePortrait)
{
scrollView.postDelayed(new Runnable() {
public void run() {
scrollView.scrollTo(0, (int) question8.getTop());
}
}, 100);
} else if (isPhoneLandscape)
{
scrollView.postDelayed(new Runnable() {
public void run() {
scrollView.scrollTo(0, (int) endOf8.getBottom());
}
}, 100);
}
}
}
/**
* ***** ***** ***** Question nr. 8 ***** ***** *****
*/
public void submitAnswer8(View view) {
boolean isCheckedQ8A1 = answerQ8A1.isChecked();
// Check if the answer is correct & update the quiz score:
if (isCheckedQ8A1) {
quizScore = quizScore + 1;
Log.v("MainActivity", "Score is " + quizScore);
}
// Prevent multiple answer submitting:
buttonQ8.setEnabled(false);
// Finish here & scroll to the next question:
if (isSmallestScreenWidthDp600)
{
scrollView.postDelayed(new Runnable() {
public void run() {
scrollView.scrollTo(0, group456.getBottom());
}
}, 100);
} else {
if (isPhonePortrait)
{
scrollView.postDelayed(new Runnable() {
public void run() {
scrollView.scrollTo(0, (int) question9.getTop());
}
}, 100);
} else if (isPhoneLandscape)
{
scrollView.postDelayed(new Runnable() {
public void run() {
scrollView.scrollTo(0, (int) endOf9.getBottom());
}
}, 100);
}
}
}
/**
* ***** ***** ***** Question nr. 9 ***** ***** *****
*/
public void submitAnswer9(View view) {
boolean isCheckedQ9A2 = answerQ9A2.isChecked();
// Check if the answer is correct & update the quiz score:
if (isCheckedQ9A2) {
quizScore = quizScore + 1;
Log.v("MainActivity", "Score is " + quizScore);
}
// Prevent multiple answer submitting:
buttonQ9.setEnabled(false);
// Finish here & scroll to the next question:
if (isSmallestScreenWidthDp600)
{
scrollView.postDelayed(new Runnable() {
public void run() {
scrollView.scrollTo(0, mainLinear.getBottom());
}
}, 100);
} else {
if (isPhonePortrait)
{
scrollView.postDelayed(new Runnable() {
public void run() {
scrollView.scrollTo(0, (int) question10.getTop());
}
}, 100);
} else if (isPhoneLandscape)
{
scrollView.postDelayed(new Runnable() {
public void run() {
scrollView.scrollTo(0, (int) endOf10.getBottom());
}
}, 100);
}
}
}
/**
* ***** ***** ***** Question nr. 10 ***** ***** *****
*/
public void submitAnswer10(View view) {
boolean isCheckedQ10A4 = answerQ10A4.isChecked();
// Check if the answer is correct & update the quiz score:
if (isCheckedQ10A4) {
quizScore = quizScore + 1;
Log.v("MainActivity", "Score is " + quizScore);
}
// Prevent multiple answer submitting:
buttonQ10.setEnabled(false);
// Finish here & scroll to the end:
if (isSmallestScreenWidthDp600)
{
scrollView.postDelayed(new Runnable() {
public void run() {
scrollView.scrollTo(0, mainLinear.getBottom());
}
}, 100);
} else {
if (isPhonePortrait)
{
scrollView.postDelayed(new Runnable() {
public void run() {
scrollView.scrollTo(0, (int) showName.getTop());
}
}, 100);
} else if (isPhoneLandscape)
{
scrollView.postDelayed(new Runnable() {
public void run() {
scrollView.scrollTo(0, (int) mainLinear.getBottom());
}
}, 100);
}
}
}
/**
* Show the quiz score toast:
*/
public void buttonScore(View view) {
if (quizScore == 10) {
Toast toast = Toast.makeText(getApplicationContext(), getString(R.string.you_scored).toUpperCase() + " " + quizScore + " " + getString(R.string.out_of_10).toUpperCase() + "\n\n\n" + getString(R.string.how_you_doin), Toast.LENGTH_LONG);
toast.setGravity(Gravity.CENTER, 0, 0);
toast.show();
}
if (quizScore > 5 && quizScore < 10) {
Toast toast = Toast.makeText(getApplicationContext(), getString(R.string.you_scored).toUpperCase() + " " + quizScore + " " + getString(R.string.out_of_10).toUpperCase() + "\n\n\n" + getString(R.string.they_dont_know), Toast.LENGTH_LONG);
toast.setGravity(Gravity.CENTER, 0, 0);
toast.show();
}
if (quizScore <= 5) {
Toast toast = Toast.makeText(getApplicationContext(), getString(R.string.you_scored).toUpperCase() + " " + quizScore + " " + getString(R.string.out_of_10).toUpperCase() + "\n\n\n" + getString(R.string.big_deal), Toast.LENGTH_LONG);
toast.setGravity(Gravity.CENTER, 0, 0);
toast.show();
}
}
/**
* ***** ***** ***** Reset quiz: ***** ***** *****
*/
public void buttonReset(View view) {
Intent i = getApplicationContext().getPackageManager()
.getLaunchIntentForPackage(getApplicationContext().getPackageName());
i.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP | Intent.FLAG_ACTIVITY_NEW_TASK);
startActivity(i);
}
}
<?xml version="1.0" encoding="utf-8"?>
<resources>
<color name="colorPrimary">#3F51B5</color>
<color name="colorPrimaryDark">#303F9F</color>
<color name="colorAccent">#FF4081</color>
<color name="title">#3e3e3e</color>
<color name="name">#3e3e3e</color>
</resources>
<?xml version="1.0" encoding="utf-8"?>
<resources>
<dimen name="button_margin_text_start_end_8dp">8dp</dimen>
<dimen name="answer_margin_start_16dp">16dp</dimen>
<dimen name="answer_padding_start_24dp">24dp</dimen>
<dimen name="question_padding_top_48dp">48dp</dimen>
<dimen name="question_circle_diameter_50dp">50dp</dimen>
<dimen name="large_button_width_200dp">200dp</dimen>
<dimen name="name_text_size_34sp">34sp</dimen>
<dimen name="logo_text_size_54sp">154sp</dimen>
<dimen name="zero">0dp</dimen>
</resources>
<?xml version="1.0" encoding="utf-8"?>
<resources>
<array name="com_google_android_gms_fonts_certs">
<item>@array/com_google_android_gms_fonts_certs_dev</item>
<item>@array/com_google_android_gms_fonts_certs_prod</item>
</array>
<string-array name="com_google_android_gms_fonts_certs_dev">
<item>
MIIEqDCCA5CgAwIBAgIJANWFuGx90071MA0GCSqGSIb3DQEBBAUAMIGUMQswCQYDVQQGEwJVUzETMBEGA1UECBMKQ2FsaWZvcm5pYTEWMBQGA1UEBxMNTW91bnRhaW4gVmlldzEQMA4GA1UEChMHQW5kcm9pZDEQMA4GA1UECxMHQW5kcm9pZDEQMA4GA1UEAxMHQW5kcm9pZDEiMCAGCSqGSIb3DQEJARYTYW5kcm9pZEBhbmRyb2lkLmNvbTAeFw0wODA0MTUyMzM2NTZaFw0zNTA5MDEyMzM2NTZaMIGUMQswCQYDVQQGEwJVUzETMBEGA1UECBMKQ2FsaWZvcm5pYTEWMBQGA1UEBxMNTW91bnRhaW4gVmlldzEQMA4GA1UEChMHQW5kcm9pZDEQMA4GA1UECxMHQW5kcm9pZDEQMA4GA1UEAxMHQW5kcm9pZDEiMCAGCSqGSIb3DQEJARYTYW5kcm9pZEBhbmRyb2lkLmNvbTCCASAwDQYJKoZIhvcNAQEBBQADggENADCCAQgCggEBANbOLggKv+IxTdGNs8/TGFy0PTP6DHThvbbR24kT9ixcOd9W+EaBPWW+wPPKQmsHxajtWjmQwWfna8mZuSeJS48LIgAZlKkpFeVyxW0qMBujb8X8ETrWy550NaFtI6t9+u7hZeTfHwqNvacKhp1RbE6dBRGWynwMVX8XW8N1+UjFaq6GCJukT4qmpN2afb8sCjUigq0GuMwYXrFVee74bQgLHWGJwPmvmLHC69EH6kWr22ijx4OKXlSIx2xT1AsSHee70w5iDBiK4aph27yH3TxkXy9V89TDdexAcKk/cVHYNnDBapcavl7y0RiQ4biu8ymM8Ga/nmzhRKya6G0cGw8CAQOjgfwwgfkwHQYDVR0OBBYEFI0cxb6VTEM8YYY6FbBMvAPyT+CyMIHJBgNVHSMEgcEwgb6AFI0cxb6VTEM8YYY6FbBMvAPyT+CyoYGapIGXMIGUMQswCQYDVQQGEwJVUzETMBEGA1UECBMKQ2FsaWZvcm5pYTEWMBQGA1UEBxMNTW91bnRhaW4gVmlldzEQMA4GA1UEChMHQW5kcm9pZDEQMA4GA1UECxMHQW5kcm9pZDEQMA4GA1UEAxMHQW5kcm9pZDEiMCAGCSqGSIb3DQEJARYTYW5kcm9pZEBhbmRyb2lkLmNvbYIJANWFuGx90071MAwGA1UdEwQFMAMBAf8wDQYJKoZIhvcNAQEEBQADggEBABnTDPEF+3iSP0wNfdIjIz1AlnrPzgAIHVvXxunW7SBrDhEglQZBbKJEk5kT0mtKoOD1JMrSu1xuTKEBahWRbqHsXclaXjoBADb0kkjVEJu/Lh5hgYZnOjvlba8Ld7HCKePCVePoTJBdI4fvugnL8TsgK05aIskyY0hKI9L8KfqfGTl1lzOv2KoWD0KWwtAWPoGChZxmQ+nBli+gwYMzM1vAkP+aayLe0a1EQimlOalO762r0GXO0ks+UeXde2Z4e+8S/pf7pITEI/tP+MxJTALw9QUWEv9lKTk+jkbqxbsh8nfBUapfKqYn0eidpwq2AzVp3juYl7//fKnaPhJD9gs=
</item>
</string-array>
<string-array name="com_google_android_gms_fonts_certs_prod">
<item>
MIIEQzCCAyugAwIBAgIJAMLgh0ZkSjCNMA0GCSqGSIb3DQEBBAUAMHQxCzAJBgNVBAYTAlVTMRMwEQYDVQQIEwpDYWxpZm9ybmlhMRYwFAYDVQQHEw1Nb3VudGFpbiBWaWV3MRQwEgYDVQQKEwtHb29nbGUgSW5jLjEQMA4GA1UECxMHQW5kcm9pZDEQMA4GA1UEAxMHQW5kcm9pZDAeFw0wODA4MjEyMzEzMzRaFw0zNjAxMDcyMzEzMzRaMHQxCzAJBgNVBAYTAlVTMRMwEQYDVQQIEwpDYWxpZm9ybmlhMRYwFAYDVQQHEw1Nb3VudGFpbiBWaWV3MRQwEgYDVQQKEwtHb29nbGUgSW5jLjEQMA4GA1UECxMHQW5kcm9pZDEQMA4GA1UEAxMHQW5kcm9pZDCCASAwDQYJKoZIhvcNAQEBBQADggENADCCAQgCggEBAKtWLgDYO6IIrgqWbxJOKdoR8qtW0I9Y4sypEwPpt1TTcvZApxsdyxMJZ2JORland2qSGT2y5b+3JKkedxiLDmpHpDsz2WCbdxgxRczfey5YZnTJ4VZbH0xqWVW/8lGmPav5xVwnIiJS6HXk+BVKZF+JcWjAsb/GEuq/eFdpuzSqeYTcfi6idkyugwfYwXFU1+5fZKUaRKYCwkkFQVfcAs1fXA5V+++FGfvjJ/CxURaSxaBvGdGDhfXE28LWuT9ozCl5xw4Yq5OGazvV24mZVSoOO0yZ31j7kYvtwYK6NeADwbSxDdJEqO4k//0zOHKrUiGYXtqw/A0LFFtqoZKFjnkCAQOjgdkwgdYwHQYDVR0OBBYEFMd9jMIhF1Ylmn/Tgt9r45jk14alMIGmBgNVHSMEgZ4wgZuAFMd9jMIhF1Ylmn/Tgt9r45jk14aloXikdjB0MQswCQYDVQQGEwJVUzETMBEGA1UECBMKQ2FsaWZvcm5pYTEWMBQGA1UEBxMNTW91bnRhaW4gVmlldzEUMBIGA1UEChMLR29vZ2xlIEluYy4xEDAOBgNVBAsTB0FuZHJvaWQxEDAOBgNVBAMTB0FuZHJvaWSCCQDC4IdGZEowjTAMBgNVHRMEBTADAQH/MA0GCSqGSIb3DQEBBAUAA4IBAQBt0lLO74UwLDYKqs6Tm8/yzKkEu116FmH4rkaymUIE0P9KaMftGlMexFlaYjzmB2OxZyl6euNXEsQH8gjwyxCUKRJNexBiGcCEyj6z+a1fuHHvkiaai+KL8W1EyNmgjmyy8AW7P+LLlkR+ho5zEHatRbM/YAnqGcFh5iZBqpknHf1SKMXFh4dd239FJ1jWYfbMDMy3NS5CTMQ2XFI1MvcyUTdZPErjQfTbQe3aDQsQcafEQPD+nqActifKZ0Np0IS9L9kR/wbNvyz6ENwPiTrjV2KRkEjH78ZMcUQXg0L3BYHJ3lc69Vs5Ddf9uUGGMYldX3WfMBEmh/9iFBDAaTCK
</item>
</string-array>
</resources>
<?xml version="1.0" encoding="utf-8"?>
<resources>
<array name="preloaded_fonts" translatable="false">
<item>@font/covered_by_your_grace</item>
<item>@font/roboto</item>
</array>
</resources>
<resources>
<string name="app_name">Friends Quiz</string>
<string name="question_1">Who had a lunch together every day for all 10 years of filming?</string>
<string name="answer_11">David Schwimmer</string>
<string name="answer_12">Jennifer Aniston</string>
<string name="answer_13">Courteney Cox</string>
<string name="answer_14">Lisa Kudrow</string>
<string name="question_2">How many hours average Friends episode took to film?</string>
<string name="answer_21">Nine</string>
<string name="answer_22">Eleven</string>
<string name="answer_23">Five</string>
<string name="answer_24">Two</string>
<string name="question_3">In the first season, each of the main six cast members received $22,000 per episode. How much did they earn by the final season?</string>
<string name="answer_31">$100,000 per episode</string>
<string name="answer_32">$50,000 per episode</string>
<string name="answer_33">$200,000 per episode</string>
<string name="answer_34">$1,000,000 per episode</string>
<string name="question_4">How was the show originally called, before becoming Friends?</string>
<string name="answer_41">Insomnia Cafe</string>
<string name="answer_42">Days of Our Lives</string>
<string name="answer_43">Friends Like Us</string>
<string name="answer_44">Six of One</string>
<string name="question_5">Which character didn\'t have a name until the middle of the second season?</string>
<string name="type_in_the_answer">Type in the answer</string>
<string name="question_6">Which actress producers originally wanted to play Rachel?</string>
<string name="answer_61">Courteney Cox</string>
<string name="answer_62">Monica Bellucci</string>
<string name="answer_63">Lisa Kudrow</string>
<string name="answer_64">Cameron Diaz</string>
<string name="question_7">Ross is __ years old for three years.</string>
<string name="answer_71" translatable="false">30</string>
<string name="answer_72" translatable="false">32</string>
<string name="answer_73" translatable="false">36</string>
<string name="answer_74" translatable="false">29</string>
<string name="question_8">Who directed 10 Friends episodes?</string>
<string name="answer_81">David Schwimmer</string>
<string name="answer_82">Courteney Cox</string>
<string name="answer_83">Matthew Perry</string>
<string name="answer_84">Jennifer Aniston</string>
<string name="question_9">Which actress turned down an offer to play Phoebe?</string>
<string name="answer_91">Cameron Diaz</string>
<string name="answer_92">Ellen DeGeneres</string>
<string name="answer_93">Pamela Anderson</string>
<string name="answer_94">Drew Barrymore</string>
<string name="question_10">What is the name of character Joey plays in a soap opera Days of Our Lives?</string>
<string name="answer_101">Dr. Blake Ramoray</string>
<string name="answer_102">Dr. Blake Memoray</string>
<string name="answer_103">Dr. Drake Lemoray</string>
<string name="answer_104">Dr. Drake Ramoray</string>
<string name="welcome_to_the">Welcome to the</string>
<string name="friends">Friends</string>
<string name="quiz">Quiz</string>
<string name="next"><![CDATA[Submit & Go Next]]></string>
<string name="reset_try_again"><![CDATA[RESET & TRY AGAIN]]></string>
<string name="score">score</string>
<string name="are_you_ready">Are you ready,</string>
<string name="name_error">Please enter your name!</string>
<string name="you_scored">You scored</string>
<string name="out_of_10">out of 10!</string>
<string name="how_you_doin">How YOU doin\'?</string>
<string name="they_dont_know">They don\'t know that we know they know we know!</string>
<string name="big_deal">Just so you know, it\'s not that common, it doesn\'t happen to every guy, and it is a big deal!</string>
<string name="show_me_score">SHOW ME SCORE</string>
<string name="submit">SUBMIT</string>
<string name="_10_10">10/10</string>
<string name="_9_10">9/10</string>
<string name="_8_10">8/10</string>
<string name="_7_10">7/10</string>
<string name="_6_10">6/10</string>
<string name="_5_10">5/10</string>
<string name="_4_10">4/10</string>
<string name="_3_10">3/10</string>
<string name="_2_10">2/10</string>
<string name="_1_10">1/10</string>
<string name="start_quiz">Start Quiz</string>
<string name="please_enter_your_name_to_start_quiz">Please enter your name to start quiz!</string>
</resources>
<resources>
<!-- Base application theme. -->
<style name="AppTheme" parent="Theme.AppCompat.Light.NoActionBar">
<!-- Customize your theme here. -->
<item name="colorPrimary">@color/colorPrimary</item>
<item name="colorPrimaryDark">@color/colorPrimaryDark</item>
<item name="colorAccent">@color/colorAccent</item>
<item name="android:background">#F5F3F3</item>
</style>
<style name="quiz_name">
<item name="android:layout_width">wrap_content</item>
<item name="android:layout_height">wrap_content</item>
<item name="android:layout_gravity">center_horizontal</item>
<item name="android:fontFamily">@font/covered_by_your_grace</item>
<item name="android:gravity">center</item>
<item name="android:textAllCaps">true</item>
<item name="android:textColor">@color/title</item>
<item name="android:textScaleX">1.2</item>
<item name="android:textSize">@dimen/logo_text_size_54sp</item>
</style>
<style name="enter_your_name">
<item name="android:layout_width">match_parent</item>
<item name="android:layout_height">wrap_content</item>
<item name="android:layout_marginBottom">@dimen/answer_padding_start_24dp</item>
<item name="android:layout_marginTop">@dimen/answer_padding_start_24dp</item>
<item name="android:cursorVisible">false</item>
<item name="android:gravity">center</item>
<item name="android:imeOptions">actionDone</item>
<item name="android:inputType">textCapWords</item>
</style>
<style name="main_button">
<item name="android:layout_width">wrap_content</item>
<item name="android:layout_height">wrap_content</item>
<item name="android:layout_gravity">center</item>
<item name="android:layout_marginTop">@dimen/answer_padding_start_24dp</item>
</style>
<style name="start_button">
<item name="android:layout_width">wrap_content</item>
<item name="android:layout_height">wrap_content</item>
<item name="android:layout_gravity">center</item>
<item name="android:layout_marginTop">@dimen/answer_padding_start_24dp</item>
</style>
<style name="yellow_line">
<item name="android:layout_width">match_parent</item>
<item name="android:layout_height">1dp</item>
<item name="android:layout_marginTop">@dimen/answer_padding_start_24dp</item>
<item name="android:background">#FFDF70</item>
</style>
<style name="question_layout_old">
<item name="android:layout_width">wrap_content</item>
<item name="android:layout_height">wrap_content</item>
<item name="android:orientation">horizontal</item>
<item name="android:paddingTop">@dimen/answer_padding_start_24dp</item>
</style>
<style name="question_number_blush">
<item name="android:layout_width">@dimen/question_circle_diameter_50dp</item>
<item name="android:layout_height">@dimen/question_circle_diameter_50dp</item>
<item name="android:layout_gravity">center</item>
<item name="android:layout_margin">@dimen/button_margin_text_start_end_8dp</item>
<item name="android:background">@drawable/circle_blush</item>
<item name="android:textColor">@android:color/white</item>
</style>
<style name="question_text">
<item name="android:layout_width">wrap_content</item>
<item name="android:layout_height">wrap_content</item>
<item name="android:paddingBottom">@dimen/button_margin_text_start_end_8dp</item>
<item name="android:paddingEnd">@dimen/button_margin_text_start_end_8dp</item>
<item name="android:paddingLeft">@dimen/button_margin_text_start_end_8dp</item>
<item name="android:paddingStart">@dimen/button_margin_text_start_end_8dp</item>
<item name="android:textAppearance">?android:textAppearanceLarge</item>
</style>
<style name="checkbox_answer">
<item name="android:layout_width">wrap_content</item>
<item name="android:layout_height">wrap_content</item>
<item name="android:layout_marginStart">@dimen/answer_margin_start_16dp</item>
<item name="android:paddingStart">@dimen/answer_padding_start_24dp</item>
<item name="android:textAppearance">?android:textAppearanceMedium</item>
</style>
<style name="question_number_yellow">
<item name="android:layout_width">@dimen/question_circle_diameter_50dp</item>
<item name="android:layout_height">@dimen/question_circle_diameter_50dp</item>
<item name="android:layout_gravity">center</item>
<item name="android:layout_margin">@dimen/button_margin_text_start_end_8dp</item>
<item name="android:background">@drawable/circle_yellow</item>
<item name="android:textColor">@android:color/white</item>
</style>
<style name="blush_line">
<item name="android:layout_width">match_parent</item>
<item name="android:layout_height">1dp</item>
<item name="android:layout_marginTop">@dimen/answer_padding_start_24dp</item>
<item name="android:background">#F29596</item>
</style>
<style name="question_layout">
<item name="android:layout_width">wrap_content</item>
<item name="android:layout_height">wrap_content</item>
<item name="android:orientation">horizontal</item>
<item name="android:paddingTop">@dimen/question_padding_top_48dp</item>
</style>
<style name="question_number_blue">
<item name="android:layout_width">@dimen/question_circle_diameter_50dp</item>
<item name="android:layout_height">@dimen/question_circle_diameter_50dp</item>
<item name="android:layout_gravity">center</item>
<item name="android:layout_margin">@dimen/button_margin_text_start_end_8dp</item>
<item name="android:background">@drawable/circle_blue</item>
<item name="android:textColor">@android:color/white</item>
</style>
<style name="show_your_name">
<item name="android:layout_width">wrap_content</item>
<item name="android:layout_height">wrap_content</item>
<item name="android:layout_gravity">center_horizontal</item>
<item name="android:gravity">center</item>
<item name="android:padding">@dimen/answer_margin_start_16dp</item>
<item name="android:textColor">@color/name</item>
<item name="android:textSize">@dimen/name_text_size_34sp</item>
</style>
<style name="large_button">
<item name="android:layout_width">@dimen/large_button_width_200dp</item>
<item name="android:layout_height">wrap_content</item>
<item name="android:layout_gravity">center</item>
<item name="android:layout_marginTop">@dimen/answer_padding_start_24dp</item>
</style>
<style name="blue_line">
<item name="android:layout_width">match_parent</item>
<item name="android:layout_height">1dp</item>
<item name="android:layout_marginTop">@dimen/answer_padding_start_24dp</item>
<item name="android:background">#7CDAF2</item>
</style>
</resources>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment