Skip to content

Commit

Permalink
Use new QT_NO_CONTEXTLESS_CONNECT variable in qt6
Browse files Browse the repository at this point in the history
Defining the macro before including any Qt header will disable
the overload of QObject::connect that does not take a receiver/context
argument.
  • Loading branch information
Montel authored and ahayzen-kdab committed Oct 25, 2023
1 parent 413282b commit 831c7c8
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,9 @@ if(NOT Qt6_FOUND)
find_package(Qt5 5.15 COMPONENTS Core Gui Test REQUIRED)
endif()

if (NOT Qt5_FOUND)
add_definitions(-DQT_NO_CONTEXTLESS_CONNECT)
endif()

if(UNIX AND NOT APPLE)
if (Qt5_FOUND)
Expand Down

0 comments on commit 831c7c8

Please sign in to comment.