From: <sag...@us...> - 2011-05-28 15:14:11
|
Revision: 886 http://modplug.svn.sourceforge.net/modplug/?rev=886&view=rev Author: saga-games Date: 2011-05-28 15:14:04 +0000 (Sat, 28 May 2011) Log Message: ----------- [Imp] Sample Editor: When selecting parts of the sample, the selection range is now also displayed in samples, not only seconds. [Mod] OpenMPT: Version is now 1.19.02.02 Modified Paths: -------------- trunk/OpenMPT/mptrack/View_smp.cpp trunk/OpenMPT/mptrack/version.h Modified: trunk/OpenMPT/mptrack/View_smp.cpp =================================================================== --- trunk/OpenMPT/mptrack/View_smp.cpp 2011-05-27 18:11:33 UTC (rev 885) +++ trunk/OpenMPT/mptrack/View_smp.cpp 2011-05-28 15:14:04 UTC (rev 886) @@ -302,18 +302,19 @@ s[0] = 0; if (m_dwEndSel > m_dwBeginSel) { - wsprintf(s, "[%d,%d]", m_dwBeginSel, m_dwEndSel); + const DWORD selLength = m_dwEndSel - m_dwBeginSel; + wsprintf(s, "[%d,%d] (%d sample%s, ", m_dwBeginSel, m_dwEndSel, selLength, (selLength == 1) ? "" : "s"); LONG lSampleRate = pSndFile->Samples[m_nSample].nC5Speed; if (pSndFile->m_nType & (MOD_TYPE_MOD|MOD_TYPE_XM)) { lSampleRate = CSoundFile::TransposeToFrequency(pSndFile->Samples[m_nSample].RelativeTone, pSndFile->Samples[m_nSample].nFineTune); } if (!lSampleRate) lSampleRate = 8363; - ULONG msec = ((ULONG)(m_dwEndSel - m_dwBeginSel) * 1000) / lSampleRate; + ULONG msec = ((ULONG)selLength * 1000) / lSampleRate; if (msec < 1000) - wsprintf(s+strlen(s), " (%lums)", msec); + wsprintf(s+strlen(s), "%lums)", msec); else - wsprintf(s+strlen(s), " (%lu.%lus)", msec/1000, (msec/100) % 10); + wsprintf(s+strlen(s), "%lu.%lus)", msec/1000, (msec/100) % 10); } pMainFrm->SetInfoText(s); } Modified: trunk/OpenMPT/mptrack/version.h =================================================================== --- trunk/OpenMPT/mptrack/version.h 2011-05-27 18:11:33 UTC (rev 885) +++ trunk/OpenMPT/mptrack/version.h 2011-05-28 15:14:04 UTC (rev 886) @@ -15,7 +15,7 @@ #define VER_MAJORMAJOR 1 #define VER_MAJOR 19 #define VER_MINOR 02 -#define VER_MINORMINOR 01 +#define VER_MINORMINOR 02 //Creates version number from version parts that appears in version string. //For example MAKE_VERSION_NUMERIC(1,17,02,28) gives version number of This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |