Skip to content
Snippets Groups Projects

qt: use weak pointer for `QObject` members of `qt_intf_t`

Open Fatih Uzunoğlu requested to merge fuzun/vlc:qt/useqpointerinintf into master
  1. Mar 29, 2025
    • Fatih Uzunoğlu's avatar
      qt: do not construct `ModelRecoveryAgent` if settings or playlist controller do not exist · 354d167b
      Fatih Uzunoğlu authored
      `ModelRecoveryAgent` requires valid settings and playlist controller instances. It can
      not be constructed when they do not exist. This is an extremely unlikely case (but not
      impossible), because given the structure of the application it is expected that they
      are valid when `ModelRecoveryAgent` is constructed.
      
      It should be noted that the reason `ModelRecoveryAgent` construction is delayed through
      queued connection is only to not prolong the application startup time.
      354d167b
    • Fatih Uzunoğlu's avatar
      qt: use `QPointer` for `QObject` members of `qt_intf_t` · e1c71978
      Fatih Uzunoğlu authored
      Although the pointers were set to null after the objects
      are destroyed, if for another reason the objects were
      destroyed (or never constructed and the pointers were
      not initialized), using a weak pointer can prevent
      unintentionally dereferencing dangling pointers.
      e1c71978
Loading