Commit Graph

1419 Commits

Author SHA1 Message Date
ThomasV
91f36db8ef type checking, follow-up 206bacbcb3 2023-03-15 15:42:58 +01:00
ThomasV
3ddffb9773 follow-up 206bacbcb3 2023-03-15 15:41:08 +01:00
ThomasV
206bacbcb3 move MyTreeView and related classes to own submodule 2023-03-15 14:25:42 +01:00
ThomasV
abc8d1550e Expiry: the setting is a period, not a date 2023-03-15 12:35:58 +01:00
ThomasV
5750c8954d receive tab: move back Expiry to its previous location, but use
dialog instead of ComboBox.

The toolbar location is not good, because it can be perceived as
being about the request currently displayed.
2023-03-15 12:28:26 +01:00
ThomasV
42a63643f3 receive tab: move expiry to toolbar 2023-03-15 12:20:22 +01:00
ThomasV
33a84f6be5 view menu: use checkable actions 2023-03-15 11:27:05 +01:00
ThomasV
b431d39a8e Qt lists: consistently show Details as first item in the contextual menu 2023-03-15 11:18:19 +01:00
ThomasV
107a6f9080 utxo_dialog: fix minor regression (set cursor to top after drawing) 2023-03-15 11:11:11 +01:00
ThomasV
2db0bc9f73 tx in/out details: rewording 'receiving address'
in the confirm tx dialog, 'receiving' could lead users to believe
that the funds are going to be sent to this address.
2023-03-15 11:00:40 +01:00
ThomasV
20e93af70c lightning_tx_dialog: add editable tx description 2023-03-15 10:48:03 +01:00
ThomasV
0bda808b29 Qt lists: always show item detail on double click
No longer enter edit mode for editable columns.
(that behaviour was difficult to learn, because
it is not explicit which columns are editable)
2023-03-15 10:35:44 +01:00
ThomasV
660a8ebc7f Qt: let user edit tx label from tx_dialog
This allows users to edit labels from the utxo_dialog,
without having to search for the transaction in history.

Also, remove block hash from tx dialog: not very useful, and
available through block explorers. (the situation where this
could be useful is case of a chain fork, but in that case the
tx might be mined in both branches of the fork, and we would
want to know that).
2023-03-15 09:33:11 +01:00
SomberNight
d166fa886e qt: fix paying to openalias
Probably got broken in https://github.com/spesmilo/electrum/pull/7839 ,
which got released in 4.3.0, ~7 months ago.
As no one complained, this really again raises the question of removing openalias...

related https://github.com/spesmilo/electrum/issues/6232
2023-03-14 17:21:33 +00:00
ThomasV
d56162c588 follow-up 842229c 2023-03-14 17:12:38 +01:00
ThomasV
49847f3544 Merge pull request #8243 from SomberNight/202303_db_metadata
Store file creation date and version in db
2023-03-14 16:45:35 +01:00
SomberNight
a6c4069617 qt send_tab: allow saving bip70 payment requests
probably got disabled in or around https://github.com/spesmilo/electrum/pull/7839 by accident
2023-03-14 14:54:15 +00:00
ThomasV
1f4cedf56a Rework PaytoEdit:
- show a QLineEdit by default, a QTextEdit only if paytomany is active.
   paytomany is a rare use case, it should not interfer with regular
   use (e.g. when a user inadvertently types enter).
 - this also fixes the visual appearance if the payto line
 - keep paytomany menu in sync with actual state
