Registration process implemented

This commit is contained in:
Caesar2011
2017-03-26 14:43:59 +02:00
parent b9dddacbaa
commit 23073a8841
32 changed files with 1576 additions and 68 deletions

View File

@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:innerRadiusRatio="7"
android:shape="ring"
android:thickness="10dp" >
<solid android:color="@color/colorPrimaryDark" />
</shape>

View File

@@ -0,0 +1,22 @@
<?xml version="1.0" encoding="utf-8"?>
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
<item android:id="@android:id/background">
<shape>
<solid android:color="@color/colorPrimary" />
</shape>
</item>
<item android:id="@android:id/secondaryProgress">
<clip>
<shape>
<solid android:color="@color/colorPrimary" />
</shape>
</clip>
</item>
<item android:id="@android:id/progress">
<clip>
<shape>
<solid android:color="@color/colorPrimaryDark" />
</shape>
</clip>
</item>
</layer-list>

View File

@@ -0,0 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportHeight="24.0"
android:viewportWidth="24.0">
<path
android:fillColor="#FFFF"
android:pathData="M8 5v14l11-7z" />
</vector>

View File

@@ -21,7 +21,23 @@
</android.support.design.widget.AppBarLayout>
<include layout="@layout/content_main" />
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:id="@+id/relative_content"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:paddingBottom="@dimen/activity_vertical_margin"
android:paddingLeft="@dimen/activity_horizontal_margin"
android:paddingRight="@dimen/activity_horizontal_margin"
android:paddingTop="@dimen/activity_vertical_margin"
app:layout_behavior="@string/appbar_scrolling_view_behavior"
tools:context="de.hwr_berlin.it14.postgrachelor.MainActivity"
tools:showIn="@layout/app_bar_main">
</RelativeLayout>
<!--
<android.support.design.widget.FloatingActionButton
android:id="@+id/fab"
@@ -29,6 +45,6 @@
android:layout_height="wrap_content"
android:layout_gravity="bottom|end"
android:layout_margin="@dimen/fab_margin"
app:srcCompat="@android:drawable/ic_dialog_email" />
app:srcCompat="@android:drawable/ic_dialog_email" />-->
</android.support.design.widget.CoordinatorLayout>

View File

@@ -1,20 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:id="@+id/content_main"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:paddingBottom="@dimen/activity_vertical_margin"
android:paddingLeft="@dimen/activity_horizontal_margin"
android:paddingRight="@dimen/activity_horizontal_margin"
android:paddingTop="@dimen/activity_vertical_margin"
app:layout_behavior="@string/appbar_scrolling_view_behavior"
tools:context="de.hwr_berlin.it14.postgrachelor.MainActivity"
tools:showIn="@layout/app_bar_main">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Hello World!" />
</RelativeLayout>

View File

@@ -0,0 +1,53 @@
<?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:layout_width="match_parent"
android:layout_height="match_parent"
android:gravity="center"
android:scrollbarStyle="outsideOverlay"
tools:context="de.hwr_berlin.it14.postgrachelor.LoginFragment">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center"
android:paddingTop="50dp"
android:orientation="vertical">
<ImageView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:minHeight="100dp"
android:src="@mipmap/ic_launcher"
android:contentDescription="@string/launcher_icon"/>
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center"
android:paddingBottom="40dp"
android:textSize="40sp"
android:text="@string/app_name" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:gravity="center"
android:layout_margin="20dp"
android:text="@string/welcome_text" />
<EditText
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:padding="10dp"
android:layout_margin="10dp"
android:hint="@string/enter_user_name"
android:id="@+id/login_edit"
android:maxLines="1"
android:inputType="textFilter|textNoSuggestions"
android:background="@android:color/background_light" />
<Button
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:id="@+id/login_btn"
android:text="@string/register_btn"/>
</LinearLayout>
</ScrollView>

View File

