78 lines
1.5 KiB
CMake
Executable File
78 lines
1.5 KiB
CMake
Executable File
#
|
|
# CMakeLists.txt for Data View
|
|
#
|
|
# $Id$
|
|
# $HeadURL$
|
|
# $Author$
|
|
# Created by Mike Wille, SLSE, 2016-06-15
|
|
#
|
|
|
|
# Make ${Qt6_Widgets} optional
|
|
if(QT6_GUI_AVAILABLE AND TARGET Qt6::Widgets)
|
|
set(Qt6_Widgets ${Qt6_Widgets})
|
|
else()
|
|
set(Qt6_Widgets "")
|
|
endif()
|
|
|
|
|
|
SET(ltsDataView_SRCS
|
|
lts_data_view_export.h
|
|
lts_data_view.h
|
|
lts_data_view.cpp
|
|
abstract_display_widget.h
|
|
abstract_display_widget.cpp
|
|
search_model.cpp
|
|
search_model.h
|
|
tree_view.cpp
|
|
tree_view.h
|
|
check_state_proxy_model.h
|
|
check_state_proxy_model.cpp
|
|
tree_view_delegate.cpp
|
|
tree_view_delegate.h
|
|
icon_view_delegate.cpp
|
|
icon_view_delegate.h
|
|
data_delegate.cpp
|
|
data_delegate.h
|
|
lts_columns_setting.cpp
|
|
lts_columns_setting.h
|
|
)
|
|
|
|
NGL_WRAP_UI(ltsDataView_SRCS
|
|
lts_data_view.ui
|
|
lts_columns_setting.ui
|
|
)
|
|
|
|
NGL_ADD_LIBRARY(WS LtsDataView SHARED ${ltsDataView_SRCS})
|
|
|
|
if(QT6_GUI_AVAILABLE)
|
|
NGL_TARGET_LINK_LIBRARIES(LtsDataView
|
|
PRIVATE
|
|
LtsWidgets
|
|
LtsUtilsSettings
|
|
ngltools
|
|
PUBLIC
|
|
Qt6::Core
|
|
${Qt6_Widgets}
|
|
)
|
|
endif()
|
|
NGL_TARGET_INCLUDE_DIRECTORIES(LtsDataView
|
|
PUBLIC
|
|
${CMAKE_CURRENT_SOURCE_DIR}/../
|
|
)
|
|
NGL_INSTALL_TARGET(LtsDataView)
|
|
|
|
|
|
# Test-Executable
|
|
NGL_ADD_EXECUTABLE(WS NO_TRANSLATION LtsDataViewTest test.h test.cpp)
|
|
NGL_TARGET_LINK_LIBRARIES(LtsDataViewTest
|
|
${Qt6_Widgets}
|
|
LtsDataView
|
|
LtsWidgets
|
|
)
|
|
|
|
# Register test with CTest
|
|
if(BUILD_TESTING)
|
|
add_test(NAME LtsDataViewTest COMMAND $<TARGET_FILE:LtsDataViewTest>)
|
|
set_tests_properties(LtsDataViewTest PROPERTIES ENVIRONMENT "QT_QPA_PLATFORM=offscreen")
|
|
endif()
|