Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Communication between plugins and pluginmanager
QtWS25 Last Chance

Communication between plugins and pluginmanager

Scheduled Pinned Locked Moved Unsolved General and Desktop
8 Posts 3 Posters 1.5k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • D Offline
    D Offline
    Defohin
    wrote on last edited by
    #1

    Hi guys, I'm creating a kind of pluginmanager and a few plugins, each plugin has a method called login which is resposible to login to a different page, but I was wondering, what is the best way to communicate between the plugin > pluginmanager > the user? For instance, when a plugin fails to login, how can I know and tell the user that the login of a specific plugin failed?
    I know it will be signals and slots, but the thing is, the pluginmanager loads all the plugins using QPluginLoader call the method login of all plugins found in a loop, how would I know which plugin failed? how to connect between the plugin and the pluginmanager and the pluginmanager to the user?

    1 Reply Last reply
    0
    • D Offline
      D Offline
      Defohin
      wrote on last edited by
      #2

      Is there anyone to help me with that?

      1 Reply Last reply
      0
      • SGaistS Offline
        SGaistS Offline
        SGaist
        Lifetime Qt Champion
        wrote on last edited by
        #3

        Hi,

        Identify each plugin properly using e.g. objetName and use signals and slots to transmit the information both between the plugin and plugin manager as well as the plugin manager and the GUI.

        Interested in AI ? www.idiap.ch
        Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

        1 Reply Last reply
        0
        • SGaistS Offline
          SGaistS Offline
          SGaist
          Lifetime Qt Champion
          wrote on last edited by
          #4

          And please, practice some patience. Allow at least 24 hours before bumping your own thread. This forum is community driven and the people answering here don't necessarily lives in the same timezone as you.

          Interested in AI ? www.idiap.ch
          Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

          D 1 Reply Last reply
          0
          • SGaistS SGaist

            And please, practice some patience. Allow at least 24 hours before bumping your own thread. This forum is community driven and the people answering here don't necessarily lives in the same timezone as you.

            D Offline
            D Offline
            Defohin
            wrote on last edited by
            #5

            @SGaist I'm sorry for that, it's that I posted this in a while and I went to do something else, I thought it had more time than it actually have.

            1 Reply Last reply
            0
            • SGaistS Offline
              SGaistS Offline
              SGaist
              Lifetime Qt Champion
              wrote on last edited by
              #6

              You can see the time elapsed besides your pseudonym on each post.

              Interested in AI ? www.idiap.ch
              Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

              Q 1 Reply Last reply
              2
              • SGaistS SGaist

                You can see the time elapsed besides your pseudonym on each post.

                Q Offline
                Q Offline
                QtTester
                wrote on last edited by QtTester
                #7

                @SGaist Hi, according to the plug & paint example.
                the interface is a pure c++ class, not inherited from QObject.
                So how can i use connect() function to use slot and signal?

                SGaistS 1 Reply Last reply
                0
                • Q QtTester

                  @SGaist Hi, according to the plug & paint example.
                  the interface is a pure c++ class, not inherited from QObject.
                  So how can i use connect() function to use slot and signal?

                  SGaistS Offline
                  SGaistS Offline
                  SGaist
                  Lifetime Qt Champion
                  wrote on last edited by
                  #8

                  @QtTester hi, make the implementation QObjects.

                  Or make your plugin a factory with a method returning a subclass of whatever base (or rather abstract) class you want for your application.

                  Interested in AI ? www.idiap.ch
                  Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                  1 Reply Last reply
                  0

                  • Login

                  • Login or register to search.
                  • First post
                    Last post
                  0
                  • Categories
                  • Recent
                  • Tags
                  • Popular
                  • Users
                  • Groups
                  • Search
                  • Get Qt Extensions
                  • Unsolved