From: <sv...@op...> - 2024-07-14 14:02:44
|
Author: sagamusix Date: Sun Jul 14 16:02:32 2024 New Revision: 21172 URL: https://source.openmpt.org/browse/openmpt/?op=revision&rev=21172 Log: Merged revision(s) 21171 from trunk/OpenMPT: [Fix] xmp-openmpt: If there is only one subsong, set the song title to the "global" song title instead of the name of that subsong (https://www.un4seen.com/forum/?topic=15448.msg143239#msg143239). ........ Modified: branches/OpenMPT-1.31/ (props changed) branches/OpenMPT-1.31/libopenmpt/xmp-openmpt/xmp-openmpt.cpp Modified: branches/OpenMPT-1.31/libopenmpt/xmp-openmpt/xmp-openmpt.cpp ============================================================================== --- branches/OpenMPT-1.31/libopenmpt/xmp-openmpt/xmp-openmpt.cpp Sun Jul 14 16:01:33 2024 (r21171) +++ branches/OpenMPT-1.31/libopenmpt/xmp-openmpt/xmp-openmpt.cpp Sun Jul 14 16:02:32 2024 (r21172) @@ -715,7 +715,7 @@ for ( auto subsong_name = first_subsong; subsong_name != last_subsong; subsong_name++ ) { append_xmplay_tag( tags, "filetype", convert_to_native( StringUpperCase( mod.get_metadata( "type" ) ) ) ); - append_xmplay_tag( tags, "title", convert_to_native( ( subsong_name->empty() || subsong == -1 ) ? title : *subsong_name ) ); + append_xmplay_tag( tags, "title", convert_to_native( ( subsong_name->empty() || subsong == -1 || subsong_names.size() == 1 ) ? title : *subsong_name ) ); append_xmplay_tag( tags, "artist", convert_to_native( mod.get_metadata( "artist" ) ) ); append_xmplay_tag( tags, "album", convert_to_native( mod.get_metadata( "xmplay-album" ) ) ); // todo, libopenmpt does not support that append_xmplay_tag( tags, "date", convert_to_native( extract_date( mod ) ) ); |