Skip to content

Commit

Permalink
add title bar back in.
Browse files Browse the repository at this point in the history
  • Loading branch information
Robin Duda committed Dec 2, 2018
1 parent 46f69cb commit 35050b6
Show file tree
Hide file tree
Showing 11 changed files with 147 additions and 86 deletions.
36 changes: 20 additions & 16 deletions app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
@@ -1,26 +1,30 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.codingchili.mouse.enigma">
package="com.codingchili.mouse.enigma">

<uses-permission android:name="android.permission.USE_BIOMETRIC"/>
<uses-permission android:name="android.permission.INTERNET"/>
<uses-permission android:name="android.permission.USE_BIOMETRIC" />
<uses-permission android:name="android.permission.INTERNET" />

<uses-permission android:name="android.permission.CAMERA"/>
<uses-feature android:name="android.hardware.camera"/>
<uses-feature android:name="android.hardware.camera.autofocus"/>
<!--<uses-permission android:name="android.permission.CAMERA" />
<uses-feature android:name="android.hardware.camera" />
<uses-feature android:name="android.hardware.camera.autofocus" />-->

<application
android:allowBackup="true"
android:icon="@drawable/mouse"
android:label="@string/app_name"
android:roundIcon="@drawable/mouse"
android:supportsRtl="true"
android:theme="@style/MouseTheme">
<activity android:name=".MainActivity" android:screenOrientation="portrait">
android:allowBackup="true"
android:icon="@drawable/mouse"
android:label="@string/app_name"
android:roundIcon="@drawable/mouse"
android:supportsRtl="true"
android:theme="@style/MouseTheme">
<activity
android:name=".MainActivity"
android:screenOrientation="portrait">
<intent-filter>
<action android:name="android.intent.action.MAIN"/>
<action android:name="android.intent.action.VIEW"/>
<category android:name="android.intent.category.LAUNCHER"/>
<action android:name="android.intent.action.MAIN" />
<action android:name="android.intent.action.VIEW" />

<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
</application>
Expand Down
44 changes: 43 additions & 1 deletion app/src/main/res/layout/activity_main.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,50 @@
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:id="@+id/root"
android:id="@+id/panel"
android:background="@drawable/gradient"
tools:context=".MainActivity"
tools:layout_editor_absoluteY="81dp">

<RelativeLayout
android:id="@+id/header"
android:layout_width="match_parent"
android:layout_height="64dp"
android:elevation="4dp">

<TextView
android:id="@+id/app_title"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="32dp"
android:layout_marginTop="24dp"
android:text="@string/app_name"
android:textColor="@color/text"
android:textSize="14sp"/>


<TextView
android:id="@+id/app_version"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentTop="true"
android:layout_marginEnd="32dp"
android:layout_marginTop="24dp"
android:text="@string/app_version"
android:layout_alignParentEnd="true" />

</RelativeLayout>

<androidx.constraintlayout.widget.ConstraintLayout
android:id="@+id/root"
android:layout_width="0dp"
android:layout_height="0dp"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/header">

</androidx.constraintlayout.widget.ConstraintLayout>


</androidx.constraintlayout.widget.ConstraintLayout>
3 changes: 1 addition & 2 deletions app/src/main/res/layout/fragment_add_credential.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,7 @@
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@drawable/gradient">
android:layout_height="match_parent">

<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
Expand Down
3 changes: 1 addition & 2 deletions app/src/main/res/layout/fragment_application_info.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,7 @@
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:background="@drawable/gradient">
xmlns:app="http://schemas.android.com/apk/res-auto">

<ImageView
android:id="@+id/octocat"
Expand Down
7 changes: 3 additions & 4 deletions app/src/main/res/layout/fragment_application_settings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,10 @@
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@drawable/gradient">
android:layout_height="match_parent">

<RelativeLayout
android:id="@+id/container"
android:id="@+id/panel"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="64dp"
Expand Down Expand Up @@ -101,7 +100,7 @@
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_below="@+id/container"
android:layout_below="@+id/panel"
android:layout_marginTop="16dp"
android:layout_marginLeft="32dp"
android:layout_marginRight="32dp"
Expand Down
5 changes: 2 additions & 3 deletions app/src/main/res/layout/fragment_credential_info.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@drawable/gradient"
android:orientation="vertical">

<RelativeLayout
Expand Down Expand Up @@ -57,7 +56,7 @@
android:layout_height="wrap_content"
android:layout_alignParentStart="true"
android:layout_marginTop="64dp"
android:id="@+id/container"
android:id="@+id/panel"
android:visibility="visible">

<LinearLayout
Expand Down Expand Up @@ -102,7 +101,7 @@
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_below="@id/container"
android:layout_below="@id/panel"
android:layout_above="@id/bottom_app_bar_layout"
android:layout_marginBottom="-16dp">

Expand Down
5 changes: 2 additions & 3 deletions app/src/main/res/layout/fragment_credential_list.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,10 @@
<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/root"
android:id="@+id/panel"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context=".MainActivity"
android:background="@drawable/gradient">
tools:context=".MainActivity">

<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
Expand Down
3 changes: 1 addition & 2 deletions app/src/main/res/layout/fragment_import.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical" android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@drawable/gradient">
android:layout_height="match_parent">

