- use it for displaying URI parsing warnings
- use it for displaying error and information in backup wallet function (the information display is new and the error was a warning before)
- cleanup BitcoinGUI::incomingTransaction()
-- use message() + the information icon from message
-- comment out an unused parameter in the function definition and
declaration
-- move all pre-checks at the beginning of the function
@laanwj There is this comment in qmessagebox.h (
// the following functions are obsolete) that lists the static QMessageBox functions (warning, information and so on) as obsolete, so I think we should talk about replacing them over the next months.
use new message() function in BitcoinGUI #2045
pull Diapolo wants to merge 1 commits into bitcoin:master from Diapolo:use_message changing 2 files +31 −31-
Diapolo commented at 9:09 PM on November 27, 2012: none
-
BitcoinPullTester commented at 9:31 PM on November 27, 2012: none
Automatic sanity-testing: PASSED, see http://jenkins.bluematt.me/pull-tester/49d58d2d1b862112fa6a4f7fbfb45d726b023c25 for binaries and test log.
-
BitcoinPullTester commented at 10:27 PM on November 27, 2012: none
Automatic sanity-testing: PASSED, see http://jenkins.bluematt.me/pull-tester/8f824def5784ab9177803af9ce561e4ffd3a4eac for binaries and test log.
-
50ecd7b689
use new message() function in BitcoinGUI
- use it for displaying URI parsing warnings - use it for displaying error and information in backup wallet function (the information display is new and the error was a warning before) - cleanup BitcoinGUI::incomingTransaction() -- use message() + the information icon from message -- comment out an unused parameter in the function definition and declaration -- move all pre-checks at the beginning of the function
-
in src/qt/bitcoingui.cpp:None in 8f824def57 outdated
885 | + message(tr("Backup Failed"), tr("There was an error trying to save the wallet data to the new location."), 886 | + true, CClientUIInterface::ICON_ERROR); 887 | } 888 | + else 889 | + message(tr("Backup Successful"), tr("The wallet data was successfully saved to the new location."), 890 | + false, CClientUIInterface::ICON_INFORMATION);
laanwj commented at 10:02 AM on December 3, 2012:I wonder why we still have a mysterious boolean parameter for the 'modal' state, even though that's one of the CClientUIInterface flags? :-)
Diapolo commented at 10:06 AM on December 3, 2012:I think the reason is in bitcoin.cpp ThreadSafeMessageBox(), where we first use the modal flag. I'm sure it could be removed, when I have time I'll take a look. Do you think this should block merging this pull then?
laanwj commented at 10:17 AM on December 3, 2012:Possibly. I think the current semantics is pretty vague. Some of the flags are usable, but not modal, because it's separated out to a different parameter. A pull request to change this would affect exactly the same areas as this one. So let's try to do it right in one go.
BitcoinPullTester commented at 1:43 PM on December 3, 2012: noneAutomatic sanity-testing: PASSED, see http://jenkins.bluematt.me/pull-tester/50ecd7b68970062bfb540798370dbfab6d376086 for binaries and test log.
in src/qt/bitcoingui.cpp:None in 50ecd7b689
893 | @@ -898,8 +894,12 @@ void BitcoinGUI::backupWallet() 894 | QString filename = QFileDialog::getSaveFileName(this, tr("Backup Wallet"), saveDir, tr("Wallet Data (*.dat)")); 895 | if(!filename.isEmpty()) { 896 | if(!walletModel->backupWallet(filename)) { 897 | - QMessageBox::warning(this, tr("Backup Failed"), tr("There was an error trying to save the wallet data to the new location.")); 898 | + message(tr("Backup Failed"), tr("There was an error trying to save the wallet data to the new location."),
laanwj commented at 6:46 AM on December 4, 2012:IMO this one should be modal
Diapolo commented at 7:00 AM on December 4, 2012:It IS :), as
MSG_ERROR = (ICON_ERROR | BTN_OK | MODAL).
laanwj commented at 7:07 AM on December 4, 2012:Ok, cool :)
laanwj referenced this in commit 07c3f846c2 on Dec 13, 2012laanwj merged this on Dec 13, 2012laanwj closed this on Dec 13, 2012laudney referenced this in commit 079348f110 on Mar 19, 2014DrahtBot locked this on Sep 8, 2021
This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2026-04-21 18:16 UTC
More mirrored repositories can be found on mirror.b10c.me