@@ -0,0 +1,64 @@
<?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:layout_width="match_parent"
android:layout_height="match_parent"
android:scrollbarStyle="outsideOverlay"
tools:context="de.hwr_berlin.it14.postgrachelor.MainFragment">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical">
<include layout="@layout/fragment_main_status"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="@+id/fragment_main_status"/>
<android.support.v7.widget.GridLayout
xmlns:grid="http://schemas.android.com/apk/res-auto"
android:id="@+id/choice_grid"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:padding="4dp"
grid:alignmentMode="alignBounds"
grid:columnCount="2"
grid:rowOrderPreserved="false"
grid:useDefaultMargins="true">
<include layout="@layout/fragment_main_category"
android:layout_width="0dp"
android:layout_height="wrap_content"
grid:layout_columnWeight="1"
grid:layout_gravity="fill"
/>
<include layout="@layout/fragment_main_category"
android:layout_width="0dp"
android:layout_height="wrap_content"
grid:layout_columnWeight="1"
grid:layout_gravity="fill"
/>
<include layout="@layout/fragment_main_category"
android:layout_width="0dp"
android:layout_height="wrap_content"
grid:layout_columnWeight="1"
grid:layout_gravity="fill"
/>
<include layout="@layout/fragment_main_category"
android:layout_width="0dp"
android:layout_height="wrap_content"
grid:layout_columnWeight="1"
grid:layout_gravity="fill"
/>
</android.support.v7.widget.GridLayout>
</LinearLayout>
</ScrollView>

View File

@@ -0,0 +1,35 @@
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
tools:showIn="@layout/fragment_main"
android:layout_width="0dp"
android:layout_height="0dp"
android:gravity="start"
android:background="#FF33B5E6" >
<TextView
android:layout_width="wrap_content"
android:layout_height="100dp"
android:text="@string/hello_blank_fragment" />
<ProgressBar
style="@style/Widget.AppCompat.ProgressBar.Horizontal"
android:progressDrawable="@drawable/circular_progress_drawable_red"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_centerInParent="true"
android:paddingTop="10dp"
android:minHeight="70dp"
android:maxWidth="70dp"
android:indeterminate="false"
android:max="100"
android:progress="75"/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerInParent="true"
android:paddingTop="10dp"
android:textSize="15sp"
android:textStyle="bold"
android:textColor="@color/colorPrimary"
android:text="@string/_1337"/>
</RelativeLayout>

View File

@@ -0,0 +1,40 @@
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:showIn="@layout/fragment_main"
android:padding="5dp">
<ProgressBar
android:id="@+id/progressBar"
style="@style/Widget.AppCompat.ProgressBar.Horizontal"
android:progressDrawable="@drawable/horizontal_progress_drawable_red"
android:layout_width="match_parent"
android:layout_height="90dp"
android:indeterminate="false"
android:max="100"
android:minHeight="90dp"
android:maxHeight="90dp"
android:progress="20"/>
<TextView
android:id="@+id/fragment_user_name"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:textAppearance="@style/Base.TextAppearance.AppCompat.Title"
android:textColor="@android:color/white"
android:padding="10dp"
android:text="@string/hello_blank_fragment" />
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="end"
android:textAppearance="@style/Base.TextAppearance.AppCompat.Title"
android:textColor="@android:color/white"
android:padding="20dp"
android:textSize="55sp"
android:text="@string/_1337" />
</RelativeLayout>

View File

@@ -0,0 +1,61 @@
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context="de.hwr_berlin.it14.postgrachelor.QuestionFragment">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:gravity="center"
android:layout_margin="20dp"
android:textAppearance="@style/TextAppearance.AppCompat.Title"
android:text="@string/welcome_text" />
<Button
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="245sp"
android:height="75sp"
android:layout_alignParentBottom="true"
android:textAppearance="@style/TextAppearance.AppCompat.Small"
android:background="@color/colorPrimary"
android:textColor="@android:color/white"
android:text="@string/welcome_text"/>
<Button
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="165sp"
android:height="75sp"
android:layout_alignParentBottom="true"
android:textAppearance="@style/TextAppearance.AppCompat.Small"
android:background="@color/colorPrimary"
android:textColor="@android:color/white"
android:text="@string/welcome_text"/>
<Button
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="85sp"
android:height="75sp"
android:layout_alignParentBottom="true"
android:textAppearance="@style/TextAppearance.AppCompat.Small"
android:background="@color/colorPrimary"
android:textColor="@android:color/white"
android:text="@string/welcome_text"/>
<Button
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="5sp"
android:height="75sp"
android:paddingStart="10dp"
android:paddingEnd="10dp"
android:layout_alignParentBottom="true"
android:textAppearance="@style/TextAppearance.AppCompat.Small"
android:background="@color/colorPrimary"
android:textColor="@android:color/white"
android:text="@string/welcome_text"/>
</RelativeLayout>

