| @@ -0,0 +1,177 @@ | ||
| using System; | ||
| using System.Collections.Generic; | ||
| using System.Linq; | ||
| using System.Text; | ||
| using System.Globalization; | ||
| using System.Text.RegularExpressions; | ||
|
|
||
| using Android.App; | ||
| using Android.Content; | ||
| using Android.OS; | ||
| using Android.Runtime; | ||
| using Android.Views; | ||
| using Android.Widget; | ||
|
|
||
| using supAppCompat = Android.Support.V7.AppCompat; | ||
| using supToolbar = Android.Support.V7.Widget.Toolbar; | ||
| using supFAB = Android.Support.Design.Widget.FloatingActionButton; | ||
| using supDesign = Android.Support.Design; | ||
|
|
||
| namespace Amnesty | ||
| { | ||
| [Activity (Label = "Form_2")] | ||
| public class Form_2 : Activity | ||
| { | ||
| // MICROSOFT EMAIL VALIDATOR | ||
| bool invalid = false; | ||
|
|
||
| public bool IsValidEmail (EditText obj) | ||
| { | ||
| invalid = false; | ||
| String strIn = obj.EditableText.ToString(); | ||
|
|
||
| if (String.IsNullOrEmpty (strIn)) { | ||
| obj.Error = Resources.GetString (Resource.String.error_empty); | ||
| return false; | ||
| } | ||
| // Use IdnMapping class to convert Unicode domain names. | ||
| try { | ||
| strIn = Regex.Replace (strIn, @"(@)(.+)$", this.DomainMapper, | ||
| RegexOptions.None, TimeSpan.FromMilliseconds (200)); | ||
| } catch (RegexMatchTimeoutException) { | ||
| obj.Error = Resources.GetString(Resource.String.error_unknown); | ||
| return false; | ||
| } | ||
| if (invalid) { | ||
| obj.Error = Resources.GetString(Resource.String.error_format); | ||
| return false; | ||
| } | ||
| // Return true if strIn is in valid e-mail format. | ||
| try { | ||
| return Regex.IsMatch (strIn, | ||
| @"^(?("")("".+?(?<!\\)""@)|(([0-9a-z]((\.(?!\.))|[-!#\$%&'\*\+/=\?\^`\{\}\|~\w])*)(?<=[0-9a-z])@))" + | ||
| @"(?(\[)(\[(\d{1,3}\.){3}\d{1,3}\])|(([0-9a-z][-\w]*[0-9a-z]*\.)+[a-z0-9][\-a-z0-9]{0,22}[a-z0-9]))$", | ||
| RegexOptions.IgnoreCase, TimeSpan.FromMilliseconds (250)); | ||
| } catch (RegexMatchTimeoutException) { | ||
| obj.Error = Resources.GetString(Resource.String.error_unknown); | ||
| return false; | ||
| } | ||
| } | ||
|
|
||
| private string DomainMapper (Match match) | ||
| { | ||
| // IdnMapping class with default property values. | ||
| IdnMapping idn = new IdnMapping (); | ||
| string domainName = match.Groups [2].Value; | ||
| try { | ||
| domainName = idn.GetAscii (domainName); | ||
| } catch (ArgumentException) { | ||
| invalid = true; | ||
| } | ||
| return match.Groups [1].Value + domainName; | ||
| } | ||
| // END MICROSOFT EMAIL VALIDATOR | ||
|
|
||
| // Checks if there are any problems with any fields and enables the button to continue if there aren't | ||
| public Boolean Validate(EditText obj){ | ||
| if (String.IsNullOrWhiteSpace(obj.Text)) { | ||
| obj.Error = Resources.GetString(Resource.String.error_empty); | ||
| return false; | ||
| } else { | ||
| return true; | ||
| } | ||
| } | ||
|
|
||
| public void Activate(Button x, EditText a, EditText b, EditText c){ | ||
| if (Validate (a) && | ||
| IsValidEmail (b) && | ||
| Validate (c)) { | ||
| var next = FindViewById<Button> (Resource.Id.next); | ||
| next.Enabled = true; | ||
| next.SetBackgroundColor (Android.Graphics.Color.Rgb (255, 237, 0)); | ||
| next.SetTextColor (Android.Graphics.Color.Black); | ||
| } else if(x.Enabled) { | ||
| x.Enabled = false; | ||
| x.SetBackgroundColor (Android.Graphics.Color.Rgb (225, 225, 225)); | ||
| x.SetTextColor (Android.Graphics.Color.Rgb (175, 175, 175)); | ||
| } | ||
| } | ||
|
|
||
| protected override void OnCreate (Bundle bundle) | ||
| { | ||
| base.OnCreate (bundle); | ||
|
|
||
| // Create your application here | ||
| SetContentView (Resource.Layout.Form_2); | ||
|
|
||
| var toolbar = FindViewById<supToolbar> (Resource.Id.toolbar); // Toolbar | ||
| var next = FindViewById<Button> (Resource.Id.next); // Next Button | ||
| var telephone = FindViewById<EditText> (Resource.Id.telephone); // Telephone Field | ||
| var mail = FindViewById<EditText> (Resource.Id.mail); // Mail Field | ||
| var iban = FindViewById<EditText> (Resource.Id.iban); // Iban Field | ||
|
|
||
| // UI | ||
| // Toolbar | ||
| // Populate | ||
| toolbar.Title = Resources.GetString (Resource.String.app_name); | ||
| toolbar.SetLogo (Resource.Drawable.logo_black_trans_xs); | ||
|
|
||
| // Styling | ||
| toolbar.SetTitleTextColor (Android.Graphics.Color.Black); | ||
|
|
||
| // Button | ||
| // Disable button by default | ||
| next.Enabled = true; // DEBUG - switch to false | ||
| next.SetBackgroundColor (Android.Graphics.Color.Rgb (225, 225, 225)); | ||
| next.SetTextColor (Android.Graphics.Color.Rgb (175, 175, 175)); | ||
|
|
||
| // Next Button | ||
| next.Click += delegate { | ||
| var newIntent = new Intent (this, typeof(Form_3)); | ||
|
|
||
| newIntent.PutExtra ("strCharityCountry", Intent.GetStringExtra("strCharityCountry")); // IMPROV: Change to ID | ||
| newIntent.PutExtra ("strVolunteerName", Intent.GetStringExtra("strVolunteerName")); // IMPROV: Change to ID | ||
| newIntent.PutExtra ("strDonatorName", Intent.GetStringExtra("strDonatorName")); | ||
| newIntent.PutExtra ("strDonatorLastname", Intent.GetStringExtra("strDonatorLastname")); | ||
| newIntent.PutExtra ("strDonatorBirthdate", Intent.GetStringExtra("strDonatorBirthdate")); | ||
| newIntent.PutExtra ("strDonatorStreet", Intent.GetStringExtra("strDonatorStreet")); | ||
| newIntent.PutExtra ("strDonatorStreetNum", Intent.GetStringExtra("intDonatorStreetNum")); | ||
| newIntent.PutExtra ("strDonatorProvince", Intent.GetStringExtra("strDonatorProvince")); | ||
|
|
||
| newIntent.PutExtra ("strDonatorTel", telephone.EditableText.ToString()); | ||
| newIntent.PutExtra ("strDonatorMail", mail.EditableText.ToString()); | ||
| newIntent.PutExtra ("strDonatorIban", iban.EditableText.ToString()); | ||
|
|
||
| StartActivity (newIntent); | ||
| }; | ||
|
|
||
| // Telephone Field Validation | ||
| telephone.TextChanged += delegate { | ||
| Activate (next, telephone, mail, iban); | ||
| }; | ||
|
|
||
| telephone.FocusChange += delegate { | ||
| Activate (next, telephone, mail, iban); | ||
| }; | ||
|
|
||
| // Mail Field Validation | ||
| mail.TextChanged += delegate { | ||
| Activate (next, telephone, mail, iban); | ||
| }; | ||
|
|
||
| mail.FocusChange += delegate { | ||
| Activate (next, telephone, mail, iban); | ||
| }; | ||
|
|
||
| // Iban Field Validation | ||
| iban.TextChanged += delegate { | ||
| Activate (next, telephone, mail, iban); | ||
| }; | ||
|
|
||
| iban.FocusChange += delegate { | ||
| Activate (next, telephone, mail, iban); | ||
| }; | ||
| } | ||
| } | ||
| } | ||
|
|
| @@ -0,0 +1,104 @@ | ||
| using System; | ||
| using System.Collections.Generic; | ||
| using System.Linq; | ||
| using System.Text; | ||
|
|
||
| using Android.App; | ||
| using Android.Content; | ||
| using Android.OS; | ||
| using Android.Runtime; | ||
| using Android.Views; | ||
| using Android.Widget; | ||
|
|
||
| using supAppCompat = Android.Support.V7.AppCompat; | ||
| using supToolbar = Android.Support.V7.Widget.Toolbar; | ||
| using supFAB = Android.Support.Design.Widget.FloatingActionButton; | ||
| using supDesign = Android.Support.Design; | ||
|
|
||
| namespace Amnesty | ||
| { | ||
| [Activity (Label = "Form_3")] | ||
| public class Form_3 : Activity | ||
| { | ||
|
|
||
| // Checks if there are any problems with any fields and enables the button to continue if there aren't | ||
| public Boolean Validate(EditText obj){ | ||
| if (String.IsNullOrWhiteSpace(obj.Text)) { | ||
| obj.Error = Resources.GetString(Resource.String.error_empty); | ||
| return false; | ||
| } else { | ||
| return true; | ||
| } | ||
| } | ||
|
|
||
| public void Activate(Button x, EditText a){ | ||
| if (Validate (a)) { | ||
| var next = FindViewById<Button> (Resource.Id.next); | ||
| next.Enabled = true; | ||
| next.SetBackgroundColor (Android.Graphics.Color.Rgb (255, 237, 0)); | ||
| next.SetTextColor (Android.Graphics.Color.Black); | ||
| } else if(x.Enabled) { | ||
| x.Enabled = false; | ||
| x.SetBackgroundColor (Android.Graphics.Color.Rgb (225, 225, 225)); | ||
| x.SetTextColor (Android.Graphics.Color.Rgb (175, 175, 175)); | ||
| } | ||
| } | ||
|
|
||
| protected override void OnCreate (Bundle bundle) | ||
| { | ||
| base.OnCreate (bundle); | ||
|
|
||
| // Create your application here | ||
| SetContentView (Resource.Layout.Form_3); | ||
|
|
||
| var toolbar = FindViewById<supToolbar> (Resource.Id.toolbar); // Toolbar | ||
| var next = FindViewById<Button> (Resource.Id.next); // Next Button | ||
| var donation = FindViewById<EditText> (Resource.Id.donation); // Amount Field | ||
|
|
||
| // UI | ||
| // Toolbar | ||
| // Populate | ||
| toolbar.Title = Resources.GetString (Resource.String.app_name); | ||
| toolbar.SetLogo (Resource.Drawable.logo_black_trans_xs); | ||
|
|
||
| // Styling | ||
| toolbar.SetTitleTextColor (Android.Graphics.Color.Black); | ||
|
|
||
| // Button | ||
| // Disable button by default | ||
| next.Enabled = true; // DEBUG - switch to false | ||
| next.SetBackgroundColor (Android.Graphics.Color.Rgb (225, 225, 225)); | ||
| next.SetTextColor (Android.Graphics.Color.Rgb (175, 175, 175)); | ||
|
|
||
| // Next Button | ||
| next.Click += delegate { | ||
| var newIntent = new Intent (this, typeof(Form_4)); | ||
|
|
||
| newIntent.PutExtra ("strCharityCountry", Intent.GetStringExtra("strCharityCountry")); // IMPROV: Change to ID | ||
| newIntent.PutExtra ("strVolunteerName", Intent.GetStringExtra("strVolunteerName")); // IMPROV: Change to ID | ||
| newIntent.PutExtra ("strDonatorName", Intent.GetStringExtra("strDonatorName")); | ||
| newIntent.PutExtra ("strDonatorLastname", Intent.GetStringExtra("strDonatorLastname")); | ||
| newIntent.PutExtra ("strDonatorBirthdate", Intent.GetStringExtra("strDonatorBirthdate")); | ||
| newIntent.PutExtra ("strDonatorStreet", Intent.GetStringExtra("strDonatorStreet")); | ||
| newIntent.PutExtra ("strDonatorStreetNum", Intent.GetStringExtra("intDonatorStreetNum")); | ||
| newIntent.PutExtra ("strDonatorProvince", Intent.GetStringExtra("strDonatorProvince")); | ||
| newIntent.PutExtra ("strDonatorTel", Intent.GetStringExtra("strDonatorTel")); | ||
| newIntent.PutExtra ("strDonatorMail", Intent.GetStringExtra("strDonatorMail")); | ||
| newIntent.PutExtra ("strDonatorIban", Intent.GetStringExtra("strDonatorIban")); | ||
|
|
||
| newIntent.PutExtra ("strDonatorAmount", donation.EditableText.ToString()); | ||
|
|
||
| StartActivity (newIntent); | ||
| }; | ||
|
|
||
| // Birthdate Field Validation | ||
| donation.FocusChange += delegate { | ||
| Activate(next, donation); | ||
| }; | ||
| donation.TextChanged += delegate { | ||
| Activate(next, donation); | ||
| }; | ||
| } | ||
| } | ||
| } | ||
|
|
| @@ -0,0 +1,75 @@ | ||
|
|
||
| using System; | ||
| using System.Collections.Generic; | ||
| using System.Linq; | ||
| using System.Text; | ||
|
|
||
| using Android.App; | ||
| using Android.Content; | ||
| using Android.OS; | ||
| using Android.Runtime; | ||
| using Android.Views; | ||
| using Android.Widget; | ||
|
|
||
| using supAppCompat = Android.Support.V7.AppCompat; | ||
| using supToolbar = Android.Support.V7.Widget.Toolbar; | ||
| using supFAB = Android.Support.Design.Widget.FloatingActionButton; | ||
| using supDesign = Android.Support.Design; | ||
|
|
||
| namespace Amnesty | ||
| { | ||
| [Activity (Label = "Form_4")] | ||
| public class Form_4 : Activity | ||
| { | ||
| protected override void OnCreate (Bundle savedInstanceState) | ||
| { | ||
| base.OnCreate (savedInstanceState); | ||
|
|
||
| // Create your application here | ||
| SetContentView (Resource.Layout.Form_4); | ||
|
|
||
| var toolbar = FindViewById<supToolbar> (Resource.Id.toolbar); // Toolbar | ||
| var submit = FindViewById<Button> (Resource.Id.submit); | ||
| var p1 = FindViewById<TextView> (Resource.Id.overview_01); | ||
| var p2 = FindViewById<TextView> (Resource.Id.overview_02); | ||
| var p3 = FindViewById<TextView> (Resource.Id.overview_03); | ||
| var p4 = FindViewById<TextView> (Resource.Id.overview_04); | ||
| var p5 = FindViewById<TextView> (Resource.Id.overview_05); | ||
| var p6 = FindViewById<TextView> (Resource.Id.overview_06); | ||
| var p7 = FindViewById<TextView> (Resource.Id.overview_07); | ||
| var p8 = FindViewById<TextView> (Resource.Id.overview_08); | ||
| var p9 = FindViewById<TextView> (Resource.Id.overview_09); | ||
| var p10 = FindViewById<TextView> (Resource.Id.overview_10); | ||
|
|
||
| // UI | ||
| // Toolbar | ||
| // Populate | ||
| toolbar.Title = Resources.GetString (Resource.String.app_name); | ||
| toolbar.SetLogo (Resource.Drawable.logo_black_trans_xs); | ||
|
|
||
| // Styling | ||
| toolbar.SetTitleTextColor (Android.Graphics.Color.Black); | ||
|
|
||
| // Content | ||
| // Populate | ||
| p1.Text = p1.Text + Intent.GetStringExtra("strVolunteerName"); | ||
| p2.Text = p2.Text + Intent.GetStringExtra("strCharityCountry"); | ||
| p3.Text = p3.Text + Intent.GetStringExtra("strDonatorName") + " " + Intent.GetStringExtra("strDonatorLastname"); | ||
| p4.Text = p4.Text + Intent.GetStringExtra("strDonatorBirthdate"); | ||
| p5.Text = p5.Text + Intent.GetStringExtra("strDonatorStreet") + " " + Intent.GetStringExtra("strDonatorStreetNum"); | ||
| p6.Text = p6.Text + Intent.GetStringExtra("strDonatorProvince"); | ||
| p7.Text = p7.Text + Intent.GetStringExtra("strDonatorTel"); | ||
| p8.Text = p8.Text + Intent.GetStringExtra("strDonatorMail"); | ||
| p9.Text = p9.Text + Intent.GetStringExtra("strDonatorIban"); | ||
| p10.Text = p10.Text + Intent.GetStringExtra("strDonatorAmount"); | ||
|
|
||
| // Submit - Click | ||
| submit.Click += delegate { | ||
| var newIntent = new Intent (this, typeof(Landing)); | ||
| newIntent.PutExtra ("strVolunteerName", Intent.GetStringExtra("strVolunteerName")); | ||
| StartActivity (newIntent); | ||
| }; | ||
| } | ||
| } | ||
| } | ||
|
|
| @@ -0,0 +1,142 @@ | ||
| <?xml version="1.0" encoding="utf-8"?> | ||
| <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" | ||
| xmlns:local="http://schemas.android.com/apk/res-auto" | ||
| android:layout_width="fill_parent" | ||
| android:layout_height="wrap_content" | ||
| android:id="@+id/container" | ||
| android:focusable="true" | ||
| android:focusableInTouchMode="true"> | ||
| <include | ||
| android:id="@+id/toolbar" | ||
| layout="@layout/toolbar" /> | ||
| <ScrollView | ||
| android:layout_width="fill_parent" | ||
| android:layout_height="wrap_content" | ||
| android:layout_below="@id/toolbar" | ||
| android:orientation="vertical"> | ||
| <LinearLayout | ||
| android:orientation="vertical" | ||
| android:layout_width="match_parent" | ||
| android:layout_height="wrap_content" | ||
| android:layout_gravity="center_horizontal" | ||
| android:id="@+id/main_content" | ||
| android:padding="50px"> | ||
| <TextView | ||
| android:text="@string/form_intro" | ||
| android:layout_width="match_parent" | ||
| android:layout_height="wrap_content" | ||
| android:id="@+id/intro" /> | ||
| <TextView | ||
| android:text="@string/form_personal" | ||
| android:layout_width="match_parent" | ||
| android:layout_height="wrap_content" | ||
| android:id="@+id/personal" | ||
| android:layout_marginTop="10dp" /> | ||
| <android.support.design.widget.TextInputLayout | ||
| android:layout_width="match_parent" | ||
| android:layout_height="wrap_content" | ||
| android:theme="@style/MyTheme" | ||
| android:layout_marginTop="10dp" | ||
| android:layout_marginLeft="-5dp" | ||
| android:layout_marginRight="-5dp"> | ||
| <EditText | ||
| android:id="@+id/name" | ||
| android:layout_width="fill_parent" | ||
| android:layout_height="wrap_content" | ||
| android:hint="@string/form_name" | ||
| android:singleLine="true" | ||
| android:inputType="textCapSentences" /> | ||
| </android.support.design.widget.TextInputLayout> | ||
| <android.support.design.widget.TextInputLayout | ||
| android:layout_width="match_parent" | ||
| android:layout_height="wrap_content" | ||
| android:theme="@style/MyTheme" | ||
| android:layout_marginTop="10dp" | ||
| android:layout_marginLeft="-5dp" | ||
| android:layout_marginRight="-5dp"> | ||
| <EditText | ||
| android:id="@+id/lastname" | ||
| android:layout_width="fill_parent" | ||
| android:layout_height="wrap_content" | ||
| android:hint="@string/form_lastname" | ||
| android:singleLine="true" | ||
| android:inputType="textCapSentences" /> | ||
| </android.support.design.widget.TextInputLayout> | ||
| <android.support.design.widget.TextInputLayout | ||
| android:layout_width="match_parent" | ||
| android:layout_height="wrap_content" | ||
| android:theme="@style/MyTheme" | ||
| android:layout_marginTop="10dp" | ||
| android:layout_marginLeft="-5dp" | ||
| android:layout_marginRight="-5dp" | ||
| android:windowSoftInputMode="stateHidden"> | ||
| <EditText | ||
| android:id="@+id/birthdate" | ||
| android:layout_width="fill_parent" | ||
| android:layout_height="wrap_content" | ||
| android:hint="@string/form_birthdate" | ||
| android:singleLine="true" | ||
| android:editable="false" | ||
| android:windowSoftInputMode="stateAlwaysHidden" /> | ||
| </android.support.design.widget.TextInputLayout> | ||
| <LinearLayout | ||
| android:orientation="horizontal" | ||
| android:layout_width="match_parent" | ||
| android:layout_height="wrap_content" | ||
| android:layout_marginTop="10dp" | ||
| android:layout_gravity="center_horizontal"> | ||
| <android.support.design.widget.TextInputLayout | ||
| android:layout_width="wrap_content" | ||
| android:layout_height="wrap_content" | ||
| android:layout_weight=".80" | ||
| android:theme="@style/MyTheme" | ||
| android:layout_marginLeft="-5dp"> | ||
| <EditText | ||
| android:id="@+id/street" | ||
| android:layout_width="fill_parent" | ||
| android:layout_height="wrap_content" | ||
| android:hint="@string/form_street" | ||
| android:singleLine="true" | ||
| android:inputType="textCapSentences" /> | ||
| </android.support.design.widget.TextInputLayout> | ||
| <android.support.design.widget.TextInputLayout | ||
| android:layout_width="wrap_content" | ||
| android:layout_height="wrap_content" | ||
| android:layout_weight=".20" | ||
| android:theme="@style/MyTheme" | ||
| android:layout_marginRight="-5dp"> | ||
| <EditText | ||
| android:id="@+id/streetNum" | ||
| android:layout_width="fill_parent" | ||
| android:layout_height="wrap_content" | ||
| android:hint="@string/form_number" | ||
| android:singleLine="true" | ||
| android:inputType="number" /> | ||
| </android.support.design.widget.TextInputLayout> | ||
| </LinearLayout> | ||
| <android.support.design.widget.TextInputLayout | ||
| android:layout_width="match_parent" | ||
| android:layout_height="wrap_content" | ||
| android:theme="@style/MyTheme" | ||
| android:layout_marginTop="10dp" | ||
| android:layout_marginLeft="-5dp" | ||
| android:layout_marginRight="-5dp"> | ||
| <AutoCompleteTextView | ||
| android:layout_width="fill_parent" | ||
| android:layout_height="wrap_content" | ||
| android:id="@+id/province" | ||
| android:hint="@string/form_province" | ||
| android:singleLine="true" /> | ||
| </android.support.design.widget.TextInputLayout> | ||
| <Button | ||
| android:id="@+id/next" | ||
| android:layout_width="wrap_content" | ||
| android:layout_height="wrap_content" | ||
| android:layout_marginTop="15dp" | ||
| style="?android:attr/borderlessButtonStyle" | ||
| android:textColor="#ff000000" | ||
| android:text="@string/generic_next" | ||
| android:background="#ffffff00" /> | ||
| </LinearLayout> | ||
| </ScrollView> | ||
| </RelativeLayout> |
| @@ -0,0 +1,68 @@ | ||
| <?xml version="1.0" encoding="utf-8"?> | ||
| <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" | ||
| xmlns:local="http://schemas.android.com/apk/res-auto" | ||
| android:layout_width="fill_parent" | ||
| android:layout_height="wrap_content" | ||
| android:id="@+id/container" | ||
| android:focusable="true" | ||
| android:focusableInTouchMode="true"> | ||
| <include | ||
| android:id="@+id/toolbar" | ||
| layout="@layout/toolbar" /> | ||
| <ScrollView | ||
| android:layout_width="fill_parent" | ||
| android:layout_height="wrap_content" | ||
| android:layout_below="@id/toolbar" | ||
| android:orientation="vertical"> | ||
| <LinearLayout | ||
| android:orientation="vertical" | ||
| android:layout_width="match_parent" | ||
| android:layout_height="wrap_content" | ||
| android:layout_gravity="center_horizontal" | ||
| android:id="@+id/main_content" | ||
| android:padding="50px"> | ||
| <TextView | ||
| android:text="@string/form_intro" | ||
| android:layout_width="match_parent" | ||
| android:layout_height="wrap_content" | ||
| android:id="@+id/intro" /> | ||
| <TextView | ||
| android:text="@string/form_amount" | ||
| android:layout_width="match_parent" | ||
| android:layout_height="wrap_content" | ||
| android:id="@+id/amount" | ||
| android:layout_marginTop="10dp" /> | ||
| <android.support.design.widget.TextInputLayout | ||
| android:layout_width="match_parent" | ||
| android:layout_height="wrap_content" | ||
| android:theme="@style/MyTheme" | ||
| android:layout_marginTop="10dp" | ||
| android:layout_marginLeft="-5dp" | ||
| android:layout_marginRight="-5dp"> | ||
| <EditText | ||
| android:id="@+id/donation" | ||
| android:layout_width="fill_parent" | ||
| android:layout_height="wrap_content" | ||
| android:hint="@string/form_donation" | ||
| android:singleLine="true" | ||
| android:inputType="numberDecimal" /> | ||
| </android.support.design.widget.TextInputLayout> | ||
| <TextView | ||
| android:text="@string/instructions_donation" | ||
| android:layout_width="match_parent" | ||
| android:layout_height="wrap_content" | ||
| android:layout_marginTop="-5dp" | ||
| android:id="@+id/instructions_donation" | ||
| android:textAppearance="?android:attr/textAppearanceSmall" /> | ||
| <Button | ||
| android:id="@+id/next" | ||
| android:layout_width="wrap_content" | ||
| android:layout_height="wrap_content" | ||
| android:layout_marginTop="15dp" | ||
| style="?android:attr/borderlessButtonStyle" | ||
| android:textColor="#ff000000" | ||
| android:text="@string/generic_next" | ||
| android:background="#ffffff00" /> | ||
| </LinearLayout> | ||
| </ScrollView> | ||
| </RelativeLayout> |
| @@ -0,0 +1,107 @@ | ||
| <?xml version="1.0" encoding="utf-8"?> | ||
| <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" | ||
| xmlns:local="http://schemas.android.com/apk/res-auto" | ||
| android:layout_width="fill_parent" | ||
| android:layout_height="wrap_content" | ||
| android:id="@+id/container" | ||
| android:focusable="true" | ||
| android:focusableInTouchMode="true"> | ||
| <include | ||
| android:id="@+id/toolbar" | ||
| layout="@layout/toolbar" /> | ||
| <ScrollView | ||
| android:layout_width="fill_parent" | ||
| android:layout_height="wrap_content" | ||
| android:layout_below="@id/toolbar" | ||
| android:orientation="vertical"> | ||
| <LinearLayout | ||
| android:orientation="vertical" | ||
| android:layout_width="match_parent" | ||
| android:layout_height="wrap_content" | ||
| android:layout_gravity="center_horizontal" | ||
| android:id="@+id/main_content" | ||
| android:padding="50px"> | ||
| <TextView | ||
| android:text="@string/form_intro" | ||
| android:layout_width="match_parent" | ||
| android:layout_height="wrap_content" | ||
| android:id="@+id/intro" /> | ||
| <TextView | ||
| android:text="@string/form_overview" | ||
| android:layout_width="match_parent" | ||
| android:layout_height="wrap_content" | ||
| android:id="@+id/overview" | ||
| android:layout_marginTop="10dp" /> | ||
| <TextView | ||
| android:id="@+id/overview_01" | ||
| android:text="Volunteer: " | ||
| android:layout_width="match_parent" | ||
| android:layout_height="wrap_content" | ||
| android:layout_marginTop="10dp" /> | ||
| <TextView | ||
| android:id="@+id/overview_02" | ||
| android:text="Charity: " | ||
| android:layout_width="match_parent" | ||
| android:layout_height="wrap_content" | ||
| android:layout_marginTop="10dp" /> | ||
| <TextView | ||
| android:id="@+id/overview_03" | ||
| android:text="Name: " | ||
| android:layout_width="match_parent" | ||
| android:layout_height="wrap_content" | ||
| android:layout_marginTop="10dp" /> | ||
| <TextView | ||
| android:id="@+id/overview_04" | ||
| android:text="Birthdate: " | ||
| android:layout_width="match_parent" | ||
| android:layout_height="wrap_content" | ||
| android:layout_marginTop="10dp" /> | ||
| <TextView | ||
| android:id="@+id/overview_05" | ||
| android:text="Adress: " | ||
| android:layout_width="match_parent" | ||
| android:layout_height="wrap_content" | ||
| android:layout_marginTop="10dp" /> | ||
| <TextView | ||
| android:id="@+id/overview_06" | ||
| android:text="Province: " | ||
| android:layout_width="match_parent" | ||
| android:layout_height="wrap_content" | ||
| android:layout_marginTop="10dp" /> | ||
| <TextView | ||
| android:id="@+id/overview_07" | ||
| android:text="Telephone Number: " | ||
| android:layout_width="match_parent" | ||
| android:layout_height="wrap_content" | ||
| android:layout_marginTop="10dp" /> | ||
| <TextView | ||
| android:id="@+id/overview_08" | ||
| android:text="E-mail: " | ||
| android:layout_width="match_parent" | ||
| android:layout_height="wrap_content" | ||
| android:layout_marginTop="10dp" /> | ||
| <TextView | ||
| android:id="@+id/overview_09" | ||
| android:text="IBAN: " | ||
| android:layout_width="match_parent" | ||
| android:layout_height="wrap_content" | ||
| android:layout_marginTop="10dp" /> | ||
| <TextView | ||
| android:id="@+id/overview_10" | ||
| android:text="Amount: " | ||
| android:layout_width="match_parent" | ||
| android:layout_height="wrap_content" | ||
| android:layout_marginTop="10dp" /> | ||
| <Button | ||
| android:id="@+id/submit" | ||
| android:layout_width="wrap_content" | ||
| android:layout_height="wrap_content" | ||
| android:layout_marginTop="15dp" | ||
| android:layout_marginRight="15dp" | ||
| style="?android:attr/borderlessButtonStyle" | ||
| android:textColor="#ff000000" | ||
| android:text="@string/generic_donate" | ||
| android:background="#ffffff00" /> | ||
| </LinearLayout> | ||
| </ScrollView> | ||
| </RelativeLayout> |