From: <sag...@us...> - 2011-06-01 22:21:03
|
Revision: 889 http://modplug.svn.sourceforge.net/modplug/?rev=889&view=rev Author: saga-games Date: 2011-06-01 22:20:57 +0000 (Wed, 01 Jun 2011) Log Message: ----------- [Fix] Song shouldn't stop anymore after playing one time if playback is initially started using play pattern in loop mode (http://bugs.openmpt.org/view.php?id=11) [Imp] Installer: A shortcut to the extraKeymaps folder is now played in the settings folder. Internal: Code should build again with NO_VST defined. Modified Paths: -------------- trunk/OpenMPT/installer/install.iss trunk/OpenMPT/mptrack/Ctrl_ins.cpp trunk/OpenMPT/mptrack/MainFrm.cpp Modified: trunk/OpenMPT/installer/install.iss =================================================================== --- trunk/OpenMPT/installer/install.iss 2011-05-31 09:58:24 UTC (rev 888) +++ trunk/OpenMPT/installer/install.iss 2011-06-01 22:20:57 UTC (rev 889) @@ -100,8 +100,9 @@ Name: {group}\ModPlug Central; Filename: {app}\ModPlug Central.url Name: {group}\Configuration files; Filename: {userappdata}\OpenMPT\; Tasks: not portable -; app's directory (for ease of use) +; app's directory and keymaps directory (for ease of use) Name: {app}\Configuration files; Filename: {userappdata}\OpenMPT\; Tasks: not portable +Name: {userappdata}\OpenMPT\More Keymaps; Filename: {app}\extraKeymaps\; Tasks: not portable ; desktop, quick launch Name: {userdesktop}\OpenMPT; Filename: {app}\mptrack.exe; Tasks: desktopicon Modified: trunk/OpenMPT/mptrack/Ctrl_ins.cpp =================================================================== --- trunk/OpenMPT/mptrack/Ctrl_ins.cpp 2011-05-31 09:58:24 UTC (rev 888) +++ trunk/OpenMPT/mptrack/Ctrl_ins.cpp 2011-06-01 22:20:57 UTC (rev 889) @@ -950,6 +950,7 @@ m_CbnPluginVolumeHandling.AddString("MIDI volume"); m_CbnPluginVolumeHandling.AddString("Dry/Wet ratio"); m_CbnPluginVolumeHandling.AddString("None"); + m_CbnPluginVolumeHandling.AddString("Custom (Macro)"); // Vol/Pan Swing m_SliderVolSwing.SetRange(0, 64); @@ -2093,6 +2094,7 @@ if ((pPlug == nullptr || pPlug->pMixPlugin == nullptr) && !IsLocked()) { // No plugin in this slot: Ask user to add one. +#ifndef NO_VST CSelectPluginDlg dlg(m_pModDoc, nPlug - 1, this); if (dlg.DoModal() == IDOK) { @@ -2103,7 +2105,7 @@ UpdatePluginList(); m_pModDoc->UpdateAllViews(NULL, HINT_MIXPLUGINS, NULL); } - +#endif // NO_VST } if (pPlug && pPlug->pMixPlugin) Modified: trunk/OpenMPT/mptrack/MainFrm.cpp =================================================================== --- trunk/OpenMPT/mptrack/MainFrm.cpp 2011-05-31 09:58:24 UTC (rev 888) +++ trunk/OpenMPT/mptrack/MainFrm.cpp 2011-06-01 22:20:57 UTC (rev 889) @@ -382,14 +382,14 @@ gcsPreviousVersion = GetPrivateProfileCString("Version", "Version", "", iniFile); if(gcsPreviousVersion == "") - vIniVersion = MPT_VERSION_NUMERIC; + vIniVersion = MptVersion::num; else vIniVersion = MptVersion::ToNum(gcsPreviousVersion); gcsInstallGUID = GetPrivateProfileCString("Version", "InstallGUID", "", iniFile); if(gcsInstallGUID == "") { - //No GUID found in INI file - generate one. + // No GUID found in INI file - generate one. GUID guid; CoCreateGuid(&guid); BYTE* Str; @@ -502,7 +502,7 @@ m_dwPatternSetup |= PATTERN_RESETCHANNELS; if(vIniVersion < MAKE_VERSION_NUMERIC(1,19,00,07)) m_dwPatternSetup &= ~0x800; // this was previously deprecated and is now used for something else - if(vIniVersion < MPT_VERSION_NUMERIC) + if(vIniVersion < MptVersion::num) m_dwPatternSetup &= ~(0x200000|0x400000|0x10000000); // various deprecated old options m_nRowSpacing = GetPrivateProfileDWord("Pattern Editor", "RowSpacing", 16, iniFile); @@ -1968,20 +1968,27 @@ } m_nMixChn = m_nAvgMixChn = 0; gsdwTotalSamples = 0; - if (!bPatLoop) { - if (bPaused) { + if (!bPatLoop) + { + if (bPaused) + { pSndFile->m_dwSongFlags |= SONG_PAUSED; - } else { + } else + { pModDoc->SetPause(FALSE); //rewbs.fix3185: removed this check so play position stays on last pattern if song ends and loop is off. //Otherwise play from cursor screws up. //if (pSndFile->GetCurrentPos() + 2 >= pSndFile->GetMaxPosition()) pSndFile->SetCurrentPos(0); - pSndFile->SetRepeatCount((gbLoopSong) ? -1 : 0); + + // Tentative fix for http://bugs.openmpt.org/view.php?id=11 - Moved following line out of any condition checks + //pSndFile->SetRepeatCount((gbLoopSong) ? -1 : 0); } } + pSndFile->SetRepeatCount((gbLoopSong) ? -1 : 0); + m_pSndFile->SetMasterVolume(m_nPreAmp, true); m_pSndFile->InitPlayer(TRUE); - memset(NotifyBuffer, 0, sizeof(NotifyBuffer)); + MemsetZero(NotifyBuffer); m_dwStatus |= MODSTATUS_PLAYING; m_wndToolBar.SetCurrentSong(m_pSndFile); if (gpSoundDevice) gpSoundDevice->Start(); @@ -2124,7 +2131,7 @@ m_WaveFile.m_nDefaultTempo = 125; m_WaveFile.m_nGlobalVolume=64; m_WaveFile.m_nDefaultSpeed = 4; - m_WaveFile.m_nRepeatCount = 0; + m_WaveFile.SetRepeatCount(0); m_WaveFile.m_nType = MOD_TYPE_IT; m_WaveFile.m_nChannels = 4; m_WaveFile.m_nInstruments = 1; @@ -2191,7 +2198,7 @@ m_WaveFile.Create(NULL, 0); m_WaveFile.m_nDefaultTempo = 125; m_WaveFile.m_nDefaultSpeed = 6; - m_WaveFile.m_nRepeatCount = 0; + m_WaveFile.SetRepeatCount(0); m_WaveFile.m_nType = pSong->m_nType; m_WaveFile.m_nChannels = 4; if ((nInstrument) && (nInstrument <= pSong->m_nInstruments)) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |