Commit Graph

51 Commits

Author SHA1 Message Date
tomFlowee 4883de304b Export the cashToken bool to the UI
Make clear that we have a cashtoken output in the UI.
2023-06-05 09:58:06 +02:00
tomFlowee 78830c8aa4 Cleanup call to no longer existing function 2023-06-04 19:20:46 +02:00
tomFlowee 49a8a9ce34 Cleanup nice-address usage
A Payment object now has a user-typed address,
a formattedAddress which is a properly formatted cash-address
and last a 'niceAddress' which is the same cash-address but without the
chain prefix.

This cleans up the usage and removes some code from the GUI that did the
string manipulation there.
2023-05-31 15:47:14 +02:00
tomFlowee 2724e2cd67 UX: make checkbox follow price indicator 2023-05-30 19:25:09 +02:00
tomFlowee 1e05c9f6ad Fix overlapping widgets issue 2023-05-30 19:19:57 +02:00
tomFlowee 6d648dc6e7 Make new account pages follow our UX guidelines.
This redoes most of those pages to look much nicer and in-place.

This also disables the 'create' button when the derivation path is not
correctly entered.
2023-05-17 21:23:19 +02:00
tomFlowee 747ff27a1f Various updates and UX features
This brings the new 'privacy mode' to use the standard widgets
and make the UX more smooth.

The swiping between pages / wallets is more visually satisfying.

We update the sync label to have a live counter of how long ago
the last block came in. (both front-ends)
2023-05-16 22:05:48 +02:00
tomFlowee 033cb5962d Add feature; private wallets
A wallet can permanently be labeled a 'private wallet' which is a simple
boolean.
Then when you may need to hand over your phone to a clerk, all you do is
quickly enable the 'private mode' which is sufficiently deep in the menu
to make it hidden.

The effect is that all wallets marked private will be hidden for the
duration of that feature being on.
2023-05-16 20:17:12 +02:00
tomFlowee b218f9f0d4 Fix inconsistent capitalization of toolTipText
Follow the Qt decided usage with 2 upper case characters.
2023-05-16 20:16:12 +02:00
tomFlowee 89e1b94027 Tie the new config settings to the front-end. 2023-05-15 16:17:26 +02:00
tomFlowee b0c22c98e1 Fix regression; make green check show up again
On having a correct address we validate it and show that green check.
This follows the refactor where we moved the logic to the AddressInfo
QML class.
2023-05-06 11:34:42 +02:00
tomFlowee bb4e0bc138 Always show BCH value on testnet
The feature to show only the exchange-rate based value on the
main screen doesn't make sense on anything but mainnet due to
the simple fact that thats the only one that has an exchange rate.

We hide the feature on testnet and make it always show the BCH
value on the overview screens.

Notice that the actuall setting, as written in the config file,
is shared between chains. We only have one confg file. So any
solution with default values would not work.
2023-05-02 11:14:15 +02:00
tomFlowee 527e7895ef Merge branch 'master' into PaymentRequest 2023-05-02 10:53:16 +02:00
tomFlowee 3dfb2b3d38 Port the startupscreen and desktop receive tab too
This makes the new PaymentRequest design be used by all components.
2023-05-02 10:52:37 +02:00
tomFlowee 167c590b78 Use triple equals in JS 2023-05-01 21:51:25 +02:00
tomFlowee 47b4e1ea0a Synchronize the errorRed colors
This adds a errorRedBg 'background' color for a popup with normal white
text on top of it.
2023-04-18 21:54:43 +02:00
tomFlowee 9a6b9686b9 UX; move most complicated to bottom. 2023-04-17 14:27:54 +02:00
tomFlowee 01f87acc28 Add address on QR
This exports the payment-request address to the QML side.
We use this to show under the QR the address we are requesting to send
to.

This is quite useful for users wanting to manually check if things are
going well.
2023-03-21 23:33:23 +01:00
tomFlowee 3bdebe7b8d Introduce GUI settting: show bch.
On the main screen, also known as the "Activity view" this allows the
user to choose to only see fiat or see both Bitcoin Cash and fiat values
listed next to each transaction.
2023-03-21 22:28:41 +01:00
tomFlowee bfac327fb1 Make the font smaller to make it fit. 2023-03-21 21:27:08 +01:00
tomFlowee 43c5f250d5 Merge branch 'master' into buildPayment 2023-03-13 12:15:59 +01:00
tomFlowee 8b50ae1ec0 Use the shared QML AddressInfoWidget 2023-03-13 12:14:23 +01:00
tomFlowee 8b3a85a88b Synchronize property names
This makes the payment detail (output) have the same property name as the
payment itself which was supposed to just be a proxy for a single-output
payment.
Consistency is good.
2023-03-13 11:56:35 +01:00
tomFlowee 45768afe63 Tweak the popup menu
- Don't show Details again for already showing details.
- Show encryption menu even if we are in the details pane (because why not)
2023-02-24 23:44:10 +01:00
tomFlowee 457edc20b4 Simplify the payment and amounts getters
This merges the paymentAmount and effectiveBchAmount methods because they
did 99% the same.
Same with the paymentAmountFiat and effectiveFiatAmount.

This removes the 'effective*' set of properties.
2023-02-22 15:28:06 +01:00
tomFlowee 018a27ceb0 cleanup; use local palette
In Qt5 the palette was introduced in the Control object (part of Qt-
Quick-Controls-2).
In Qt6 this property was moved to the superclass 'Item'.

