Bitcoin-Qt: small RPCConsole cleanup #2442

pull Diapolo wants to merge 1 commits into bitcoin:master from Diapolo:Qt_RPCCon changing 1 files +3 −9
  1. Diapolo commented at 9:28 AM on April 2, 2013: none
    • add missing initalisation for clientModel
    • remove unneded RPCExecutor::start() code
  2. in src/qt/rpcconsole.cpp:None in 922f65de79 outdated
     225 | @@ -231,7 +226,7 @@ bool RPCConsole::eventFilter(QObject* obj, QEvent *event)
     226 |          case Qt::Key_PageDown:
     227 |              if(obj == ui->lineEdit)
     228 |              {
     229 | -                QApplication::postEvent(ui->messagesWidget, new QKeyEvent(*keyevt));
     230 | +                qApp->postEvent(ui->messagesWidget, new QKeyEvent(*keyevt));
    


    laanwj commented at 12:33 PM on April 2, 2013:

    postEvent is a static method in the QApplication class; there is no reason to use an instance (qApp) here.


    Diapolo commented at 1:36 PM on April 2, 2013:

    @laanwj Perhaps I was a bit over-eager once more, can we find a defined state as to when we use qApp global pointer and when we use QApplication:: or QCoreApplication::instance()? I thought qApp is fine everywhere, see https://qt-project.org/doc/qt-4.8/qapplication.html#qApp. Goal was to have it used the same everywhere in the Qt code.


    laanwj commented at 2:33 PM on April 2, 2013:

    qApp when it's a normal method of the QApplication object, QApplication:: when it's a static method. QCoreApplication::instance() is a longer way of writing qApp so is never necessary.


    Diapolo commented at 2:38 PM on April 2, 2013:

    Alright, so for static methods we always intend to use QApplication:: and for the rest you mentioned it's qApp then. Will update this!

  3. Bitcoin-Qt: small RPCConsole cleanup
    - add missing initalisation for clientModel
    - remove unneded RPCExecutor::start() code
    bfad9982f8
  4. Diapolo commented at 2:44 PM on April 2, 2013: none

    @laanwj I reverted the qApp thing, should be fine now :).

  5. BitcoinPullTester commented at 2:13 AM on April 3, 2013: none

    Automatic sanity-testing: PASSED, see http://jenkins.bluematt.me/pull-tester/bfad9982f84ef97b0f73eb260cf64e3bbeb2e8f0 for binaries and test log. This test script verifies pulls every time they are updated. It, however, dies sometimes and fails to test properly. If you are waiting on a test, please check timestamps to verify that the test.log is moving at http://jenkins.bluematt.me/pull-tester/current/ Contact BlueMatt on freenode if something looks broken.

  6. laanwj referenced this in commit 369e3df0f8 on Apr 5, 2013
  7. laanwj merged this on Apr 5, 2013
  8. laanwj closed this on Apr 5, 2013

  9. laudney referenced this in commit 859ba6657c on Mar 19, 2014
  10. DrahtBot locked this on Sep 8, 2021

github-metadata-mirror

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

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me