don't make the log dialog taller than the screen (patch 457695)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@12271 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -869,7 +869,13 @@ void wxLogDialog::CreateDetailsControls()
|
||||
int y;
|
||||
GetTextExtent(_T("H"), (int*)NULL, &y, (int*)NULL, (int*)NULL, &font);
|
||||
int height = wxMax(y*(count + 3), 100);
|
||||
m_listctrl->SetSize(-1, height);
|
||||
|
||||
// if the height as computed from list items exceeds, together with the
|
||||
// actual message & controls, the screen, make it smaller
|
||||
int heightMax =
|
||||
(3*wxSystemSettings::GetSystemMetric(wxSYS_SCREEN_Y))/5 - GetSize().y;
|
||||
|
||||
m_listctrl->SetSize(-1, wxMin(height, heightMax));
|
||||
}
|
||||
|
||||
void wxLogDialog::OnListSelect(wxListEvent& event)
|
||||
|
Reference in New Issue
Block a user