Commit Graph

740 Commits

Author SHA1 Message Date
tomFlowee 5fef6d9864 Add license. 2022-12-16 19:54:32 +01:00
tomFlowee 993f5b1d3e Put the menu options in a flickable. 2022-12-16 11:41:26 +01:00
tomFlowee eadc87e64c Improve account selector in menu
Working with the UX guy we massively improved the account selector.

Instead of trying to shoe-horn the 'add account' under a non-existing
account we realized it fits better on its own. Even the moving of it
after adding one will not cause too big a problem due to the
different look afterwards.

The actual opened menu will also behave better if you have more than
one account in this new design and more predictable.
2022-12-15 22:35:05 +01:00
tomFlowee e1e7e8f14e Move account selector to the titlebar. 2022-12-15 15:03:43 +01:00
tomFlowee 331da1fa57 Make scanner abort on pressing the Esc or Back keys. 2022-12-15 14:57:41 +01:00
tomFlowee c12f8cea64 Cleanup QRScanner QML component design
Avoid the ugly 'Component.onCompleted' and instead make this is a
property 'autostart'.
2022-12-15 14:54:13 +01:00
tomFlowee bdbbdd1726 Remove priceFor overload
The downside of this method is that changes in price don't cause the
result to be re-calculated.
Its not very declarative, in other words.
2022-12-15 14:37:58 +01:00
tomFlowee ebae4b6bcd Add gui-font-scaling config option.
Allow the user to change the font sizing of the GUI.
2022-12-15 12:37:21 +01:00
tomFlowee 0386ae0154 Export baseline. 2022-12-15 12:00:01 +01:00
tomFlowee b6b8bb407a Add a plus icon in front of the 'add wallet' button. 2022-12-15 11:59:07 +01:00
tomFlowee c6df261335 State time in the recent transactions. 2022-12-15 10:50:29 +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 6eb3df5248 Close accounts section on menu close. 2022-12-14 14:38:33 +01:00
tomFlowee a0c4f9be7a Much improvement with the camera section.
This adds a prettty cutout screen and better feedback on the camera view
popping up.
We also make visible the scan overlay instantly, hiding out any other UI
that is hidden beneath it.

We correctly handle various odd issues with Qt / Android.

- the permissions request (QFuture) returned in a different thread, we
now move back to the main thread before doing any calls on the
multimedia objects.

- The popping up of the android permissions requestor actually makes the
app think its being made inactive. Now we no longer cancel the QR scan
request in such cases.
2022-12-14 14:21:56 +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 bacbfb2849 Be more lenient with hiding of the progress indicator
When there has not been a block for some time we might be up to date
already.

Also remove unused variable.
2022-12-13 20:53:58 +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 21bc7343ce Swap order to fix screen layout
Moving the text line up would allow the virtual keyboard to have more
space and likely that the top-level button to get out of the screen
stays visible.

I.e. users don't have to manually hide the keyboard to continue.
2022-12-08 15:27:59 +01:00
tomFlowee 94c74de75e Hide wallet name when its the default never used one. 2022-12-08 15:27:59 +01:00
tomFlowee 5fba582bbe Make SmallAccountSelector reuable. 2022-12-08 15:27:59 +01:00
tomFlowee 3c30934963 Provide silly icons and do the receive screen.
The 3 icons at the top of the account screen now have 2 with actual
icons. They don't look very good, but at least its better than no
icons.

Also I stole most of the receive screen from desktop and ported it here.
Quick and dirty as that screen has been long overdue for a refresh.
2022-12-08 15:27:59 +01:00
tomFlowee 3295910e94 Remove not existing feature from menu. 2022-12-08 15:27:59 +01:00
tomFlowee 73a44e31c5 Add new icons
For the send and receive tabs.