</LinearLayout>
120 changes: 69 additions & 51 deletions app/src/main/res/layout/fragment_master_setup.xml
Original file line number Diff line number Diff line change
@@ -1,62 +1,80 @@
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:app="http://schemas.android.com/apk/res-auto"
android:background="@drawable/gradient"
android:layout_height="match_parent"
android:layout_width="match_parent"
android:windowSoftInputMode="adjustNothing"
xmlns:android="http://schemas.android.com/apk/res/android">

<RelativeLayout
<View
android:id="@+id/center"
android:layout_width="1dp"
android:layout_height="1dp"
android:layout_centerInParent="true"
android:layout_centerHorizontal="true"
android:layout_centerVertical="true"
android:visibility="invisible" />

<LinearLayout
android:id="@+id/container"
android:layout_width="wrap_content"
android:layout_height="192dp"
android:layout_alignParentStart="true"
android:layout_centerVertical="true">

<ImageView
android:id="@+id/fp_icon"
android:layout_width="48dp"
android:layout_height="48dp"
android:layout_below="@+id/master_password_header"
android:layout_centerHorizontal="true"
android:layout_marginTop="128dp"
android:scaleType="center"
app:srcCompat="@drawable/baseline_fingerprint_24" />

<TextView
android:id="@+id/master_password_header"
android:layout_height="wrap_content"
android:layout_alignBottom="@id/center"
android:layout_centerVertical="true"
android:layout_marginBottom="-64dp">

<RelativeLayout
android:id="@+id/panel"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentTop="true"
android:layout_centerHorizontal="true"
android:text="@string/master_password_header" />

<com.google.android.material.textfield.TextInputLayout
android:id="@+id/master_password_layout"
style="@style/Widget.MaterialComponents.TextInputLayout.OutlinedBox"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="12dp"
android:layout_marginTop="24dp"
android:layout_marginRight="12dp"
android:visibility="visible">

<com.google.android.material.textfield.TextInputEditText
android:id="@+id/master_password"
android:layout_height="192dp">

<ImageView
android:id="@+id/fp_icon"
android:layout_width="48dp"
android:layout_height="48dp"
android:layout_below="@+id/master_password_header"
android:layout_centerHorizontal="true"
android:layout_marginTop="128dp"
android:scaleType="center"
app:srcCompat="@drawable/baseline_fingerprint_24" />

<TextView
android:id="@+id/master_password_header"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentTop="true"
android:layout_centerHorizontal="true"
android:text="@string/master_password_header" />

<com.google.android.material.textfield.TextInputLayout
android:id="@+id/master_password_layout"
style="@style/Widget.MaterialComponents.TextInputLayout.OutlinedBox"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:hint="@string/master_password_hint"
android:inputType="textVisiblePassword" />
</com.google.android.material.textfield.TextInputLayout>

<TextView
android:id="@+id/fp_header"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_alignParentStart="true"
android:layout_alignParentBottom="true"
android:layout_marginStart="0dp"
android:layout_marginTop="32dp"
android:layout_marginBottom="64dp"
android:text="@string/master_scan_fp_text"
android:textAlignment="center" />
</RelativeLayout>
android:layout_marginLeft="12dp"
android:layout_marginTop="24dp"
android:layout_marginRight="12dp"
android:visibility="visible">

<com.google.android.material.textfield.TextInputEditText
android:id="@+id/master_password"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:hint="@string/master_password_hint"
android:inputType="textVisiblePassword" />
</com.google.android.material.textfield.TextInputLayout>

<TextView
android:id="@+id/fp_header"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_alignParentStart="true"
android:layout_alignParentBottom="true"
android:layout_marginStart="0dp"
android:layout_marginTop="32dp"
android:layout_marginBottom="64dp"
android:text="@string/master_scan_fp_text"
android:textAlignment="center" />
</RelativeLayout>
</LinearLayout>

</RelativeLayout>
2 changes: 2 additions & 0 deletions app/src/main/res/values/colors.xml
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,6 @@
<color name="password_weak">#d50000</color>
<color name="password_ok">#ffe100</color>
<color name="password_strong">#64dd17</color>

<color name="transparent">#00000000</color>
</resources>
5 changes: 3 additions & 2 deletions app/src/main/res/values/strings.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
<resources>
<string name="app_name">Mouse Enigma</string>
<string name="app_version">0.2.0</string>

<!-- navigation menu. -->
<string name="navigation_rate">Rate</string>
Expand Down Expand Up @@ -91,8 +92,8 @@
<string name="audit_fingerprint_authenticated">Authenticated using fingerprint.</string>
<string name="audit_password_authenticated">Authenticated using password.</string>
<string name="audit_security_list_update">Updated security lists.</string>
<string name="audit_displayed_password">Displayed password for %1$s@%2$s.</string>
<string name="audit_coped_password">Password clipboard copy %1$s@%2$s.</string>
<string name="audit_displayed_password">Display password: %1$s@%2$s.</string>
<string name="audit_coped_password">Password to clipboard: %1$s@%2$s.</string>
<string name="audit_added_credential">Added credential %1$s@%2$s.</string>
<string name="audit_removed_credential">Removed credential %1$s@%2$s.</string>

Expand Down

0 comments on commit 35050b6

Please sign in to comment.