aboutsummaryrefslogtreecommitdiff
path: root/src/qt/sendcoinsdialog.cpp
AgeCommit message (Collapse)Author
2020-03-19refactor: Change createWallet, fillPSBT argument orderRussell Yanofsky
Move output arguments after input arguments for consistency with other methods, and to work more easily with IPC framework in #10102
2020-03-19refactor: Get rid of Wallet::IsWalletFlagSet methodRussell Yanofsky
Replace by privateKeysDisabled method to avoid need for GUI to reference internal wallet flags. Also remove adjacent WalletModel canGetAddresses wrapper that serves no purpose and make Wallet::canGetAddresses non-const so it can be implemented by IPC classes in #10102.
2020-03-09Move FillPSBT to be a member of CWalletAndrew Chow
2019-12-30scripted-diff: Bump copyright of files changed in 2019MarcoFalke
-BEGIN VERIFY SCRIPT- ./contrib/devtools/copyright_header.py update ./ -END VERIFY SCRIPT-
2019-11-26[gui] send: show watch-only balance in send screenSjors Provoost
2019-11-23refactor: Nuke coincontrol circular dependencyHennadii Stepanov
2019-11-13[gui] watch-only wallet: copy PSBT to clipboardSjors Provoost
2019-11-13[gui] send: include watch-onlySjors Provoost
For wallets with WALLET_FLAG_DISABLE_PRIVATE_KEYS.
2019-10-24Remove BIP70 Supportfanquake
2019-10-18[wallet] Remove return value from CommitTransaction()John Newbery
CommitTransaction returns a bool to indicate success, but since commit b3a74100b8 it only returns true, even if the transaction was not successfully broadcast. This commit changes CommitTransaction() to return void. All dead code in `if (!CommitTransaction())` branches has been removed.
2019-09-25Change sendcoins dialogue Yes to SendGregory Sanders
2019-09-08HTML escape address labels in more dialogs and notificationsAndrew Chow
2019-09-08HTML escape the wallet name in more dialogs and notificationsAndrew Chow
2019-08-29Merge #16701: qt: Replace functions deprecated in Qt 5.13Wladimir J. van der Laan
c6dd32da697e5a8052cbabe8c7605d27c43a8dfb qt: Replace obsolete functions of QDesktopWidget (Hennadii Stepanov) 1260ecd812e35185898fd555ad3e01d019072bcf qt: Add TextWidth() wrapper (Hennadii Stepanov) Pull request description: The following functions are obsolete in Qt 5.13: - [`QFontMetrics::width()`](https://doc.qt.io/qt-5/qfontmetrics-obsolete.html#width) - [`QDesktopWidget::availableGeometry()`](https://doc.qt.io/qt-5/qdesktopwidget-obsolete.html#availableGeometry) - [`QDesktopWidget::screenGeometry()`](https://doc.qt.io/qt-5/qdesktopwidget-obsolete.html#screenGeometry) This PR replaces them and does not change behavior. Here are some excerpts from the master build log: ``` qt/bitcoingui.cpp: In constructor ‘BitcoinGUI::BitcoinGUI(interfaces::Node&, const PlatformStyle*, const NetworkStyle*, QWidget*)’: qt/bitcoingui.cpp:84:57: warning: ‘const QRect QDesktopWidget::availableGeometry(int) const’ is deprecated: Use QGuiApplication::screens() [-Wdeprecated-declarations] move(QApplication::desktop()->availableGeometry().center() - frameGeometry().center()); ^ In file included from /home/hebasto/Qt/5.13.0/gcc_64/include/QtWidgets/QDesktopWidget:1:0, from qt/bitcoingui.cpp:43: /home/hebasto/Qt/5.13.0/gcc_64/include/QtWidgets/qdesktopwidget.h:88:67: note: declared here QT_DEPRECATED_X("Use QGuiApplication::screens()") const QRect availableGeometry(int screen = -1) const; ^~~~~~~~~~~~~~~~~ ``` ``` qt/bitcoingui.cpp:1410:74: warning: ‘int QFontMetrics::width(const QString&, int) const’ is deprecated: Use QFontMetrics::horizontalAdvance [-Wdeprecated-declarations] max_width = qMax(max_width, fm.width(BitcoinUnits::longName(unit))); ^ In file included from /home/hebasto/Qt/5.13.0/gcc_64/include/QtWidgets/qwidget.h:50:0, from /home/hebasto/Qt/5.13.0/gcc_64/include/QtWidgets/qdialog.h:44, from /home/hebasto/Qt/5.13.0/gcc_64/include/QtWidgets/QDialog:1, from ./qt/optionsdialog.h:8, from ./qt/bitcoingui.h:12, from qt/bitcoingui.cpp:5: /home/hebasto/Qt/5.13.0/gcc_64/include/QtGui/qfontmetrics.h:108:9: note: declared here int width(const QString &, int len = -1) const; ^~~~~ ``` ``` qt/splashscreen.cpp: In constructor ‘SplashScreen::SplashScreen(interfaces::Node&, Qt::WindowFlags, const NetworkStyle*)’: qt/splashscreen.cpp:127:50: warning: ‘const QRect QDesktopWidget::screenGeometry(int) const’ is deprecated: Use QGuiApplication::screens() [-Wdeprecated-declarations] move(QApplication::desktop()->screenGeometry().center() - r.center()); ^ In file included from /home/hebasto/Qt/5.13.0/gcc_64/include/QtWidgets/QDesktopWidget:1:0, from qt/splashscreen.cpp:24: /home/hebasto/Qt/5.13.0/gcc_64/include/QtWidgets/qdesktopwidget.h:79:67: note: declared here QT_DEPRECATED_X("Use QGuiApplication::screens()") const QRect screenGeometry(int screen = -1) const; ^~~~~~~~~~~~~~ ``` ACKs for top commit: jonasschnelli: utACK c6dd32da697e5a8052cbabe8c7605d27c43a8dfb Tree-SHA512: deb7bcbf86e1dcc6508bd91288772c2fe8811db79fa2011de37d0469cdd094fbf7fd8c4512c607bed0bd08dc2968e893c0bbc190732c43c69ed1085259df766c
2019-08-23qt: Add TextWidth() wrapperHennadii Stepanov
In Qt 5.12 and before the QFontMetrics::width() is used and it is deprecated since Qt 13.0. In Qt 5.11 the QFontMetrics::horizontalAdvance() was introduced.
2019-08-23gui: Ensure tx send error highlight is visiblebpay
If sending to multiple recipients and one of the recipient fields is malformed, the highlighted field may not be visible due to being scrolled out of view, leading to a confusing lack of error feedback when clicking Send. To avoid this problem ensure the first field containing an error is scrolled into view when Send is clicked.
2019-07-18Get rid of PendingWalletTx class.Russell Yanofsky
No reason for this class to exist if it doesn't have any code to run in the destructor. e10e1e8db043e9b7c113e07faf408f337c1b732d from https://github.com/bitcoin/bitcoin/pull/16208 recently removed code destructor code that would return an unused key if the transaction wasn't committed.
2019-06-06Merge #15886: qt, wallet: Revamp SendConfirmationDialogWladimir J. van der Laan
78f9b5160fea32f85c6ced16b3b0cccda6d3b181 Do not show list for the only recipient. (Hennadii Stepanov) 2ee756f0411c467fc638373ea68d6cb5ced46974 Show recipient list as detailedText of QMessageBox (Hennadii Stepanov) 654e419549fb5f1c360843d48e66eb098bbf5a83 Make SendConfirmationDialog fully fledged (Hennadii Stepanov) Pull request description: Fix #15667 With this PR: ![Screenshot from 2019-04-24 23-47-30](https://user-images.githubusercontent.com/32963518/56692672-63400b00-66eb-11e9-87f6-15957c6e81f7.png) ![Screenshot from 2019-04-24 23-47-40](https://user-images.githubusercontent.com/32963518/56692681-663afb80-66eb-11e9-8b04-8a342026ada6.png) ACKs for commit 78f9b5: laanwj: code review ACK 78f9b5160fea32f85c6ced16b3b0cccda6d3b181 Tree-SHA512: f868d78d01b0898aff2277fa3a7e8c6f936acbbcfa8a0323cddcd9daba4a998030c667bd803ae67c2b9179ed8082a48a67568e9ba3c8d14e3a2d88d93ada94fa
2019-05-18Do not show list for the only recipient.Hennadii Stepanov
2019-04-24Show recipient list as detailedText of QMessageBoxHennadii Stepanov
2019-04-24Make SendConfirmationDialog fully fledgedHennadii Stepanov
The property-based API has been used. Added support for the `informativeText` and `detailedText` properties.
2019-04-18[wallet] Move maxTxFee to walletJohn Newbery
This commit moves the maxtxfee setting to the wallet. There is only one minor behavior change: - an error message in feebumper now refers to -maxtxfee instead of maxTxFee.
2019-01-13Don't use zero as null pointer constant (-Wzero-as-null-pointer-constant)practicalswift
Qt-only changes.
2018-10-30qt: Remove "Pay only required fee" checkboxHennadii Stepanov
The custom fee input box now has a minimum value equal to the minimum required fee. Before a value below the minimum fee could be entered which was confusing since the minimum fee would still be paid even though a lower amount was entered.
2018-10-09build: Add --disable-bip70 configure optionWladimir J. van der Laan
This patch adds a --disable-bip70 configure option that disables BIP70 payment request support. When disabled, this removes the dependency of the GUI on OpenSSL and Protobuf.
2018-08-27Make objects in range declarations immutable by default. Avoid unnecessary ↵practicalswift
copying of objects in range declarations.
2018-08-21qt: Use new Qt5 connect syntaxJoão Barbosa
2018-07-27Update copyright headers to 2018DrahtBot
2018-05-08[qt]: changes sendcoinsdialog's box layout for improved readability.marcoagner
[qt]: extracts html tags from translator. [qt]: removes missed tr() call.
2018-04-23wallet: Make fee settings non-static membersMarcoFalke
2018-04-07scripted-diff: Avoid `interface` keyword to fix windows gitian buildRussell Yanofsky
Rename `interface` to `interfaces` Build failure reported by Chun Kuan Lee <ken2812221@gmail.com> https://github.com/bitcoin/bitcoin/pull/10244#issuecomment-379434756 -BEGIN VERIFY SCRIPT- git mv src/interface src/interfaces ren() { git grep -l "$1" | xargs sed -i "s,$1,$2,g"; } ren interface/ interfaces/ ren interface:: interfaces:: ren BITCOIN_INTERFACE_ BITCOIN_INTERFACES_ ren "namespace interface" "namespace interfaces" -END VERIFY SCRIPT-
2018-04-04Use WalletBalances struct in QtRussell Yanofsky
Suggested by John Newbery <john@johnnewbery.com> https://github.com/bitcoin/bitcoin/pull/10244#discussion_r177504284
2018-04-04Remove direct bitcoin calls from qt/sendcoinsdialog.cppRussell Yanofsky
2018-04-04Remove direct bitcoin access from qt/guiutil.cppRussell Yanofsky
2018-04-04Remove most direct bitcoin calls from qt/walletmodel.cppRussell Yanofsky
2018-03-26Merge #12610: Multiwallet for the GUIJonas Schnelli
779c5f984 Qt: hide RPCConsole wallet selector when no wallets are present (Jonas Schnelli) dc6f150f3 Qt: show wallet name in request dlg in case of multiwallet (Jonas Schnelli) 4826ca4b8 Qt: show wallet name in send confirmation dlg in case of multiwallet (Jonas Schnelli) cfa4133ce GUI: RPCConsole: Log wallet changes (Luke Dashjr) b6d04fc7c Qt: Get wallet name from WalletModel rather than passing it around (Luke Dashjr) 12d8d2681 Qt: When multiple wallets are used, include in notifications the name (Jonas Schnelli) d1ec34a76 Qt: QComboBox::setVisible doesn't work in toolbars, so defer adding it at all until needed (Luke Dashjr) d49cc70e6 Qt: Add wallet selector to debug console (Jonas Schnelli) d558f44c5 Bugfix: RPC: Add missing UnregisterHTTPHandler for /wallet/ (Luke Dashjr) 85d531971 Qt: Ensure UI updates only come from the currently selected walletView (Luke Dashjr) e449f9a9e Qt: Add a combobox to toolbar to select from multiple wallets (Luke Dashjr) 3dba3c3ac Qt: Load all wallets into WalletModels (Luke Dashjr) Pull request description: This is an overhaul of #11383 (plus some additions). It avoids unnecessary coupling of httpserver/jsonrpc and the wallet as well as it avoids pointer pure passing (and pointer deletion) of `CWallet` (plus other minor design changes). Additionally it adds the wallet name to the sendconfirmation and request dialog (in case multiwallet is active) Tree-SHA512: 3d06e18badbc5d1821e488bf1dae463bb0be544cf11b2b618e025812bfdd13c5f39604bb93b4c705313930e7dc4e66f4848b9469ba14871bade58e7a027246a1
2018-03-26Qt: show wallet name in send confirmation dlg in case of multiwalletJonas Schnelli
2018-03-07Merge #11372: Address encoding cleanupWladimir J. van der Laan
92f1f8b31 Split off key_io_tests from base58_tests (Pieter Wuille) 119b0f85e Split key_io (address/key encodings) off from base58 (Pieter Wuille) ebfe217b1 Stop using CBase58Data for ext keys (Pieter Wuille) 32e69fa0d Replace CBitcoinSecret with {Encode,Decode}Secret (Pieter Wuille) Pull request description: This PR contains some of the changes left as TODO in #11167 (and built on top of that PR). They are not intended for backporting. This removes the `CBase58`, `CBitcoinSecret`, `CBitcoinExtKey`, and `CBitcoinExtPubKey` classes, in favor of simple `Encode`/`Decode` functions. Furthermore, all Bitcoin-specific logic (addresses, WIF, BIP32) is moved to `key_io.{h,cpp}`, leaving `base58.{h,cpp}` as a pure utility that implements the base58 encoding/decoding logic. Tree-SHA512: a5962c0ed27ad53cbe00f22af432cf11aa530e3efc9798e25c004bc9ed1b5673db5df3956e398ee2c085e3a136ac8da69fe7a7d97a05fb2eb3be0b60d0479655
2018-03-06Merge #12432: [qt] send: Clear All also resets coin control optionsWladimir J. van der Laan
f506c0a7f [qt] send: Clear All also resets coin control options (Sjors Provoost) Pull request description: This change makes it so that a custom change address and manual input selection are removed if the user clicks Clear All in the send screen. Tree-SHA512: 78746043a74c9c26ef476eb0df7ce95411683749d9f6b2747222eaac751e241ea7d4d7ce9e4e69ed0b19fa76754d8584e5bef5bba1ad6598f8e39c784b4264d2
2018-03-01[qt] navigate to transaction history page after sendSjors Provoost
The transaction will be selected. When sending to multiple destinations, all will be selected (thanks @promag).
2018-02-19Split key_io (address/key encodings) off from base58Pieter Wuille
2018-02-14[qt] send: Clear All also resets coin control optionsSjors Provoost
2018-02-07Merge #10498: Use static_cast instead of C-style casts for non-fundamental typesMarcoFalke
9ad6746ccd Use static_cast instead of C-style casts for non-fundamental types (practicalswift) Pull request description: A C-style cast is equivalent to try casting in the following order: 1. `const_cast(...)` 2. `static_cast(...)` 3. `const_cast(static_cast(...))` 4. `reinterpret_cast(...)` 5. `const_cast(reinterpret_cast(...))` By using `static_cast<T>(...)` explicitly we avoid the possibility of an unintentional and dangerous `reinterpret_cast`. Furthermore `static_cast<T>(...)` allows for easier grepping of casts. For a more thorough discussion, see ["ES.49: If you must use a cast, use a named cast"](https://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#es49-if-you-must-use-a-cast-use-a-named-cast) in the C++ Core Guidelines (Stroustrup & Sutter). Tree-SHA512: bd6349b7ea157da93a47b8cf238932af5dff84731374ccfd69b9f732fabdad1f9b1cdfca67497040f14eaa85346391404f4c0495e22c467f26ca883cd2de4d3c
2018-02-01[gui] Defer coin control instancingJoão Barbosa
Defer the GUI coin control instancing so that argument processing is taken into account for the default coin control values.
2018-01-04Replaces numbered place marker %2 with %1.251
Replaces numbered place marker %2 with %1, because the QString::arg() member function is called once on the string used to create the QString object.
2018-01-03Increment MIT Licence copyright header year on files modified in 2017Akira Takizawa
2017-12-22Merge #11605: [Wallet] Enable RBF by default in QTWladimir J. van der Laan
5cbbbd7 [Wallet] Use RBF by default in QT only (Sjors Provoost) Pull request description: ~If there are no objections, this would supersede #11556.~ Enabling RBF by default avoids the need to explain all possible use cases of RBF. This PR does not change the default RPC wallet behavior, as this could break implementations that depend on it and it's not clear what happens when automated services suddenly switch on RBF on a large scale. After trying various approaches, we settled on just having QT ignore `-walletrbf`. Send screen: <img width="388" alt="send" src="https://user-images.githubusercontent.com/10217/34251097-329c8dee-e63f-11e7-9e14-d7f55d2b52cc.png"> Confirmation screen by default (with RBF): <img width="429" alt="rbf yes" src="https://user-images.githubusercontent.com/10217/32442799-f50d54aa-c2fc-11e7-9392-96339d0f1f74.png"> Confirmation screen without RBF: <img width="431" alt="rf no" src="https://user-images.githubusercontent.com/10217/32442793-ef30bc34-c2fc-11e7-8ca2-e86a97175278.png"> Tree-SHA512: 53efb5d277144478143e69dcae8112c1b9c2beb981fdd0fe778592e5f7d5bf838f73d48052ead874586a75b944e8af469b25e5f376c135cf48cc3598e77f5891
2017-12-22[Wallet] Use RBF by default in QT onlySjors Provoost
GUI wallet uses RBF by default, regardless of -walletrbf. RPC and debug console in the GUI remain unchanged; they don't use RBF by default, unless launched with -walletrbf=1.
2017-12-14Merge #10839: Don't use pass by reference to const for cheaply-copied types ↵Wladimir J. van der Laan
(bool, char, etc.) 99ba0c3 Don't use pass by reference to const for cheaply-copied types (bool, char, etc.). (practicalswift) Pull request description: Don't use pass by reference to const for cheaply-copied types (`bool`, `char`, etc.). Tree-SHA512: ccad5e2695dff0b3d6de3e713ff3448f2981168cdac72d73bee10ad346b9919d8d4d588933369e54657a244b8b222fa0bef919bc56d983e1fa64b2004e51b225
2017-12-12Merge #10574: Remove includes in .cpp files for things the corresponding .h ↵Wladimir J. van der Laan
file already included a720b92 Remove includes in .cpp files for things the corresponding .h file already included (practicalswift) Pull request description: Remove includes in .cpp files for things the corresponding .h file already included. Example case: * `addrdb.cpp` includes `addrdb.h` and `fs.h` * `addrdb.h` includes `fs.h` Then remove the direct inclusion of `fs.h` in `addrman.cpp` and rely on the indirect inclusion of `fs.h` via the included `addrdb.h`. In line with the header include guideline (see #10575). Tree-SHA512: 8704b9de3011a4c234db336a39f7d2c139e741cf0f7aef08a5d3e05197e1e18286b863fdab25ae9638af4ff86b3d52e5cab9eed66bfa2476063aa5c79f9b0346