Skip to content

Commit

Permalink
3476: disable Qt OpenGL buglist (TrenchBroom#3483)
Browse files Browse the repository at this point in the history
  • Loading branch information
ericwa authored Sep 22, 2020
1 parent 33bcf65 commit 3d39054
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 2 deletions.
6 changes: 5 additions & 1 deletion app/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@ include(${CMAKE_CURRENT_SOURCE_DIR}/cmake/GenerateManual.cmake)
set(APP_SOURCE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/src")
set(APP_RESOURCE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/resources")

set(APP_SOURCE "${APP_SOURCE_DIR}/Main.cpp")
set(APP_SOURCE
"${APP_SOURCE_DIR}/Main.cpp"
"${APP_RESOURCE_DIR}/qrc/resources.qrc")

# OS X app bundle configuration, must happen before the executable is added
if(APPLE)
Expand Down Expand Up @@ -107,6 +109,8 @@ macro(configure_app_target APP_TARGET_NAME SHOULD_BUILD_MANUAL)
target_link_libraries(${APP_TARGET_NAME} common) # common already comes with all its dependencies, no need to repeat them here
set_compiler_config(${APP_TARGET_NAME})

set_target_properties(${APP_TARGET_NAME} PROPERTIES AUTORCC TRUE)

if(APPLE)
# Configure variables that are substituted into the plist
# Set CFBundleExecutable
Expand Down
1 change: 1 addition & 0 deletions app/resources/qrc/opengl_buglist.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{ "entries": [] }
5 changes: 5 additions & 0 deletions app/resources/qrc/resources.qrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
<!DOCTYPE RCC><RCC version="1.0">
<qresource>
<file>opengl_buglist.json</file>
</qresource>
</RCC>
7 changes: 6 additions & 1 deletion app/src/Main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,12 @@ int main(int argc, char *argv[])
// it should produce RMB down/move events.
// This environment variable disables Qt's emulation so we can implement it ourselves in InputEventRecorder::recordEvent
qputenv("QT_MAC_DONT_OVERRIDE_CTRL_LMB", "1");


// Disable Qt OpenGL buglist; since we require desktop OpenGL 2.1 there's no point in
// having Qt disable it (also we've had reports of some Intel drivers being blocked that
// actually work with TB.)
qputenv("QT_OPENGL_BUGLIST", ":/opengl_buglist.json");

TrenchBroom::View::TrenchBroomApp app(argc, argv);
app.parseCommandLineAndShowFrame();
return app.exec();
Expand Down

0 comments on commit 3d39054

Please sign in to comment.