From: <sag...@us...> - 2015-06-16 16:41:49
|
Revision: 5326 http://sourceforge.net/p/modplug/code/5326 Author: saga-games Date: 2015-06-16 16:41:43 +0000 (Tue, 16 Jun 2015) Log Message: ----------- [Fix] Hidable message box visibility flags were read from the wrong setting variable since r3074. [Mod] General tab: Invert direction of the wet/dry slider to match the Zxx parameter (http://forum.openmpt.org/index.php?topic=3227.0) Revision Links: -------------- http://sourceforge.net/p/modplug/code/3074 Modified Paths: -------------- trunk/OpenMPT/mptrack/TrackerSettings.cpp trunk/OpenMPT/mptrack/View_gen.cpp Modified: trunk/OpenMPT/mptrack/TrackerSettings.cpp =================================================================== --- trunk/OpenMPT/mptrack/TrackerSettings.cpp 2015-06-16 13:06:34 UTC (rev 5325) +++ trunk/OpenMPT/mptrack/TrackerSettings.cpp 2015-06-16 16:41:43 UTC (rev 5326) @@ -206,7 +206,7 @@ , gnPlugWindowWidth(conf, "Display", "PlugSelectWindowWidth", 400) , gnPlugWindowHeight(conf, "Display", "PlugSelectWindowHeight", 450) , gnPlugWindowLast(conf, "Display", "PlugSelectWindowLast", 0) - , gnMsgBoxVisiblityFlags(conf, "Display", "MDIGraphHeight", uint32_max) + , gnMsgBoxVisiblityFlags(conf, "Display", "MsgBoxVisibilityFlags", uint32_max) , GUIUpdateInterval(conf, "Display", "GUIUpdateInterval", 0) , VuMeterUpdateInterval(conf, "Display", "VuMeterUpdateInterval", 15) , VuMeterDecaySpeedDecibelPerSecond(conf, "Display", "VuMeterDecaySpeedDecibelPerSecond", 88.0f) Modified: trunk/OpenMPT/mptrack/View_gen.cpp =================================================================== --- trunk/OpenMPT/mptrack/View_gen.cpp 2015-06-16 13:06:34 UTC (rev 5325) +++ trunk/OpenMPT/mptrack/View_gen.cpp 2015-06-16 16:41:43 UTC (rev 5326) @@ -325,7 +325,7 @@ return; } - CHAR s[128]; + TCHAR s[128]; nTabCount = (sndFile.m_nChannels + 3) / 4; if (nTabCount != m_TabCtrl.GetItemCount()) { @@ -336,7 +336,7 @@ for (int iItem=0; iItem<nTabCount; iItem++) { const int lastItem = MIN(iItem * 4 + 4, MAX_BASECHANNELS); - wsprintf(s, "%d - %d", iItem * 4 + 1, lastItem); + wsprintf(s, _T("%d - %d"), iItem * 4 + 1, lastItem); TC_ITEM tci; tci.mask = TCIF_TEXT | TCIF_PARAM; tci.pszText = s; @@ -365,7 +365,7 @@ { // Text s[0] = 0; - if (bEnable) wsprintf(s, "Channel %u", nChn + 1); + if (bEnable) wsprintf(s, _T("Channel %u"), nChn + 1); SetDlgItemText(IDC_TEXT1 + ichn, s); // Mute CheckDlgButton(IDC_CHECK1 + ichn * 2, sndFile.ChnSettings[nChn].dwFlags[CHN_MUTE] ? TRUE : FALSE); @@ -433,10 +433,10 @@ GetDlgItem(IDC_MOVEFXSLOT)->EnableWindow((pVstPlugin) ? TRUE : FALSE); GetDlgItem(IDC_INSERTFXSLOT)->EnableWindow((pVstPlugin) ? TRUE : FALSE); GetDlgItem(IDC_CLONEPLUG)->EnableWindow((pVstPlugin) ? TRUE : FALSE); - int n = static_cast<int>(plugin.fDryRatio*100); - wsprintf(s, "(%d%% wet, %d%% dry)", 100-n, n); + int n = static_cast<int>(plugin.fDryRatio * 100); + wsprintf(s, _T("%d%% wet, %d%% dry"), 100 - n, n); SetDlgItemText(IDC_STATIC8, s); - m_sbDryRatio.SetPos(n); + m_sbDryRatio.SetPos(100 - n); if(pVstPlugin && pVstPlugin->isInstrument()) { @@ -452,7 +452,7 @@ int gain = plugin.GetGain(); if(gain == 0) gain = 10; float value = 0.1f * (float)gain; - sprintf(s,"Gain: x %1.1f", value); + _stprintf(s, _T("Gain: x %1.1f"), value); SetDlgItemText(IDC_STATIC2, s); m_SpinMixGain.SetPos(gain); @@ -518,10 +518,10 @@ std::string libName = mpt::ToCharset(mpt::CharsetLocale, mpt::CharsetUTF8, plugin.GetLibraryName()); if(!strcmp(plugin.GetName(), "") || libName != plugin.GetName()) { - wsprintf(s, "FX%d: %s", iOut + 1, libName.c_str()); + wsprintf(s, _T("FX%d: %s"), iOut + 1, libName.c_str()); } else { - wsprintf(s, "FX%d: %s (%s)", iOut + 1, libName.c_str(), plugin.GetName()); + wsprintf(s, _T("FX%d: %s (%s)"), iOut + 1, libName.c_str(), plugin.GetName()); } int n = m_CbnOutput.AddString(s); @@ -736,10 +736,9 @@ } - //rewbs.dryRatio if ((pScrollBar) && (pScrollBar->m_hWnd == m_sbDryRatio.m_hWnd)) { - int n = m_sbDryRatio.GetPos(); + int n = 100 - m_sbDryRatio.GetPos(); if ((n >= 0) && (n <= 100) && (m_nCurrentPlugin < MAX_MIXPLUGINS)) { CSoundFile *pSndFile = pModDoc->GetSoundFile(); @@ -747,14 +746,13 @@ if(plugin.pMixPlugin) { - wsprintf(s, "(%d%% wet, %d%% dry)", 100 - n, n); + wsprintf(s, "%d%% wet, %d%% dry", 100 - n, n); SetDlgItemText(IDC_STATIC8, s); plugin.fDryRatio = static_cast<float>(n) / 100.0f; SetPluginModified(); } } } - //end rewbs.dryRatio if (bUpdate) pModDoc->UpdateAllViews(this, GeneralHint(nChn).Channels()); UnlockControls(); @@ -793,7 +791,7 @@ { CModDoc *pModDoc = GetDocument(); CSoundFile *pSndFile = pModDoc->GetSoundFile(); - CHAR s[32]; + TCHAR s[32]; if((m_nCurrentPlugin >= MAX_MIXPLUGINS) || (!pModDoc)) return; @@ -810,11 +808,12 @@ plugin.SetGain(gain); float fValue = 0.1f * (float)gain; - sprintf(s,"Gain: x %1.1f",fValue); - SetDlgItemText(IDC_STATIC2, s); + _stprintf(s, _T("Gain: x %1.1f"), fValue); + SetDlgItemText(IDC_EDIT16, s); SetPluginModified(); } + m_SpinMixGain.SetFocus(); } CFormView::OnVScroll(nSBCode, nPos, pScrollBar); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |