本文整理匯總了C++中EnableApply函數的典型用法代碼示例。如果您正苦於以下問題:C++ EnableApply函數的具體用法?C++ EnableApply怎麽用?C++ EnableApply使用的例子?那麽, 這裏精選的函數代碼示例或許可以為您提供幫助。
在下文中一共展示了EnableApply函數的13個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的C++代碼示例。
示例1: WXUNUSED
void EffectChangePitch::OnText_PercentChange(wxCommandEvent & WXUNUSED(evt))
{
if (m_bLoopDetect)
return;
if (!m_pTextCtrl_PercentChange->GetValidator()->TransferFromWindow())
{
EnableApply(false);
return;
}
Calc_SemitonesChange_fromPercentChange();
Calc_ToPitch(); // Call *after* m_dSemitonesChange is updated.
Calc_ToFrequency();
Calc_ToOctave(); // Call after Calc_ToFrequency().
m_bLoopDetect = true;
{
Update_Choice_ToPitch();
Update_Spin_ToOctave();
Update_Text_SemitonesChange();
Update_Text_ToFrequency();
Update_Slider_PercentChange();
}
m_bLoopDetect = false;
// Success. Make sure OK and Preview are enabled, in case we disabled above during editing.
EnableApply(true);
}
示例2: nc
void EffectRepeat::DisplayNewTime()
{
long l;
wxString str;
mRepeatCount->GetValue().ToLong(&l);
NumericConverter nc(NumericConverter::TIME,
GetSelectionFormat(),
mT1 - mT0,
mProjectRate);
str = _("Current selection length: ") + nc.GetString();
mCurrentTime->SetLabel(str);
mCurrentTime->SetName(str); // fix for bug 577 (NVDA/Narrator screen readers do not read static text in dialogs)
if (l > 0) {
EnableApply(true);
repeatCount = l;
nc.SetValue((mT1 - mT0) * (repeatCount + 1));
str = _("New selection length: ") + nc.GetString();
}
else {
str = _("Warning: No repeats.");
EnableApply(false);
}
mTotalTime->SetLabel(str);
mTotalTime->SetName(str); // fix for bug 577 (NVDA/Narrator screen readers do not read static text in dialogs)
}
示例3: EnableApply
void EffectPhaser::OnFreqSlider(wxCommandEvent & evt)
{
mFreq = (double) evt.GetInt() / SCL_Freq;
if (mFreq < MIN_Freq) mFreq = MIN_Freq;
mFreqT->GetValidator()->TransferToWindow();
EnableApply(mUIParent->Validate());
}
示例4: WXUNUSED
void EffectToneGen::OnControlUpdate(wxCommandEvent & WXUNUSED(evt))
{
if (!EnableApply(mUIParent->TransferDataFromWindow()))
{
return;
}
}
示例5: EnableApply
void EffectPhaser::OnStagesSlider(wxCommandEvent & evt)
{
mStages = (evt.GetInt() / SCL_Stages) & ~1; // must be even;
mPhaseS->SetValue(mStages * SCL_Stages);
mStagesT->GetValidator()->TransferToWindow();
EnableApply(mUIParent->Validate());
}
示例6: EnableApply
void EffectBassTreble::OnGainSlider(wxCommandEvent & evt)
{
mGain = (double) evt.GetInt() / SCL_Gain;
mGainT->GetValidator()->TransferToWindow();
EnableApply(mUIParent->Validate());
}
示例7: WXUNUSED
void EffectWahwah::OnGainText(wxCommandEvent & WXUNUSED(evt))
{
if (!EnableApply(mUIParent->TransferDataFromWindow()))
{
return;
}
mOutGainS->SetValue((int) (mOutGain * SCL_OutGain));
}
示例8: WXUNUSED
void EffectScienFilter::OnStopbandRipple(wxCommandEvent & WXUNUSED(evt))
{
if (!EnableApply(mUIParent->TransferDataFromWindow()))
{
return;
}
mPanel->Refresh(false);
}
示例9: EnableApply
void EffectWahwah::OnPhaseSlider(wxCommandEvent & evt)
{
int val = ((evt.GetInt() + 5) / 10) * 10; // round to nearest multiple of 10
val = val > MAX_Phase * SCL_Phase ? MAX_Phase * SCL_Phase : val;
mPhaseS->SetValue(val);
mPhase = (double) val / SCL_Phase;
mPhaseT->GetValidator()->TransferToWindow();
EnableApply(mUIParent->Validate());
}
示例10: WXUNUSED
void EffectPhaser::OnDryWetText(wxCommandEvent & WXUNUSED(evt))
{
if (!EnableApply(mUIParent->TransferDataFromWindow()))
{
return;
}
mDryWetS->SetValue((int) (mDryWet * SCL_DryWet));
}
示例11: EnableApply
void CUCPDetail::OnUcpdAccessLogOnoff()
{
m_ucinfo->m_access_log = !m_ucinfo->m_access_log;
if (m_ucinfo->m_access_log) {
m_ucpd_access_log.SetWindowText("Access LOG ON");
} else {
m_ucpd_access_log.SetWindowText("Access LOG OFF");
}
EnableApply();
}
示例12: WXUNUSED
void EffectTruncSilence::OnControlChange(wxCommandEvent & WXUNUSED(evt))
{
mActionChoice->GetValidator()->TransferFromWindow();
UpdateUI();
if (!EnableApply(mUIParent->TransferDataFromWindow()))
{
return;
}
}
示例13: WXUNUSED
void EffectBassTreble::OnBassText(wxCommandEvent & WXUNUSED(evt))
{
double oldBass = mBass;
if (!EnableApply(mUIParent->TransferDataFromWindow()))
{
return;
}
if (mLink) UpdateGain(oldBass, kBass);
mBassS->SetValue((int) (mBass * SCL_Bass));
}