projects
/
wxWidgets.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
don't include unnecessary headers if we don't compile MDI at all
[wxWidgets.git]
/
src
/
generic
/
logg.cpp
diff --git
a/src/generic/logg.cpp
b/src/generic/logg.cpp
index f3b82f938c6f3a91357ba50230c594ecc689cf27..67bd5716b97a3e7c5e07590ca026b1a8ca8058f1 100644
(file)
--- a/
src/generic/logg.cpp
+++ b/
src/generic/logg.cpp
@@
-7,7
+7,7
@@
// Created: 20.09.99 (extracted from src/common/log.cpp)
// RCS-ID: $Id$
// Copyright: (c) 1998 Vadim Zeitlin <zeitlin@dptmaths.ens-cachan.fr>
// Created: 20.09.99 (extracted from src/common/log.cpp)
// RCS-ID: $Id$
// Copyright: (c) 1998 Vadim Zeitlin <zeitlin@dptmaths.ens-cachan.fr>
-// Licence: wxWindows licen
s
e
+// Licence: wxWindows licen
c
e
/////////////////////////////////////////////////////////////////////////////
// ============================================================================
/////////////////////////////////////////////////////////////////////////////
// ============================================================================
@@
-18,7
+18,9
@@
// headers
// ----------------------------------------------------------------------------
// headers
// ----------------------------------------------------------------------------
-// no #pragma implementation "log.h" because it's already in src/common/log.cpp
+#ifdef __GNUG__
+ #pragma implementation "logg.h"
+#endif
// For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h"
// For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h"
@@
-27,10
+29,6
@@
#pragma hdrstop
#endif
#pragma hdrstop
#endif
-#if !wxUSE_GUI
- #error "This file can't be compiled without GUI!"
-#endif
-
#ifndef WX_PRECOMP
#include "wx/app.h"
#include "wx/button.h"
#ifndef WX_PRECOMP
#include "wx/app.h"
#include "wx/button.h"
@@
-71,6
+69,10
@@
#include "wx/msgdlg.h"
#endif // wxUSE_LOG_DIALOG/!wxUSE_LOG_DIALOG
#include "wx/msgdlg.h"
#endif // wxUSE_LOG_DIALOG/!wxUSE_LOG_DIALOG
+#if defined(__MWERKS__) && wxUSE_UNICODE
+ #include <wtime.h>
+#endif
+
// the suffix we add to the button to show that the dialog can be expanded
#define EXPAND_SUFFIX _T(" >>")
// the suffix we add to the button to show that the dialog can be expanded
#define EXPAND_SUFFIX _T(" >>")
@@
-84,6
+86,10
@@
// allows to exclude the usage of wxDateTime
static wxString TimeStamp(const wxChar *format, time_t t)
{
// allows to exclude the usage of wxDateTime
static wxString TimeStamp(const wxChar *format, time_t t)
{
+#ifdef __WXWINCE__
+ // FIXME
+ return wxEmptyString;
+#else
wxChar buf[4096];
if ( !wxStrftime(buf, WXSIZEOF(buf), format, localtime(&t)) )
{
wxChar buf[4096];
if ( !wxStrftime(buf, WXSIZEOF(buf), format, localtime(&t)) )
{
@@
-91,6
+97,7
@@
static wxString TimeStamp(const wxChar *format, time_t t)
wxFAIL_MSG(_T("strftime() failed"));
}
return wxString(buf);
wxFAIL_MSG(_T("strftime() failed"));
}
return wxString(buf);
+#endif
}
}
@@
-196,7
+203,11
@@
void wxVLogStatus(wxFrame *pFrame, const wxChar *szFormat, va_list argptr)
wxASSERT( gs_pFrame == NULL ); // should be reset!
gs_pFrame = pFrame;
wxASSERT( gs_pFrame == NULL ); // should be reset!
gs_pFrame = pFrame;
+#ifdef __WXWINCE__
+ wxLog::OnLog(wxLOG_Status, msg, 0);
+#else
wxLog::OnLog(wxLOG_Status, msg, time(NULL));
wxLog::OnLog(wxLOG_Status, msg, time(NULL));
+#endif
gs_pFrame = (wxFrame *) NULL;
}
}
gs_pFrame = (wxFrame *) NULL;
}
}
@@
-430,8
+441,6
@@
public:
#endif // wxUSE_FILE
void OnClear(wxCommandEvent& event);
#endif // wxUSE_FILE
void OnClear(wxCommandEvent& event);
- void OnIdle(wxIdleEvent&);
-
// accessors
wxTextCtrl *TextCtrl() const { return m_pTextCtrl; }
// accessors
wxTextCtrl *TextCtrl() const { return m_pTextCtrl; }
@@
-1146,7
+1155,7
@@
static int OpenLogFile(wxFile& file, wxString *pFilename)
#endif // !(wxUSE_LOGGUI || wxUSE_LOGWINDOW)
#endif // !(wxUSE_LOGGUI || wxUSE_LOGWINDOW)
-#if wxUSE_LOG && wxUSE_
GUI && wxUSE_
TEXTCTRL
+#if wxUSE_LOG && wxUSE_TEXTCTRL
// ----------------------------------------------------------------------------
// wxLogTextCtrl implementation
// ----------------------------------------------------------------------------
// wxLogTextCtrl implementation
@@
-1173,6
+1182,5
@@
void wxLogTextCtrl::DoLogString(const wxChar *szString, time_t WXUNUSED(t))
m_pTextCtrl->AppendText(msg);
}
m_pTextCtrl->AppendText(msg);
}
-#endif // wxUSE_LOG && wxUSE_
GUI && wxUSE_
TEXTCTRL
+#endif // wxUSE_LOG && wxUSE_TEXTCTRL
-// vi:sts=4:sw=4:et