BOOL CAppSettingsDlg::OnInitDialog() { CDialog::OnInitDialog(); m_midesk_update_period_edit.SetLimitText(4); m_midesk_update_period_spin.SetBuddy(&m_midesk_update_period_edit); m_midesk_update_period_spin.SetRangeAndDelta(10,1000,10); m_dv_update_period_edit.SetLimitText(4); m_dv_update_period_spin.SetBuddy(&m_dv_update_period_edit); m_dv_update_period_spin.SetRangeAndDelta(10,1000,10); m_tachometer_max_edit.SetLimitText(5); m_tachometer_max_spin.SetBuddy(&m_tachometer_max_edit); m_tachometer_max_spin.SetRangeAndDelta(1000, 15000, 10); m_pressure_max_edit.SetLimitText(5); m_pressure_max_spin.SetBuddy(&m_pressure_max_edit); m_pressure_max_spin.SetRangeAndDelta(50, 500, 10); m_wheel_pulses_edit.SetLimitText(5); m_wheel_pulses_edit.SetDecimalPlaces(5); m_wheel_pulses_spin.SetBuddy(&m_wheel_pulses_edit); m_wheel_pulses_spin.SetRangeAndDelta(0, 30000, 1); if (m_OnActivate) m_OnActivate(); //информируем слушателя о том что мы готовы к приему данных UpdateData(FALSE); OnAppSettingsLogfolderUseappfolder(); OnAppSettingsLogfolderUseDVFeatures(); return TRUE; // return TRUE unless you set the focus to a control }
BOOL CMapImpExpDlg::OnInitDialog() { Super::OnInitDialog(); if (m_OnActivate) m_OnActivate(); CloneWndFont(&m_exchange_button, &m_exbtnFont, 16, true); m_exchange_button.SetFont(&m_exbtnFont); //create a tooltip control and assign tooltips mp_ttc.reset(new CToolTipCtrlEx()); VERIFY(mp_ttc->Create(this, WS_POPUP | TTS_ALWAYSTIP | TTS_BALLOON)); //ignition VERIFY(mp_ttc->AddWindow(&m_fwd_flags_buttons[FLAG_START_MAP], MLL::GetString(IDS_MAP_IMPEXP_STARTMAP_FLAG_TT))); VERIFY(mp_ttc->AddWindow(&m_fwd_flags_buttons[FLAG_IDLE_MAP], MLL::GetString(IDS_MAP_IMPEXP_STARTMAP_FLAG_TT))); VERIFY(mp_ttc->AddWindow(&m_fwd_flags_buttons[FLAG_WORK_MAP], MLL::GetString(IDS_MAP_IMPEXP_STARTMAP_FLAG_TT))); VERIFY(mp_ttc->AddWindow(&m_fwd_flags_buttons[FLAG_TEMP_MAP], MLL::GetString(IDS_MAP_IMPEXP_STARTMAP_FLAG_TT))); //fuel injection VERIFY(mp_ttc->AddWindow(&m_fwd_flags_buttons[FLAG_VE_MAP], MLL::GetString(IDS_MAP_IMPEXP_STARTMAP_FLAG_TT))); VERIFY(mp_ttc->AddWindow(&m_fwd_flags_buttons[FLAG_AFR_MAP], MLL::GetString(IDS_MAP_IMPEXP_STARTMAP_FLAG_TT))); VERIFY(mp_ttc->AddWindow(&m_fwd_flags_buttons[FLAG_CRNK_MAP], MLL::GetString(IDS_MAP_IMPEXP_STARTMAP_FLAG_TT))); VERIFY(mp_ttc->AddWindow(&m_fwd_flags_buttons[FLAG_WRMP_MAP], MLL::GetString(IDS_MAP_IMPEXP_STARTMAP_FLAG_TT))); VERIFY(mp_ttc->AddWindow(&m_fwd_flags_buttons[FLAG_DEAD_MAP], MLL::GetString(IDS_MAP_IMPEXP_STARTMAP_FLAG_TT))); VERIFY(mp_ttc->AddWindow(&m_fwd_flags_buttons[FLAG_IDLR_MAP], MLL::GetString(IDS_MAP_IMPEXP_STARTMAP_FLAG_TT))); VERIFY(mp_ttc->AddWindow(&m_fwd_flags_buttons[FLAG_IDLC_MAP], MLL::GetString(IDS_MAP_IMPEXP_STARTMAP_FLAG_TT))); VERIFY(mp_ttc->AddWindow(&m_fwd_flags_buttons[FLAG_AETPS_MAP], MLL::GetString(IDS_MAP_IMPEXP_STARTMAP_FLAG_TT))); VERIFY(mp_ttc->AddWindow(&m_fwd_flags_buttons[FLAG_AERPM_MAP], MLL::GetString(IDS_MAP_IMPEXP_STARTMAP_FLAG_TT))); VERIFY(mp_ttc->AddWindow(&m_fwd_flags_buttons[FLAG_AFTSTR_MAP], MLL::GetString(IDS_MAP_IMPEXP_STARTMAP_FLAG_TT))); //separate VERIFY(mp_ttc->AddWindow(&m_fwd_flags_buttons[FLAG_DWLCNTR_MAP], MLL::GetString(IDS_MAP_IMPEXP_DWELLCNTRL_FLAG_TT))); VERIFY(mp_ttc->AddWindow(&m_fwd_flags_buttons[FLAG_ATTEN_MAP], MLL::GetString(IDS_MAP_IMPEXP_DWELLCNTRL_FLAG_TT))); VERIFY(mp_ttc->AddWindow(&m_fwd_flags_buttons[FLAG_CTS_MAP], MLL::GetString(IDS_MAP_IMPEXP_DWELLCNTRL_FLAG_TT))); VERIFY(mp_ttc->AddWindow(&m_fwd_flags_buttons[FLAG_CHOKE_MAP], MLL::GetString(IDS_MAP_IMPEXP_DWELLCNTRL_FLAG_TT))); VERIFY(mp_ttc->AddWindow(&m_fwd_flags_buttons[FLAG_ATS_MAP], MLL::GetString(IDS_MAP_IMPEXP_DWELLCNTRL_FLAG_TT))); VERIFY(mp_ttc->AddWindow(&m_fwd_flags_buttons[FLAG_ATSAAC_MAP], MLL::GetString(IDS_MAP_IMPEXP_DWELLCNTRL_FLAG_TT))); VERIFY(mp_ttc->AddWindow(&m_fwd_flags_buttons[FLAG_GASDOSE_MAP], MLL::GetString(IDS_MAP_IMPEXP_DWELLCNTRL_FLAG_TT))); mp_ttc->SetMaxTipWidth(250); //Enable text wrapping mp_ttc->ActivateToolTips(true); return TRUE; // return TRUE unless you set the focus to a control }
void CMainFrame::OnActivateApp(BOOL bActive, DWORD dwThreadID) { ASSERT(m_OnActivate); if (m_OnActivate) m_OnActivate(bActive == TRUE); }