Half an hour with Inkscape, I'm a little proud of these two icons.
Created them myself.
2022-12-08 15:27:59 +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 41d332b697 Make camera screen acceptable and abortable
The camera scanning screen now isn't looking like a total disaster
anymore and I even put a close button on it to allow closing it without
a scan.
2022-12-08 15:27:59 +01:00
tomFlowee 406327becb Finish up basic payment page
Next up; broadcast and feedback.
2022-12-08 15:27:59 +01:00
tomFlowee b89276a688 Fix language name 2022-12-07 21:30:05 +01:00
tomFlowee a8c7a6c3ae Minor bugfixes
Actually hide the cursor when we are no longer editing.
2022-12-07 11:22:27 +01:00
tomFlowee d37a24d984 Add ObjectShaker to give feedback on bad input
When the user uses the keyboard and that doesn't get accepted, we now
shake the widget we are editing.
2022-12-07 11:22:27 +01:00
tomFlowee 1aa58cf62c Make BitcoinvalueField hide trailing zeros 2022-12-07 11:17:12 +01:00
tomFlowee 03204fad3e Update the PayWithQR.qml to integrate the nicer editors
This makes most of the widget functional, I'll leave the "slide to pay"
for tomorrow.
2022-12-06 22:39:02 +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 6e5b330cc6 Also update FiatValueField.qml
Same concept as BitcoinValueField, and a small refactor to reuse code
between them.
2022-12-06 22:10:03 +01:00
tomFlowee d14f2db763 Rewrite BitcoinValueField to use font-sizing
This now makes the editing version look identical to the basic display
version with regards to font sizing and coloring.
2022-12-06 22:10:03 +01:00
tomFlowee 2818cc44f9 Setup the page to have the needed components.
This is mostly without user interaction right now, but all the needed
stuff is on the page to show the visual design.
2022-12-05 21:24:32 +01:00
tomFlowee 98be7d0ff0 Link button 2022-12-05 20:33:12 +01:00
tomFlowee a106048840 drop the wrapping of pages in a grid layout
It now feels like a premature optimization to make anything
that inherets from Page be wrapped in a grid layout.
Notice that a "Page" here is the thing we push on the card-stack, the
Page has the back icon and the header text.
2022-12-05 20:31:00 +01:00
tomFlowee ca60e7360d Add comment. 2022-12-05 18:35:02 +01:00
tomFlowee 55694bf28c Make scanner part feature complete.
We now make the scanner ignore barcodes that do not fit the expected
content.
We now detect 'seedphrase' and 'address' and bip21 type payment urls.
2022-12-05 18:34:53 +01:00
tomFlowee 15ae94ad55 Add missing quote
Seems a copy/paste issue.
2022-12-04 14:43:44 +01:00
tomFlowee 324255c0ea Refactor camera support
After working on android and the qtmultimedia library for a week,
I have a much better understanding of what works and what doesn't.
The resulting design is thus presented. We will have one
CameraController class which refers to one overlay panel in QML
and in different places in the GUI objects based on QRScanner
can be created to initiate a scan.

This additionally moves the actual scanning out of the GUI thread
since blocking that is a no-no.

Now to move towards actually supporting scanning usecases.
2022-12-03 19:34:23 +01:00
tomFlowee b346f21871 Bugfixes in camera code.
Also upstreamed in ZXing-cpp (pr 451 + 453).

Also, re-enable clear-whitespace.
2022-12-02 14:12:20 +01:00
tomFlowee 46d34df2a0 Actually scan for QRs.
This takes the camera feed and pipes it through the ZXing (pronounced
zebra-crossing) library which detects the barcodes in the image.
When we find it, we pluck out the text.
2022-12-01 23:53:21 +01:00
tomFlowee a398d731dc Hardcode QML theme in desktop app 2022-12-01 10:48:09 +01:00
tomFlowee 52e6f85cbb Move camera init to C++ 2022-11-30 17:53:47 +01:00
tomFlowee 95d2b57cb3 Add basically functional camera support
This makes it possible for the mobile app on Android to use the camera.
We only ask for permission when the user actively goes to the 'QR-Scan'
tab, and we show a simple preview of the camera feed.

Notice that the permissions stuff is quite ugly right now due to Qt
having that module in development and the public APIs are simply not
available yet. But at least it works, which is all that matters.
When the next minor Qt release comes out we can hopefully clean this
up and use a version that needs no ifdefs.
2022-11-29 23:51:14 +01:00
tomFlowee 59b0b300db Use QtMultimedia 2022-11-29 23:51:14 +01:00
tomFlowee 143cf3fef8 Slowly moving to the extra tab 2022-11-29 23:51:14 +01:00
tomFlowee 83451ac648 Remove unneeded import 2022-11-29 11:47:13 +01:00