View File

@@ -0,0 +1,33 @@
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context="de.hwr_berlin.it14.postgrachelor.QuestionEndFragment"
android:orientation="vertical"
android:gravity="center">
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center"
android:paddingBottom="40dp"
android:textSize="40sp"
android:text="@string/test_completed" />
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center"
android:paddingBottom="40dp"
android:textSize="80sp"
android:text="@string/_1337"
android:maxLines="1"
android:textColor="@color/colorPrimaryDark"
android:textStyle="bold"/>
<Button
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:background="@color/colorPrimary"
android:textColor="@android:color/white"
android:text="@string/return_btn"/>
</LinearLayout>

View File

@@ -0,0 +1,25 @@
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context="de.hwr_berlin.it14.postgrachelor.QuestionStartFragment"
android:orientation="vertical"
android:gravity="center">
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center"
android:paddingBottom="60dp"
android:textSize="40sp"
android:text="@string/start_test" />
<android.support.design.widget.FloatingActionButton
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_margin="16dp"
android:scaleX="2"
android:scaleY="2"
android:src="@drawable/ic_play_arrow" />
</LinearLayout>

View File

@@ -17,19 +17,22 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:paddingTop="@dimen/nav_header_vertical_spacing"
app:srcCompat="@android:drawable/sym_def_app_icon" />
android:contentDescription="@string/launcher_icon"
app:srcCompat="@mipmap/ic_launcher" />
<TextView
android:id="@+id/user_name"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingTop="@dimen/nav_header_vertical_spacing"
android:text="Android Studio"
android:textAppearance="@style/TextAppearance.AppCompat.Body1" />
android:text="@string/android_studio"
android:textAppearance="@style/TextAppearance.AppCompat.Body2" />
<TextView
android:id="@+id/textView"
android:id="@+id/user_uid"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="android.studio@android.com" />
android:textSize="12sp"
android:text="@string/android_studio_email" />
</LinearLayout>

View File

@@ -1,35 +1,38 @@
<?xml version="1.0" encoding="utf-8"?>
<menu xmlns:android="http://schemas.android.com/apk/res/android">
<menu xmlns:tools="http://schemas.android.com/tools"
xmlns:android="http://schemas.android.com/apk/res/android">
<group android:checkableBehavior="single">
<item
android:id="@+id/nav_camera"
android:icon="@drawable/ic_menu_camera"
android:title="Import" />
android:title="Login"
tools:ignore="HardcodedText" />
<item
android:id="@+id/nav_gallery"
android:icon="@drawable/ic_menu_gallery"
android:title="Gallery" />
android:title="Gallery"
tools:ignore="HardcodedText" />
<item
android:id="@+id/nav_slideshow"
android:icon="@drawable/ic_menu_slideshow"
android:title="Slideshow" />
android:title="Slideshow"
tools:ignore="HardcodedText" />
<item
android:id="@+id/nav_manage"
android:icon="@drawable/ic_menu_manage"
android:title="Tools" />
android:title="Tools"
tools:ignore="HardcodedText" />
</group>
<item android:title="Communicate">
<item android:title="Communicate"
tools:ignore="HardcodedText">
<menu>
<item
android:id="@+id/nav_share"
android:icon="@drawable/ic_menu_share"
android:title="Share" />
<item
android:id="@+id/nav_send"
android:icon="@drawable/ic_menu_send"
android:title="Send" />
android:title="Share"
tools:ignore="HardcodedText" />
</menu>
</item>

View File

@@ -5,4 +5,18 @@
<string name="navigation_drawer_close">Close navigation drawer</string>
<string name="action_settings">Settings</string>
<string name="enter_user_name">Enter User Name…</string>
<string name="hello_blank_fragment">Hello blank fragment</string>
<string name="hello_login_fragment">Hello login fragment</string>
<string name="welcome_text">Welcome to our stupid app. Prove that you are smarter than we are and answer our questions!</string>
<string name="register_btn">Register</string>
<string name="start_test">Start Test!</string>
<string name="test_completed">Test completed!</string>
<string name="_1337">1337</string>
<string name="return_btn">Return</string>
<string name="launcher_icon">Launcher Icon</string>
<string name="android_studio">Android Studio</string>
<string name="android_studio_email">android.studio@android.com</string>
</resources>