MGR: clear Simple View Notices when disconnected and don't display "Fetching notices" until connected to client

This commit is contained in:
Charlie Fenton 2013-01-17 04:20:41 -08:00 committed by Oliver Bock
parent c3ed0d8103
commit 4a9f81d6ce
2 changed files with 3 additions and 5 deletions

View File

@ -550,13 +550,8 @@ wxString CNoticeListCtrl::OnGetItem(size_t i) const {
void CNoticeListCtrl::Clear() {
int oldItemCount = GetItemCount();
SetItemCount(0);
m_bNeedsReloading = true;
UpdateUI();
if (oldItemCount) { // Prevents covering Fetching Notices text
Refresh();
}
}

View File

@ -180,6 +180,7 @@ void CPanelMessages::CreateControls()
);
m_NoNoticesText->SetBackgroundColour(*wxWHITE);
m_FetchingNoticesText->Hide();
m_NoNoticesText->Hide();
m_ReloadNoticesPanel->Hide();
Layout();
@ -283,6 +284,8 @@ void CPanelMessages::OnRefresh() {
Layout();
}
}
} else {
m_pHtmlListPane->Clear();
}
// Don't call Freeze() / Thaw() here because it causes an unnecessary redraw