UI touch-ups

This commit is contained in:
pokkst 2022-10-04 04:19:48 -05:00
parent 186b63044a
commit 5545d8c6d0
No known key found for this signature in database
GPG Key ID: 90C2ED85E67A50FF
13 changed files with 50 additions and 25 deletions

View File

@ -15,13 +15,13 @@ import com.google.android.material.bottomsheet.BottomSheetDialogFragment;
import net.mynero.wallet.R; import net.mynero.wallet.R;
import net.mynero.wallet.util.Helper; import net.mynero.wallet.util.Helper;
public class InformationBottomSheetDialog extends BottomSheetDialogFragment { public class WalletKeysBottomSheetDialog extends BottomSheetDialogFragment {
public boolean showCopyButton = false; public boolean showCopyButton = false;
public String information = ""; public String information = "";
@Override @Override
public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) { public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
return inflater.inflate(R.layout.information_bottom_sheet_dialog, null); return inflater.inflate(R.layout.wallet_keys_bottom_sheet_dialog, null);
} }
@Override @Override

View File

@ -27,7 +27,7 @@ import net.mynero.wallet.R;
import net.mynero.wallet.data.DefaultNodes; import net.mynero.wallet.data.DefaultNodes;
import net.mynero.wallet.data.Node; import net.mynero.wallet.data.Node;
import net.mynero.wallet.fragment.dialog.AddNodeBottomSheetDialog; import net.mynero.wallet.fragment.dialog.AddNodeBottomSheetDialog;
import net.mynero.wallet.fragment.dialog.InformationBottomSheetDialog; import net.mynero.wallet.fragment.dialog.WalletKeysBottomSheetDialog;
import net.mynero.wallet.fragment.dialog.NodeSelectionBottomSheetDialog; import net.mynero.wallet.fragment.dialog.NodeSelectionBottomSheetDialog;
import net.mynero.wallet.fragment.dialog.PasswordBottomSheetDialog; import net.mynero.wallet.fragment.dialog.PasswordBottomSheetDialog;
import net.mynero.wallet.model.Wallet; import net.mynero.wallet.model.Wallet;
@ -38,9 +38,6 @@ import net.mynero.wallet.util.Constants;
import net.mynero.wallet.util.DayNightMode; import net.mynero.wallet.util.DayNightMode;
import net.mynero.wallet.util.NightmodeHelper; import net.mynero.wallet.util.NightmodeHelper;
import java.util.concurrent.ExecutorService;
import java.util.concurrent.Executors;
public class SettingsFragment extends Fragment implements PasswordBottomSheetDialog.PasswordListener, NodeSelectionBottomSheetDialog.NodeSelectionDialogListener, AddNodeBottomSheetDialog.AddNodeListener { public class SettingsFragment extends Fragment implements PasswordBottomSheetDialog.PasswordListener, NodeSelectionBottomSheetDialog.NodeSelectionDialogListener, AddNodeBottomSheetDialog.AddNodeListener {
private SettingsViewModel mViewModel; private SettingsViewModel mViewModel;
@ -184,7 +181,7 @@ public class SettingsFragment extends Fragment implements PasswordBottomSheetDia
} }
private void displaySeedDialog() { private void displaySeedDialog() {
InformationBottomSheetDialog informationDialog = new InformationBottomSheetDialog(); WalletKeysBottomSheetDialog informationDialog = new WalletKeysBottomSheetDialog();
informationDialog.showCopyButton = false; informationDialog.showCopyButton = false;
informationDialog.information = WalletManager.getInstance().getWallet().getSeed(""); informationDialog.information = WalletManager.getInstance().getWallet().getSeed("");
informationDialog.show(getActivity().getSupportFragmentManager(), "information_seed_dialog"); informationDialog.show(getActivity().getSupportFragmentManager(), "information_seed_dialog");

View File

@ -5,5 +5,5 @@
android:left="8dp" android:left="8dp"
android:right="8dp" /> android:right="8dp" />
<solid android:color="@color/button_disabled_bg_color" /> <solid android:color="@color/button_disabled_bg_color" />
<corners android:radius="16dp" /> <corners android:radius="64dp" />
</shape> </shape>

View File

@ -5,6 +5,6 @@
android:left="8dp" android:left="8dp"
android:right="8dp" /> android:right="8dp" />
<solid android:color="@color/button_disabled_bg_color" /> <solid android:color="@color/button_disabled_bg_color" />
<corners android:topLeftRadius="16dp" <corners android:topLeftRadius="64dp"
android:bottomLeftRadius="16dp"/> android:bottomLeftRadius="64dp"/>
</shape> </shape>

View File

@ -5,6 +5,6 @@
android:left="8dp" android:left="8dp"
android:right="8dp" /> android:right="8dp" />
<solid android:color="@color/button_disabled_bg_color" /> <solid android:color="@color/button_disabled_bg_color" />
<corners android:topRightRadius="16dp" <corners android:topRightRadius="64dp"
android:bottomRightRadius="16dp"/> android:bottomRightRadius="64dp"/>
</shape> </shape>

View File

@ -5,5 +5,5 @@
android:left="8dp" android:left="8dp"
android:right="8dp" /> android:right="8dp" />
<solid android:color="@color/oled_colorSecondary" /> <solid android:color="@color/oled_colorSecondary" />
<corners android:radius="16dp" /> <corners android:radius="64dp" />
</shape> </shape>

View File

@ -5,6 +5,6 @@
android:left="8dp" android:left="8dp"
android:right="8dp" /> android:right="8dp" />
<solid android:color="@color/oled_colorSecondary" /> <solid android:color="@color/oled_colorSecondary" />
<corners android:topLeftRadius="16dp" <corners android:topLeftRadius="64dp"
android:bottomLeftRadius="16dp"/> android:bottomLeftRadius="64dp"/>
</shape> </shape>

View File

@ -5,6 +5,6 @@
android:left="8dp" android:left="8dp"
android:right="8dp" /> android:right="8dp" />
<solid android:color="@color/oled_colorSecondary" /> <solid android:color="@color/oled_colorSecondary" />
<corners android:topRightRadius="16dp" <corners android:topRightRadius="64dp"
android:bottomRightRadius="16dp"/> android:bottomRightRadius="64dp"/>
</shape> </shape>

View File

@ -110,6 +110,7 @@
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:background="@drawable/button_bg_left" android:background="@drawable/button_bg_left"
android:text="@string/receive" android:text="@string/receive"
android:layout_marginEnd="1dp"
android:layout_marginBottom="16dp" android:layout_marginBottom="16dp"
android:layout_marginStart="24dp" android:layout_marginStart="24dp"
app:layout_constraintBottom_toBottomOf="parent" app:layout_constraintBottom_toBottomOf="parent"
@ -122,6 +123,7 @@
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:background="@drawable/button_bg_right" android:background="@drawable/button_bg_right"
android:text="@string/send" android:text="@string/send"
android:layout_marginStart="1dp"
android:layout_marginBottom="16dp" android:layout_marginBottom="16dp"
android:layout_marginEnd="24dp" android:layout_marginEnd="24dp"
app:layout_constraintBottom_toBottomOf="parent" app:layout_constraintBottom_toBottomOf="parent"

View File

@ -108,6 +108,7 @@
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginTop="16dp" android:layout_marginTop="16dp"
android:layout_marginEnd="24dp" android:layout_marginEnd="24dp"
android:minHeight="48dp"
app:layout_constraintEnd_toEndOf="parent" app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toBottomOf="@id/appearance_settings_textview" /> app:layout_constraintTop_toBottomOf="@id/appearance_settings_textview" />
@ -129,16 +130,20 @@
android:id="@+id/select_node_button" android:id="@+id/select_node_button"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginStart="24dp"
android:layout_marginTop="16dp" android:layout_marginTop="16dp"
android:layout_marginEnd="24dp" android:layout_marginEnd="24dp"
android:layout_marginStart="24dp" android:paddingStart="16dp"
android:singleLine="true" android:paddingEnd="16dp"
android:ellipsize="middle" tools:text="aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
android:background="@drawable/button_bg" android:background="@drawable/button_bg"
android:ellipsize="middle"
android:singleLine="true"
app:layout_constraintEnd_toEndOf="parent" app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.0" app:layout_constraintHorizontal_bias="0.0"
app:layout_constraintStart_toStartOf="parent" app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/network_settings_textview" /> app:layout_constraintTop_toBottomOf="@id/network_settings_textview"
tools:ignore="SpeakableTextPresentCheck" />
<TextView <TextView
android:id="@+id/tor_textview" android:id="@+id/tor_textview"
@ -158,6 +163,7 @@
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginTop="16dp" android:layout_marginTop="16dp"
android:layout_marginEnd="24dp" android:layout_marginEnd="24dp"
android:minHeight="48dp"
app:layout_constraintEnd_toEndOf="parent" app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toBottomOf="@id/select_node_button" /> app:layout_constraintTop_toBottomOf="@id/select_node_button" />

View File

@ -4,7 +4,6 @@
xmlns:tools="http://schemas.android.com/tools" xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="match_parent"
android:padding="24dp"
tools:context="net.mynero.wallet.fragment.home.HomeFragment"> tools:context="net.mynero.wallet.fragment.home.HomeFragment">
<TextView <TextView
@ -14,6 +13,9 @@
android:text="@string/view_utxos" android:text="@string/view_utxos"
android:textSize="32sp" android:textSize="32sp"
android:textStyle="bold" android:textStyle="bold"
android:layout_marginTop="24dp"
android:layout_marginStart="24dp"
android:layout_marginEnd="24dp"
app:layout_constraintEnd_toEndOf="parent" app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent" app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" /> app:layout_constraintTop_toTopOf="parent" />
@ -23,6 +25,8 @@
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="0dp" android:layout_height="0dp"
android:layout_marginTop="16dp" android:layout_marginTop="16dp"
android:layout_marginStart="24dp"
android:layout_marginEnd="24dp"
android:clipToPadding="false" android:clipToPadding="false"
android:paddingBottom="128dp" android:paddingBottom="128dp"
app:layout_constraintBottom_toBottomOf="parent" app:layout_constraintBottom_toBottomOf="parent"
@ -37,6 +41,8 @@
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:background="@drawable/button_bg" android:background="@drawable/button_bg"
android:visibility="gone" android:visibility="gone"
android:layout_marginBottom="24dp"
android:layout_marginEnd="24dp"
android:text="@string/send" android:text="@string/send"
tools:visibility="visible" tools:visibility="visible"
app:layout_constraintBottom_toBottomOf="parent" app:layout_constraintBottom_toBottomOf="parent"

View File

@ -13,6 +13,19 @@
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content"> android:layout_height="wrap_content">
<TextView
android:id="@+id/recv_monero_textview"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="32dp"
android:text="@string/wallet_keys_label"
android:textSize="32sp"
android:textStyle="bold"
app:layout_constraintBottom_toTopOf="@id/information_textview"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<TextView <TextView
android:id="@+id/information_textview" android:id="@+id/information_textview"
android:layout_width="0dp" android:layout_width="0dp"
@ -23,7 +36,7 @@
android:textStyle="bold" android:textStyle="bold"
app:layout_constraintEnd_toStartOf="@id/copy_information_imagebutton" app:layout_constraintEnd_toStartOf="@id/copy_information_imagebutton"
app:layout_constraintStart_toStartOf="parent" app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" app:layout_constraintTop_toBottomOf="@id/recv_monero_textview"
tools:text="INFORMATION" /> tools:text="INFORMATION" />
<ImageButton <ImageButton

View File

@ -31,7 +31,7 @@
<string name="wallet_locked_balance_text">+ %1$s confirming</string> <string name="wallet_locked_balance_text">+ %1$s confirming</string>
<string name="send_amount_empty">Please enter an amount</string> <string name="send_amount_empty">Please enter an amount</string>
<string name="send_amount_invalid">Please enter a valid amount</string> <string name="send_amount_invalid">Please enter a valid amount</string>
<string name="send_max">Send Max</string> <string name="send_max">Max</string>
<string name="undo">Undo</string> <string name="undo">Undo</string>
<string name="error_sending_tx">Error sending tx</string> <string name="error_sending_tx">Error sending tx</string>
<string name="error_creating_tx">Error creating tx</string> <string name="error_creating_tx">Error creating tx</string>
@ -39,7 +39,7 @@
<string name="invalid_mnemonic_code">Invalid mnemonic</string> <string name="invalid_mnemonic_code">Invalid mnemonic</string>
<string name="copied_to_clipboard">Copied to clipboard</string> <string name="copied_to_clipboard">Copied to clipboard</string>
<string name="night_mode">Night mode</string> <string name="night_mode">Night mode</string>
<string name="display_recovery_phrase">Display recovery phrase</string> <string name="display_recovery_phrase">Display wallet keys</string>
<string name="tor_switch_label">Enable proxy</string> <string name="tor_switch_label">Enable proxy</string>
<string name="connection_failed">Connection failed</string> <string name="connection_failed">Connection failed</string>
<string name="address">87MRtZPrWUCVUgcFHdsVb5MoZUcLtqfD3FvQVGwftFb8eSdMnE39JhAJcbuSW8X2vRaRsB9RQfuCpFciybJFHaz3QYPhCLw</string> <string name="address">87MRtZPrWUCVUgcFHdsVb5MoZUcLtqfD3FvQVGwftFb8eSdMnE39JhAJcbuSW8X2vRaRsB9RQfuCpFciybJFHaz3QYPhCLw</string>
@ -97,4 +97,5 @@
<string name="global_index_text">Global Idx: %1$d</string> <string name="global_index_text">Global Idx: %1$d</string>
<string name="outpoint_text">Outpoint: %1$s</string> <string name="outpoint_text">Outpoint: %1$s</string>
<string name="create_wallet_failed">Create wallet failed: %1$s</string> <string name="create_wallet_failed">Create wallet failed: %1$s</string>
<string name="wallet_keys_label">Wallet Keys</string>
</resources> </resources>