[kde-common/cmake] tde_install_icons: detect locolor theme icons; ignoring icons with invalid names

git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kde-common@1187287 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
master
samelian 14 years ago
parent 955e3bfa94
commit 688c4ba9d0

@ -65,10 +65,15 @@ macro( tde_install_icons )
set( _group "${CMAKE_MATCH_3}" ) set( _group "${CMAKE_MATCH_3}" )
set( _name "${CMAKE_MATCH_4}" ) set( _name "${CMAKE_MATCH_4}" )
# we must ignore invalid icon names
if( _type AND _size AND _group AND _name )
# autodetect theme # autodetect theme
if( NOT _req_theme ) if( NOT _req_theme )
if( "${_type}" STREQUAL "cr" ) if( "${_type}" STREQUAL "cr" )
set( _theme crystalsvg ) set( _theme crystalsvg )
elseif( "${_type}" STREQUAL "lo" )
set( _theme locolor )
endif( "${_type}" STREQUAL "cr" ) endif( "${_type}" STREQUAL "cr" )
# defaulting # defaulting
if( NOT _theme ) if( NOT _theme )
@ -101,6 +106,8 @@ macro( tde_install_icons )
install( FILES ${_icon_file} DESTINATION ${_dest}/${_theme}/${_size}x${_size}/${_group}/ RENAME ${_name} ) install( FILES ${_icon_file} DESTINATION ${_dest}/${_theme}/${_size}x${_size}/${_group}/ RENAME ${_name} )
endif( "${_size}" STREQUAL "sc" ) endif( "${_size}" STREQUAL "sc" )
endif( _type AND _size AND _group AND _name )
endforeach( _icon_file ) endforeach( _icon_file )
endforeach( _icon ) endforeach( _icon )

Loading…
Cancel
Save