mirror of
https://github.com/ClaytonWWilson/Listify.git
synced 2025-12-16 10:48:46 +00:00
Merge branch 'master' of https://github.com/ClaytonWWilson/Listify
This commit is contained in:
commit
d42013a07e
@ -6,6 +6,7 @@ import android.util.Log;
|
||||
import android.view.View;
|
||||
import android.widget.Button;
|
||||
import android.widget.EditText;
|
||||
import android.widget.TextView;
|
||||
|
||||
import com.example.listify.R;
|
||||
import static com.example.listify.MainActivity.am;
|
||||
@ -38,6 +39,8 @@ public class ForgotPasswordPage extends AppCompatActivity implements CodePage.Co
|
||||
}
|
||||
catch (Exception e) {
|
||||
Log.i("Authentication", e.toString());
|
||||
TextView invalidCred = findViewById(R.id.textView6);
|
||||
invalidCred.setText("Password criteria not met. Please try again.");
|
||||
}
|
||||
openDialog();
|
||||
}
|
||||
|
||||
@ -6,6 +6,7 @@ import android.util.Log;
|
||||
import android.view.View;
|
||||
import android.widget.Button;
|
||||
import android.widget.EditText;
|
||||
import android.widget.TextView;
|
||||
|
||||
import com.example.listify.R;
|
||||
import com.example.listify.AuthManager;
|
||||
@ -57,8 +58,10 @@ public class LoginPage extends AppCompatActivity {
|
||||
Intent intent = new Intent(LoginPage.this, MainActivity.class);
|
||||
startActivity(intent);
|
||||
}
|
||||
catch(Exception ex) {
|
||||
//Display "Incorrect email or password" message
|
||||
catch(Exception e) {
|
||||
Log.i("Authentication", e.toString());
|
||||
TextView invalidCred = findViewById(R.id.textView5);
|
||||
invalidCred.setText("Incorrect email or password. Please try again.");
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
@ -6,6 +6,7 @@ import android.util.Log;
|
||||
import android.view.View;
|
||||
import android.widget.Button;
|
||||
import android.widget.EditText;
|
||||
import android.widget.TextView;
|
||||
|
||||
import com.example.listify.R;
|
||||
import com.example.listify.AuthManager;
|
||||
@ -47,6 +48,8 @@ public class SignupPage extends AppCompatActivity implements CodePage.CodeDialog
|
||||
}
|
||||
catch (Exception e) {
|
||||
Log.i("Authentication", e.toString());
|
||||
TextView invalidCred = findViewById(R.id.textView3);
|
||||
invalidCred.setText("Invalid credentials. Please try again.");
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
@ -44,10 +44,10 @@ public class HomeFragment extends Fragment {
|
||||
toListPage.setOnClickListener(new View.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(View v) {
|
||||
Intent intent = new Intent(HomeFragment.this.getActivity(), com.example.listify.ListPage.class);
|
||||
startActivity(intent);
|
||||
//Intent intent = new Intent(HomeFragment.this.getActivity(), com.example.listify.ListPage.class);
|
||||
//startActivity(intent);
|
||||
|
||||
/*try {
|
||||
try {
|
||||
Properties configs = new Properties();
|
||||
try {
|
||||
configs = AuthManager.loadProperties(getContext(), "android.resource://" + getActivity().getPackageName() + "/raw/auths.json");
|
||||
@ -59,7 +59,7 @@ public class HomeFragment extends Fragment {
|
||||
}
|
||||
catch (Exception e) {
|
||||
Log.i("Authentication", e.toString());
|
||||
}*/
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
@ -9,10 +9,10 @@
|
||||
android:id="@+id/button1"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="27dp"
|
||||
android:text="Button"
|
||||
app:layout_constraintEnd_toEndOf="@+id/editTextTextPassword2"
|
||||
app:layout_constraintStart_toStartOf="@+id/editTextTextPassword2"
|
||||
android:layout_marginTop="52dp"
|
||||
android:text="Submit"
|
||||
app:layout_constraintEnd_toStartOf="@+id/textView6"
|
||||
app:layout_constraintStart_toStartOf="@+id/textView6"
|
||||
app:layout_constraintTop_toBottomOf="@+id/editTextTextPassword2" />
|
||||
|
||||
<EditText
|
||||
@ -23,8 +23,7 @@
|
||||
android:ems="10"
|
||||
android:hint="Email"
|
||||
android:inputType="textEmailAddress"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintStart_toStartOf="@+id/editTextTextPassword2"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<EditText
|
||||
@ -35,7 +34,8 @@
|
||||
android:ems="10"
|
||||
android:hint="New Password"
|
||||
android:inputType="textPassword"
|
||||
app:layout_constraintStart_toStartOf="@+id/editTextTextEmailAddress2"
|
||||
app:layout_constraintEnd_toStartOf="@+id/textView6"
|
||||
app:layout_constraintStart_toStartOf="@+id/textView6"
|
||||
app:layout_constraintTop_toBottomOf="@+id/editTextTextEmailAddress2" />
|
||||
|
||||
<TextView
|
||||
@ -47,4 +47,13 @@
|
||||
android:text="Please enter your email address."
|
||||
app:layout_constraintBottom_toTopOf="@+id/editTextTextEmailAddress2"
|
||||
app:layout_constraintEnd_toEndOf="@+id/editTextTextEmailAddress2" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/textView6"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text=""
|
||||
app:layout_constraintBottom_toTopOf="@+id/button1"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent" />
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
@ -12,8 +12,8 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="53dp"
|
||||
android:text="Log in"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintEnd_toStartOf="@+id/textView5"
|
||||
app:layout_constraintStart_toStartOf="@+id/textView5"
|
||||
app:layout_constraintTop_toBottomOf="@+id/button2" />
|
||||
|
||||
<Button
|
||||
@ -32,8 +32,8 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="72dp"
|
||||
android:text="Forgot password? Click here."
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintEnd_toStartOf="@+id/textView5"
|
||||
app:layout_constraintStart_toStartOf="@+id/textView5"
|
||||
app:layout_constraintTop_toBottomOf="@+id/editTextTextPersonName" />
|
||||
|
||||
<EditText
|
||||
@ -68,4 +68,13 @@
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/textView5"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text=""
|
||||
app:layout_constraintBottom_toTopOf="@+id/button3"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
@ -10,10 +10,10 @@
|
||||
android:id="@+id/button2"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="20dp"
|
||||
android:layout_marginTop="65dp"
|
||||
android:text="Sign up"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintEnd_toStartOf="@+id/textView3"
|
||||
app:layout_constraintStart_toStartOf="@+id/textView3"
|
||||
app:layout_constraintTop_toBottomOf="@+id/editTextTextPassword" />
|
||||
|
||||
<Button
|
||||
@ -21,7 +21,7 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="18dp"
|
||||
android:layout_marginTop="288dp"
|
||||
android:layout_marginTop="244dp"
|
||||
android:text="Already have an account? Click here to log in."
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
@ -30,7 +30,7 @@
|
||||
android:id="@+id/editTextTextPersonName"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="24dp"
|
||||
android:layout_marginTop="23dp"
|
||||
android:ems="10"
|
||||
android:hint="Username"
|
||||
android:inputType="textPersonName"
|
||||
@ -41,18 +41,19 @@
|
||||
android:id="@+id/editTextTextPassword"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="24dp"
|
||||
android:layout_marginEnd="1dp"
|
||||
android:layout_marginTop="26dp"
|
||||
android:ems="10"
|
||||
android:hint="Password"
|
||||
android:inputType="textPassword"
|
||||
app:layout_constraintStart_toStartOf="@+id/editTextTextPersonName"
|
||||
app:layout_constraintEnd_toEndOf="@+id/editTextTextPersonName"
|
||||
app:layout_constraintTop_toBottomOf="@+id/editTextTextPersonName" />
|
||||
|
||||
<EditText
|
||||
android:id="@+id/editTextTextEmailAddress"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="28dp"
|
||||
android:layout_marginTop="26dp"
|
||||
android:ems="10"
|
||||
android:hint="Email"
|
||||
android:inputType="textEmailAddress"
|
||||
@ -64,10 +65,19 @@
|
||||
android:id="@+id/textView"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginBottom="24dp"
|
||||
android:layout_marginBottom="17dp"
|
||||
android:text="Sign up"
|
||||
app:layout_constraintBottom_toTopOf="@+id/button1"
|
||||
app:layout_constraintEnd_toEndOf="@+id/button1"
|
||||
app:layout_constraintStart_toStartOf="@+id/button1" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/textView3"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text=""
|
||||
app:layout_constraintBottom_toTopOf="@+id/button2"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
Loading…
Reference in New Issue
Block a user