From c786f763657d6ca781f6d9cd0cb396899163c3f3 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Thu, 24 May 2001 21:36:41 +0000 Subject: [PATCH] fixed wxBase compilation git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@10318 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/unix/mimetype.cpp | 30 +++++++++++++++++------------- 1 file changed, 17 insertions(+), 13 deletions(-) diff --git a/src/unix/mimetype.cpp b/src/unix/mimetype.cpp index 5f86b8f068..a78e5ee7f5 100644 --- a/src/unix/mimetype.cpp +++ b/src/unix/mimetype.cpp @@ -1110,17 +1110,19 @@ wxString wxFileTypeImpl::GetExpandedCommand(const wxString & verb, const wxFileT return wxFileType::ExpandCommand(sTmp, params); } -bool wxFileTypeImpl::GetIcon(wxIcon *icon, wxString *iconFile /*= NULL */, - int *iconIndex /*= NULL*/) const +bool wxFileTypeImpl::GetIcon(wxIcon *icon, + wxString *iconFile /*= NULL */, + int *iconIndex /*= NULL*/) const { +#if wxUSE_GUI wxString sTmp; size_t i = 0; while ( (i < m_index.GetCount() ) && sTmp.IsEmpty() ) - { - sTmp = m_manager->m_aIcons[m_index[i]]; - i ++; - } + { + sTmp = m_manager->m_aIcons[m_index[i]]; + i ++; + } if ( sTmp.IsEmpty () ) return FALSE; wxIcon icn; @@ -1131,14 +1133,16 @@ bool wxFileTypeImpl::GetIcon(wxIcon *icon, wxString *iconFile /*= NULL */, icn = wxIcon(sTmp, wxBITMAP_TYPE_ANY); if ( icn.Ok() ) - { - *icon = icn; - if (iconFile) *iconFile = sTmp; - if (iconIndex) *iconIndex = 0; - return TRUE; - } - return FALSE; + { + *icon = icn; + if (iconFile) *iconFile = sTmp; + if (iconIndex) *iconIndex = 0; + return TRUE; } +#endif // wxUSE_GUI + + return FALSE; +} bool -- 2.45.2