summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCraig Scott <craig.scott@qt.io>2021-07-12 21:38:42 +1000
committerQt Cherry-pick Bot <cherrypick_bot@qt-project.org>2021-07-19 04:40:49 +0000
commit640e8d232f29fbe560797784664cd556cc069049 (patch)
treef04968edb1b5db7befe51a1dcfdd628a6acc6775
parent3b0c8291502957a5ebf1b60b86f2e314af2a41ce (diff)
Don't create ${target}_qml_files target any more
The qml files should now always be added via dedicated functions provided by the qtdeclarative repo. Those functions take care of adding the files to targets so that they will show up in IDE file lists, so we should not add them to a separate target as well. This will also remove one unnecessary build target, which will reduce visual noise in some IDEs. Change-Id: I79bf1ea8fb8a2f15643e052d50ac582a91bdff1a Reviewed-by: Ulf Hermann <ulf.hermann@qt.io> Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io> (cherry picked from commit a1229a5aa1fb8c7d7e7047ce4c1769d9dae00aec) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
-rw-r--r--src/corelib/Qt6CoreMacros.cmake11
1 files changed, 3 insertions, 8 deletions
diff --git a/src/corelib/Qt6CoreMacros.cmake b/src/corelib/Qt6CoreMacros.cmake
index 9d3e2a646b..f9393a2b07 100644
--- a/src/corelib/Qt6CoreMacros.cmake
+++ b/src/corelib/Qt6CoreMacros.cmake
@@ -1576,15 +1576,10 @@ function(__qt_propagate_generated_resource target resource_name generated_source
endfunction()
# Creates fake targets and adds resource files to IDE's tree
+# FIXME: We shouldn't need to create a separate target for this, the files
+# should be added to the actual target instead.
function(_qt_internal_expose_source_file_to_ide target file)
- set(ide_target_extension "other_files")
- set(qml_extensions ".qml" ".js")
- get_filename_component(resource_extension "${file}" LAST_EXT)
- if(resource_extension IN_LIST qml_extensions)
- set(ide_target_extension "qml_files")
- endif()
-
- set(ide_target ${target}_${ide_target_extension})
+ set(ide_target ${target}_other_files)
if(NOT TARGET ${ide_target})
add_custom_target(${ide_target} SOURCES "${file}")
else()