This means that we no longer need to refer to a control when using a
palette, every single thing in QtQuick is an Item, afterall.
2023-02-21 16:40:46 +01:00
tomFlowee a00f21e4e2 Move calculation of fees to c++
Add a property 'fees' to the TransactionInfo class and use it.

This also changes the GUI behavior of the 'sent' field a little.
In the GUI we now show the amount actually meant to arrive on the other
address(es) instead of the amount our wallet became more empty.

This makes a lot of sense if you look at your transaction and compare to
an invoice, now the 'sent' field will match that invoice and it will
match what the receiver actually received.
2023-02-20 18:10:35 +01:00
tomFlowee 155647d7ac Add docs and make input selector work again
Document various of the Payment properties better and make the input
selector use the multi-detail getter for price.
2023-02-17 19:22:24 +01:00
tomFlowee c024321083 Revise colors, especially dark-theme
This gives the dark-theme a make-over with better colors, more colors
coming from the palette and this makes the conceptual usage between the
mobile and desktop clients of colors to be in-line.
2023-02-14 14:56:18 +01:00
tomFlowee 5ab0290815 Fix reference missing issue. 2023-02-09 14:56:56 +01:00
tomFlowee a7551e1ab2 Avoid multiple copies, add shared QRWidget 2023-02-09 14:56:39 +01:00
tomFlowee f1f8a87fc6 Move line back to the desktop usage
this got moved to the shared component, but it only works in the single
usage of the desktop. Move it back there.
2023-02-09 11:37:26 +01:00
tomFlowee 2aefc20023 Use === instead of ==, following linter suggestion. 2023-02-08 10:05:39 +01:00
tomFlowee 996e5644a5 Share code, split out HamburgerMenu.qml 2023-02-06 21:59:55 +01:00
tomFlowee 906f90e5c2 Re-use secrets view in mobile 'backup' screen.
This moves the desktop account-details specific WalletSecretsView
component to live in the common area and we then use it from the backup
view for a wallet in mobile.

The only change is that we automatically detect if the content is too
wide to fit and we split it over 3 lines instead of 2.
2022-12-19 16:06:19 +01:00
tomFlowee 40c3222f4a Rename property and minor UX cleanups
Rename AccountInfo property 'isDefautWallet' to 'isPrimaryAccount'.
2022-12-19 14:06:27 +01:00
tomFlowee 80200fa28c Start new mobile page 'wallet information'.
This shows all wallets and wallet details.

Additionally, this moves the AccountTypeLabel out of the desktop page to
be reusable. Not so much because its hard, but because they have
translations and we'd better push shared translations into the common
translation unit as opposed to duplicating it.

The LabelWithClipboard now has as default context-menu-item text "Copy"
instead of "Copy Address".
2022-12-16 19:57:43 +01:00
tomFlowee 12c514e024 Avoid confusion, use palette.windowText
The 'text' and 'windowText' were both used like they were the same
thing, which they currently are but don't have to be.

Now migrate the various cases where to we use 'text' to 'windowText'.
This choice is made because the Label object uses windowText by default.

In future we might want to make the 'text' one have a slightly different
color. Its still used in Qt components like the popup menu.
2022-12-14 14:41:55 +01:00
tomFlowee 4f35c21a4f Cleanup
The shapes code moved out of this file, remove the import.
2022-12-14 14:18:07 +01:00
tomFlowee dbccb36077 cleanup the desktop file a bit 2022-12-13 16:36:59 +01:00
tomFlowee c391b89611 Revert debug 2022-12-10 23:37:25 +01:00
tomFlowee 91ae779f91 Reuse BroadcastFeedback on Mobile
This moves the broadcastfeedback part of the desktop to its own (now
shared) widget, and with minor changes reuses it on the mobile side.
2022-12-08 15:27:59 +01:00
tomFlowee fbd4c1a8ea Fix UX issue
When the user changes unit (BCH / mBCH), the widget would not update
until you typed something. Creating a surprise moment.
This fixes that, at the expense of a seemingly innocent warning by QML
about a binding loop.
2022-12-06 22:10:03 +01:00
tomFlowee 15ae94ad55 Add missing quote
Seems a copy/paste issue.
2022-12-04 14:43:44 +01:00
tomFlowee a398d731dc Hardcode QML theme in desktop app 2022-12-01 10:48:09 +01:00
tomFlowee 50ca6c112f Remove version numbers in imports
This idea has been removed in Qt6.
2022-11-26 10:46:57 +01:00
tomFlowee 34614cb646 Fix default value 2022-11-22 23:07:14 +01:00
tomFlowee 1ebfcbf997 Move CardTypeSelector to be a common widget 2022-11-21 20:16:21 +01:00
tomFlowee a46a7e5b74 re-add dropped line
This restores the ability to click on the import tile
2022-11-21 15:46:37 +01:00
tomFlowee 6a9848366d Refactor enum; move to own class
The usage of the big application singleton for enums is not the best for
linkage.

See, in QML you like to use enums, but you need to register the object
it is defined on with QML. So, you ideally have one object with loads of
enums. Easy to maintain, less to learn for the QML author.
Using the application-wide singleton made kind of sense, but this
creates a dependency requirement for all users of these enums that
doesn't jibe well with maintainable code.

So, introduce a simple enums-only class that can be used from QML and is
cheap to include from any using classes.
2022-11-18 13:09:12 +01:00