X-Git-Url: http://Server1/repobrowser/?p=xestiaab%2F.git;a=blobdiff_plain;f=source%2FfrmMain.cpp;h=c062c153d3262218244a8e36471c5cb55dabef43;hp=8e6ec600739a0d9c73d3e87193d754e39ba4f981;hb=b85066836998d2e8834dc224e61e9855381671e4;hpb=c4cb141646798aeb76fff22948bcb7d155c8a7e1 diff --git a/source/frmMain.cpp b/source/frmMain.cpp index 8e6ec60..c062c15 100644 --- a/source/frmMain.cpp +++ b/source/frmMain.cpp @@ -1210,15 +1210,26 @@ void frmMain::ShowContactEditorEdit( wxCommandEvent& event ) } void frmMain::RefreshAddressBook( wxCommandEvent& event ){ - - // TODO: Check Account Type. + + // Check if ActiveAccount is empty. If not then check if + // account type is not local otherwise continue. if (!ActiveAccount.IsEmpty()){ - - frmActivityMgr *frameActMgr = static_cast(ActMgrPtr); - frameActMgr->AddTask(3, wxT(""), ActiveAccount, - wxT(""), wxT(""), wxT(""), wxT("")); - + + if (ActiveAccountType != wxT("Local")){ + + // Account type is not local. + + frmActivityMgr *frameActMgr = static_cast(ActMgrPtr); + frameActMgr->AddTask(3, wxT(""), ActiveAccount, + wxT(""), wxT(""), wxT(""), wxT("")); + + } else { + + wxMessageBox(_("The refresh address book command is not supported with this type of account."), wxT("Not supported for this type of account")); + + } + } }