promag
commented at 4:22 pm on July 6, 2019:
member
Invalid/wrong dynamic calls aren’t verified by the compiler. This PR asserts those dynamic calls. Once we bump Qt to at least 5.10 these can be refactored to use the invokeMethod overload that allows connecting to lambdas or member pointers, which are compile checked.
DrahtBot
commented at 6:23 pm on July 6, 2019:
member
The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.
Conflicts
Reviewers, this pull request conflicts with the following ones:
#16349 (qt: Remove redundant WalletController::addWallet signal by hebasto)
If you consider this pull request important, please also help to review the conflicting pull requests. Ideally, start with the one that should be merged first.
hebasto
commented at 7:22 pm on July 6, 2019:
member
Once we bump Qt to at least 5.10 these can be refactored to use the invokeMethod overload that allows connecting to lambdas or member pointers, which are compile checked.
IMO, in the long run it will be better to get rid of QMetaObject::invokeMethod completely, because QMetaObject class
… is not normally required for application programming…
fanquake added the label
GUI
on Jul 6, 2019
promag
commented at 7:43 pm on July 6, 2019:
member
@hebasto since Qt 5.10 invokeMethod is very useful to run code (a)synchronous in other thread.
hebasto
commented at 8:35 am on July 7, 2019:
member
Invokes the member (a signal or a slot name) on the object obj. Returns true if the member could be invoked. Returns false if there is no such member or the parameters did not match.
such as a full queue
Is this even possible?
laanwj
commented at 3:31 pm on July 8, 2019:
member
Is this even possible?
I don’t think so, not sure, my experience (with accidentally not rate-limiting notifications) is that the queue is very deep at least
but thanks for quoting the doc that’s good enough for me.
concept and code review ACK2fd7d0b9081c9add34277e94e8ad21ce22ee2d61
hebasto
commented at 3:45 pm on July 8, 2019:
member
This approach was used in a720a983015c9ef8cc814c16a5b9ef6379695817 already.
MarcoFalke added the label
Refactoring
on Jul 8, 2019
hebasto
commented at 4:19 pm on July 8, 2019:
member
0diff --git a/src/qt/bitcoin.cpp b/src/qt/bitcoin.cpp
1index 2fdbcca04..b7740d540 100644
2--- a/src/qt/bitcoin.cpp
3+++ b/src/qt/bitcoin.cpp
4@@ -454,6 +454,7 @@ int GuiMain(int argc, char* argv[])
5 qRegisterMetaType< CAmount >("CAmount");
6 qRegisterMetaType< std::function<void()> >("std::function<void()>");
7 qRegisterMetaType<QMessageBox::Icon>("QMessageBox::Icon");
8+ qRegisterMetaType< WalletModel* >();
9 /// 2. Parse command-line options. We do this after qt in order to show an error if there are problems parsing these
10 // Command-line options take precedence:
11 node->setupServerArgs();
It works.
promag
commented at 5:07 pm on July 8, 2019:
member
Cool, I’ll add it here and you can close your PR.
hebasto
commented at 5:20 pm on July 8, 2019:
member
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: 2024-11-17 09:12 UTC
This site is hosted by @0xB10C More mirrored repositories can be found on mirror.b10c.me