2023-03-14 15:37:20 +01:00
Sander van Grieken
842229c4bb qt: fit StatusBarButton to inner height of status bar 2023-03-14 12:37:34 +01:00
SomberNight
acc1f22442 qt: MyTreeView: small clean-up for WatcherList and ContactList 2023-03-13 19:00:46 +00:00
SomberNight
1740765125 qt settings_dialog: fix trampoline_cb 2023-03-13 18:51:34 +00:00
SomberNight
9d64fe7046 qt: MyTreeView: disambiguate "parent" and "main_window" 2023-03-13 17:29:29 +00:00
SomberNight
dd27c6beff qt utxo list: copy menu: separate items for short/long outpoint 2023-03-13 16:41:10 +00:00
SomberNight
08c37ab088 qt: HistoryList to also use BaseColumnsEnum 2023-03-13 16:39:13 +00:00
SomberNight
d3c241db4c qt: MyTreeView: use enum.auto() in Columns enum 2023-03-13 16:12:50 +00:00
SomberNight
638c896b11 qt: MyTreeView: make item labels independent of column order 2023-03-13 15:54:52 +00:00
SomberNight
950065a3de Store file creation date and version in db
Store the electrum version used to create a wallet file and a timestamp,
in the file itself. This can be useful for debugging.
2023-03-13 15:15:50 +00:00
ThomasV
2571eeeecd coins tab: add toolbar. 2023-03-13 15:35:35 +01:00
SomberNight
c39653c796 qt wallet info dlg: make mess smaller 2023-03-13 14:21:40 +00:00
ThomasV
0f1fe1b1f1 address_list: fix counter (was not displaying filtered count) 2023-03-13 14:38:21 +01:00
ThomasV
32ee70438c Address filter: remove label 2023-03-13 14:30:45 +01:00
ThomasV
b690f2e5cd qr_window: keep menu in sync with actual visibility 2023-03-13 14:23:36 +01:00
SomberNight
375ae851ec qt tx dialog: better size policy. for nicer window resizing 2023-03-13 13:14:03 +00:00
ThomasV
90b46885a9 address_dialog: set num_tx_label 2023-03-13 12:55:30 +01:00
ThomasV
2bf2d815d2 Qt: add tx and address counters 2023-03-13 12:25:55 +01:00
ThomasV
cbab50e4ce channels_list: move swap and rebalance buttons into toolbar 2023-03-13 12:11:50 +01:00
ThomasV
303ad02d17 privacy analysis: add warning about tx downstream of address reuse 2023-03-13 11:41:36 +01:00
ThomasV
439f1e6331 settings_dialog: add confirmation dialog before disabling trampoline 2023-03-13 11:08:04 +01:00
ThomasV
e150a9ccad restructure settings_dialog, create 'Units' tab 2023-03-13 10:02:47 +01:00
ThomasV
519926ade3 move 'allow_instant_swaps' option from preferences dialog to swap_dialog toolbar 2023-03-13 09:53:08 +01:00
ThomasV
4909cebdae move recoverable channel option from preferences to new_channel_dialog toolbar 2023-03-13 09:36:02 +01:00
ThomasV
b15387c89b Qt send tab: move payto_edit input buttons to toolbar 2023-03-13 08:55:45 +01:00
ThomasV
eef1f0b2fd transaction_dialog: move tx_dialog_fetch_txin_data checkbox into toolbar 2023-03-13 08:16:44 +01:00
ThomasV
503776c0de move fiat columns show/hide settings from settings_dialog to tab toolbars 2023-03-12 13:30:11 +01:00
ThomasV
98f0526996 swap_dialog: minor fix 2023-03-12 11:54:44 +01:00
ThomasV
37a0e125c6 move config settings that are related to invoice creation to receive tab. 2023-03-12 10:42:26 +01:00
ThomasV
473c86c395 toolbar: use custom MyMenu class with addToggle 2023-03-12 10:11:08 +01:00
SomberNight
d83863cc52 qt tx dialog: add checkbox "Download input data"
If checked, we download prev (parent) txs from the network, asynchronously.
This allows calculating the fee and showing "input addresses".

We could also SPV-verify the tx, to fill in missing tx_mined_status
(block height, blockhash, timestamp, short ids), but this is not done currently.
Note that there is no clean way to do this with electrum protocol 1.4:
`blockchain.transaction.get_merkle(tx_hash, height)` requires knowledge of the block height.

Loosely based on 6112fe0e51
2023-03-12 00:24:31 +00:00
Calin Culianu
c79074c4d8 qt: port "rate_limiter" function decorator utility from Electron-Cash
ported from e8bbf8280c/electroncash_gui/qt/util.py
(originally added in 8b8d8a5690 )

Co-authored-by: Calin Culianu <calin.culianu@gmail.com>
Co-authored-by: SomberNight <somber.night@protonmail.com>
2023-03-12 00:22:01 +00:00
SomberNight
81772faf6c wallet: add_input_info to no longer do network requests
- wallet.add_input_info() previously had a fallback to download parent
  prev txs from the network (after a lookup in wallet.db failed).
  wallet.add_input_info() is not async, so the network request cannot
  be done cleanly there and was really just a hack.
- tx.add_info_from_wallet() calls wallet.add_input_info() on each txin,
  in which case these network requests were done sequentially, not concurrently
- the network part of wallet.add_input_info() is now split out into new method:
  txin.add_info_from_network()
- in addition to tx.add_info_from_wallet(), there is now also tx.add_info_from_network()
  - callers of old tx.add_info_from_wallet() should now called either
    - tx.add_info_from_wallet(), then tx.add_info_from_network(), preferably in that order
    - tx.add_info_from_wallet() alone is sufficient if the tx is complete,
      or typically when not in a signing context
- callers of wallet.bump_fee and wallet.dscancel are now expected to have already
  called tx.add_info_from_network(), as it cannot be done in a non-async context
  (but for the common case of all-inputs-are-ismine, bump_fee/dscancel should work regardless)
- PartialTxInput.utxo was moved to the baseclass, TxInput.utxo
2023-03-12 00:21:57 +00:00