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. Understanding Edge Cases in Signal/Slot Interactions
Qt 6.11 is out! See what's new in the release blog

Understanding Edge Cases in Signal/Slot Interactions

Scheduled Pinned Locked Moved Unsolved General and Desktop
4 Posts 2 Posters 445 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.
  • F Offline
    F Offline
    FizzyGig
    wrote on last edited by
    #1

    Hi there!

    I'm looking to understand the edge cases where a signal may not be emitted. Is a QObject guaranteed to always emit a destroyed signal?

    1 Reply Last reply
    0
    • Christian EhrlicherC Offline
      Christian EhrlicherC Offline
      Christian Ehrlicher
      Lifetime Qt Champion
      wrote on last edited by
      #2

      @fizzygig said in Understanding Edge Cases in Signal/Slot Interactions:

      Is a QObject guaranteed to always emit a destroyed signal?

      If it would be the case then it would be in the documentation: https://doc.qt.io/qt-5/qobject.html#destroyed

      Qt Online Installer direct download: https://download.qt.io/official_releases/online_installers/
      Visit the Qt Academy at https://academy.qt.io/catalog

      F 1 Reply Last reply
      3
      • Christian EhrlicherC Christian Ehrlicher

        @fizzygig said in Understanding Edge Cases in Signal/Slot Interactions:

        Is a QObject guaranteed to always emit a destroyed signal?

        If it would be the case then it would be in the documentation: https://doc.qt.io/qt-5/qobject.html#destroyed

        F Offline
        F Offline
        FizzyGig
        wrote on last edited by
        #3

        @christian-ehrlicher Since it does not state that it is guaranteed, then it isn't. Good to know.

        1 Reply Last reply
        0
        • Christian EhrlicherC Offline
          Christian EhrlicherC Offline
          Christian Ehrlicher
          Lifetime Qt Champion
          wrote on last edited by
          #4

          @fizzygig said in Understanding Edge Cases in Signal/Slot Interactions:

          Since it does not state that it is guaranteed, then it isn't.

          Wrong. "This signal is emitted immediately before the object obj is destroyed" - if this wouldn't be true for a case then it had to be documented so anyone reading the documentation is aware of it.

          Qt Online Installer direct download: https://download.qt.io/official_releases/online_installers/
          Visit the Qt Academy at https://academy.qt.io/catalog

          1 Reply Last reply
          1

          • Login

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