Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-92551

[REG 5.9.3->5.12.10] Assistant tree not opened at first opened page on first setSource + syncContents call

    XMLWordPrintable

Details

    • Bug
    • Resolution: Unresolved
    • P1: Critical
    • None
    • 5.15.2
    • Tools: Assistant
    • None

    Description

      We use remote controlling of the Help Assistant via -enableRemoteControl.
      When we open the first page just after the Assistant is started, the tree is not opened, despite calling syncContents.
      However with the version 5.9.3 Assistant this works fine.
      If we add a waitdelay/sleep of 1 second just after starting the Help Assistant and before we open the page, opening the tree seems to work most of the times.
      The tree is also opened after going to the same page again via remote control when the Assistant is already opened.
      The tree is also opened after clicking the Sync-button in Assistant toolbar.
      (The tree is NOT opened after clicking the Reload-option in the contextmenu of the helppage.)

      (I noticed that the Assistant of version of 5.9.3 also starts bit slower)

       

       

      bool HelpAssistant::startApp()
      {
       if (m_pProc == nullptr)
       {
       m_pProc = new QProcess();
       }
       if (m_pProc->state() == QProcess::NotRunning)
       {
       QStringList args;
       args << QLatin1String("-collectionFile ourhelp.qhc -enableRemoteControl");
       m_pProc->start(QLatin1String("assistant.exe"), args);
       if (!m_pProc->waitForStarted())
       return false;
       //QThread::msleep(1000);// workaround for not opening tree directly after starting assistant when opening first page
       }
       return true;
      }
      void HelpAssistant::goToPage(const QString& page)
      {
       QByteArray ba;
       ba.append("setSource qthelp://com.ourcompany.ourapp/doc/" + page.toLocal8Bit() + ";");
       ba.append("syncContents;");// show item in tree
       ba.append("\n");
       m_pProc->write(ba);
      }
      if (startApp())
       goToPage("somepage.html");
      

       

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            jkobus Jarek Kobus
            wj W. Jaspers
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are no open Gerrit changes