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. [Solved]what is the usage of Q_PRIVATE_SLOT?
Forum Updated to NodeBB v4.3 + New Features

[Solved]what is the usage of Q_PRIVATE_SLOT?

Scheduled Pinned Locked Moved Unsolved General and Desktop
6 Posts 3 Posters 4.3k Views 1 Watching
  • 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.
  • O Offline
    O Offline
    opengpu2
    wrote on last edited by opengpu2
    #1

    what is the usage of Q_PRIVATE_SLOT? is it useless?

    RatzzR 1 Reply Last reply
    0
    • TheBadgerT Offline
      TheBadgerT Offline
      TheBadger
      wrote on last edited by TheBadger
      #2

      I did not know about it, but after some searching and reading up I came across this link: http://kunalmaemo.blogspot.co.za/2010/09/using-signalslot-with-private.html

      So in short if you use opaque or d-pointers the Q_PRIVATE_SLOT is used to connect a slot to a method in the private member class.

      Edit: Look at the links that @Ratzz gave below rather for better information.
      From there you would see that for Qt > 5 with C++11 it is useless


      Check out my SpellChecker Plugin for Qt Creator @ https://github.com/CJCombrink/SpellChecker-Plugin

      O 1 Reply Last reply
      0
      • O opengpu2

        what is the usage of Q_PRIVATE_SLOT? is it useless?

        RatzzR Offline
        RatzzR Offline
        Ratzz
        wrote on last edited by Ratzz
        #3

        You will find something here / here.

        --Alles ist gut.

        1 Reply Last reply
        1
        • TheBadgerT TheBadger

          I did not know about it, but after some searching and reading up I came across this link: http://kunalmaemo.blogspot.co.za/2010/09/using-signalslot-with-private.html

          So in short if you use opaque or d-pointers the Q_PRIVATE_SLOT is used to connect a slot to a method in the private member class.

          Edit: Look at the links that @Ratzz gave below rather for better information.
          From there you would see that for Qt > 5 with C++11 it is useless

          O Offline
          O Offline
          opengpu2
          wrote on last edited by
          #4

          @TheBadger thank you

          1 Reply Last reply
          0
          • RatzzR Offline
            RatzzR Offline
            Ratzz
            wrote on last edited by
            #5

            Once your problem is solved please use the Topic Tools button to mark as Solved.
            Thank you!

            --Alles ist gut.

            O 1 Reply Last reply
            0
            • RatzzR Ratzz

              Once your problem is solved please use the Topic Tools button to mark as Solved.
              Thank you!

              O Offline
              O Offline
              opengpu2
              wrote on last edited by
              #6

              @Ratzz thanks

              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