Add button to toggle passphrase visibility

closes #3776
// FREEBIE
This commit is contained in:
Carlin
2015-07-24 03:16:45 +12:00
committed by Moxie Marlinspike
parent 5a29c61dac
commit 927aac2c4a
20 changed files with 81 additions and 3 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 366 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 560 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 528 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 472 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 250 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 387 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 356 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 310 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 458 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 706 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 652 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 581 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 650 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1019 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 919 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 846 B

View File

@@ -32,7 +32,40 @@
android:layout_marginRight="50dp"
android:singleLine="true"
android:paddingLeft="10dp"
android:paddingRight="10dp"/>
android:paddingRight="40dp"/>
<org.thoughtcrime.securesms.components.AnimatingToggle
android:id="@+id/button_toggle"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignRight="@+id/passphrase_edit"
android:layout_centerVertical="true"
android:layout_gravity="center"
android:gravity="center">
<ImageButton android:id="@+id/passphrase_visibility"
android:src="?ic_visibility"
android:background="@drawable/touch_highlight_background"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:paddingLeft="8dp"
android:paddingRight="8dp"
android:paddingTop="3dp"
android:paddingBottom="3dp"
android:layout_centerVertical="true" />
<ImageButton android:id="@+id/passphrase_visibility_off"
android:src="?ic_visibility_off"
android:background="@drawable/touch_highlight_background"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:paddingLeft="8dp"
android:paddingRight="8dp"
android:paddingTop="3dp"
android:paddingBottom="3dp"
android:layout_centerVertical="true" />
</org.thoughtcrime.securesms.components.AnimatingToggle>
<ImageButton android:id="@+id/ok_button"
android:src="?ic_arrow_forward"

View File

@@ -23,6 +23,8 @@
<attr name="centered_app_title_color" format="reference|color" />
<attr name="ic_arrow_forward" format="reference" />
<attr name="ic_visibility" format="reference" />
<attr name="ic_visibility_off" format="reference" />
<attr name="conversation_background" format="reference|color"/>
<attr name="conversation_editor_background" format="reference|color"/>

View File

@@ -46,6 +46,8 @@
<item name="centered_app_title_color">#55000000</item>
<item name="ic_arrow_forward">@drawable/ic_arrow_forward_light</item>
<item name="lockscreen_watermark">@drawable/lockscreen_watermark_light</item>
<item name="ic_visibility">@drawable/ic_visibility_grey600_24dp</item>
<item name="ic_visibility_off">@drawable/ic_visibility_off_grey600_24dp</item>
</style>
<style name="TextSecure.DarkIntroTheme" parent="@style/Theme.AppCompat">
@@ -57,6 +59,8 @@
<item name="ic_arrow_forward">@drawable/ic_arrow_forward_dark</item>
<item name="lockscreen_watermark">@drawable/lockscreen_watermark_dark</item>
<item name="android:windowBackground">@color/black</item>
<item name="ic_visibility">@drawable/ic_visibility_white_24dp</item>
<item name="ic_visibility_off">@drawable/ic_visibility_off_white_24dp</item>
</style>
<style name="PopupAnimation" parent="@android:style/Animation">