Added some missing tests; replaced scrolwin.cpp with scrlwng.cpp

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@10811 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Julian Smart
2001-07-04 10:08:44 +00:00
parent 7ecf5ac7cd
commit 3e6e2754a6
11 changed files with 48 additions and 16 deletions

View File

@@ -229,6 +229,14 @@
# endif # endif
#endif /* !defined(wxUSE_LOGWINDOW) */ #endif /* !defined(wxUSE_LOGWINDOW) */
#ifndef wxUSE_LOG_DIALOG
# ifdef wxABORT_ON_CONFIG_ERROR
# error "wxUSE_LOG_DIALOG must be defined."
# else
# define wxUSE_LOG_DIALOG 0
# endif
#endif /* !defined(wxUSE_LOGWINDOW) */
#ifndef wxUSE_MDI_ARCHITECTURE #ifndef wxUSE_MDI_ARCHITECTURE
# ifdef wxABORT_ON_CONFIG_ERROR # ifdef wxABORT_ON_CONFIG_ERROR
# error "wxUSE_MDI_ARCHITECTURE must be defined." # error "wxUSE_MDI_ARCHITECTURE must be defined."
@@ -716,6 +724,17 @@
# endif # endif
#endif /* wxUSE_LOGWINDOW */ #endif /* wxUSE_LOGWINDOW */
#if wxUSE_LOG_DIALOG
# if !wxUSE_LISTCTRL
# ifdef wxABORT_ON_CONFIG_ERROR
# error "wxUSE_LOG_DIALOG requires wxUSE_LISTCTRL"
# else
# undef wxUSE_LISTCTRL
# define wxUSE_LISTCTRL 1
# endif
# endif
#endif /* wxUSE_LOG_DIALOG */
/* I wonder if we shouldn't just remove all occurrences of /* I wonder if we shouldn't just remove all occurrences of
wxUSE_DYNAMIC_CLASSES from the sources? */ wxUSE_DYNAMIC_CLASSES from the sources? */
#if !defined(wxUSE_DYNAMIC_CLASSES) || !wxUSE_DYNAMIC_CLASSES #if !defined(wxUSE_DYNAMIC_CLASSES) || !wxUSE_DYNAMIC_CLASSES

View File

@@ -425,7 +425,7 @@ private:
DECLARE_DYNAMIC_CLASS(wxGenericTreeCtrl) DECLARE_DYNAMIC_CLASS(wxGenericTreeCtrl)
}; };
#if !defined(__WXMSW__) || defined(__WIN16__) #if !defined(__WXMSW__) || defined(__WIN16__) || defined(__WXUNIVERSAL__)
/* /*
* wxTreeCtrl has to be a real class or we have problems with * wxTreeCtrl has to be a real class or we have problems with
* the run-time information. * the run-time information.

View File

@@ -1,8 +1,10 @@
#ifndef _WX_IMAGLIST_H_BASE_ #ifndef _WX_IMAGLIST_H_BASE_
#define _WX_IMAGLIST_H_BASE_ #define _WX_IMAGLIST_H_BASE_
#if defined(__WXMSW__) #if defined(__WXUNIVERSAL__)
#if defined(__WIN16__) || defined(__WXMICROWIN__) #include "wx/generic/imaglist.h"
#elif defined(__WXMSW__)
#if defined(__WIN16__)
#include "wx/generic/imaglist.h" #include "wx/generic/imaglist.h"
#else #else
#include "wx/msw/imaglist.h" #include "wx/msw/imaglist.h"

View File

@@ -241,7 +241,9 @@ private:
// include the wxListCtrl class declaration // include the wxListCtrl class declaration
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
#if defined(__WXMSW__) #if defined(__WXUNIVERSAL__)
#include "wx/generic/listctrl.h"
#elif defined(__WXMSW__)
#ifdef __WIN16__ #ifdef __WIN16__
#include "wx/generic/listctrl.h" #include "wx/generic/listctrl.h"
#else #else

View File

@@ -199,6 +199,9 @@
// Recommended setting: 1 (always) // Recommended setting: 1 (always)
#define wxUSE_LOGGUI 1 #define wxUSE_LOGGUI 1
// Recommended setting: 1 (always)
#define wxUSE_LOG_DIALOG 1
// Support for multithreaded applications: if 1, compile in thread classes // Support for multithreaded applications: if 1, compile in thread classes
// (thread.h) and make the library a bit more thread safe. Although thread // (thread.h) and make the library a bit more thread safe. Although thread
// support is quite stable by now, you may still consider recompiling the // support is quite stable by now, you may still consider recompiling the

View File

@@ -7,7 +7,9 @@
// include the platform-dependent wxTreeCtrl class // include the platform-dependent wxTreeCtrl class
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
#if defined(__WXMSW__) #if defined(__WXUNIVERSAL__)
#include "wx/generic/treectlg.h"
#elif defined(__WXMSW__)
#ifdef __WIN16__ #ifdef __WIN16__
#include "wx/generic/treectlg.h" #include "wx/generic/treectlg.h"
#else #else

View File

@@ -30,6 +30,9 @@
#define wxUSE_UNICODE 0 #define wxUSE_UNICODE 0
#define wxUSE_WCHAR_T 0 #define wxUSE_WCHAR_T 0
#define wxUSE_LOG 1 #define wxUSE_LOG 1
#define wxUSE_LOGGUI 1
#define wxUSE_LOGWINDOW 1
#define wxUSE_LOG_DIALOG 0
#define wxUSE_THREADS 0 #define wxUSE_THREADS 0
#define wxUSE_STREAMS 0 #define wxUSE_STREAMS 0
#define wxUSE_STD_IOSTREAM 0 #define wxUSE_STD_IOSTREAM 0
@@ -49,11 +52,6 @@
#define wxUSE_FS_INET 0 #define wxUSE_FS_INET 0
#define wxUSE_ZIPSTREAM 0 #define wxUSE_ZIPSTREAM 0
#define wxUSE_ZLIB 0 #define wxUSE_ZLIB 0
#define wxUSE_FILESYSTEM 0
#define wxUSE_FS_ZIP 0
#define wxUSE_FS_INET 0
#define wxUSE_ZIPSTREAM 0
#define wxUSE_ZLIB 0
#define wxUSE_APPLE_IEEE 0 #define wxUSE_APPLE_IEEE 0
#define wxUSE_FILE 1 #define wxUSE_FILE 1
#define wxUSE_FFILE 1 #define wxUSE_FFILE 1
@@ -133,6 +131,7 @@
#define wxUSE_IPC 0 #define wxUSE_IPC 0
#define wxUSE_HELP 0 #define wxUSE_HELP 0
#define wxUSE_MS_HTML_HELP 0 #define wxUSE_MS_HTML_HELP 0
#define wxUSE_WXHTML_HELP 0
#define wxUSE_RESOURCES 0 #define wxUSE_RESOURCES 0
#define wxUSE_CONSTRAINTS 1 #define wxUSE_CONSTRAINTS 1
#define wxUSE_CLIPBOARD 0 #define wxUSE_CLIPBOARD 0

View File

@@ -152,7 +152,7 @@ END_EVENT_TABLE()
// private functions // private functions
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
#if wxUSE_FILE #if wxUSE_FILE && wxUSE_FILEDLG
// pass an uninitialized file object, the function will ask the user for the // pass an uninitialized file object, the function will ask the user for the
// filename and try to open it, returns TRUE on success (file was opened), // filename and try to open it, returns TRUE on success (file was opened),
@@ -167,7 +167,7 @@ static int OpenLogFile(wxFile& file, wxString *filename = NULL);
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
// we use a global variable to store the frame pointer for wxLogStatus - bad, // we use a global variable to store the frame pointer for wxLogStatus - bad,
// but it's he easiest way // but it's the easiest way
static wxFrame *gs_pFrame; // FIXME MT-unsafe static wxFrame *gs_pFrame; // FIXME MT-unsafe
// ============================================================================ // ============================================================================
@@ -261,6 +261,7 @@ void wxLogGui::Flush()
else // more than one message else // more than one message
{ {
#if wxUSE_LOG_DIALOG #if wxUSE_LOG_DIALOG
wxLogDialog dlg(parent, wxLogDialog dlg(parent,
m_aMessages, m_aSeverity, m_aTimes, m_aMessages, m_aSeverity, m_aTimes,
title, style); title, style);
@@ -504,6 +505,7 @@ void wxLogFrame::OnCloseWindow(wxCloseEvent& WXUNUSED(event))
#if wxUSE_FILE #if wxUSE_FILE
void wxLogFrame::OnSave(wxCommandEvent& WXUNUSED(event)) void wxLogFrame::OnSave(wxCommandEvent& WXUNUSED(event))
{ {
#if wxUSE_FILEDLG
wxString filename; wxString filename;
wxFile file; wxFile file;
int rc = OpenLogFile(file, &filename); int rc = OpenLogFile(file, &filename);
@@ -532,6 +534,7 @@ void wxLogFrame::OnSave(wxCommandEvent& WXUNUSED(event))
else { else {
wxLogStatus(this, _("Log saved to the file '%s'."), filename.c_str()); wxLogStatus(this, _("Log saved to the file '%s'."), filename.c_str());
} }
#endif
} }
#endif // wxUSE_FILE #endif // wxUSE_FILE
@@ -891,6 +894,7 @@ void wxLogDialog::OnOk(wxCommandEvent& WXUNUSED(event))
void wxLogDialog::OnSave(wxCommandEvent& WXUNUSED(event)) void wxLogDialog::OnSave(wxCommandEvent& WXUNUSED(event))
{ {
#if wxUSE_FILEDLG
wxFile file; wxFile file;
int rc = OpenLogFile(file); int rc = OpenLogFile(file);
if ( rc == -1 ) if ( rc == -1 )
@@ -925,6 +929,7 @@ void wxLogDialog::OnSave(wxCommandEvent& WXUNUSED(event))
if ( !ok ) if ( !ok )
wxLogError(_("Can't save log contents to file.")); wxLogError(_("Can't save log contents to file."));
#endif
} }
#endif // wxUSE_FILE #endif // wxUSE_FILE
@@ -991,7 +996,7 @@ wxLogDialog::~wxLogDialog()
#endif // wxUSE_LOG_DIALOG #endif // wxUSE_LOG_DIALOG
#if wxUSE_FILE #if wxUSE_FILE && wxUSE_FILEDLG
// pass an uninitialized file object, the function will ask the user for the // pass an uninitialized file object, the function will ask the user for the
// filename and try to open it, returns TRUE on success (file was opened), // filename and try to open it, returns TRUE on success (file was opened),

View File

@@ -636,7 +636,7 @@ SOURCE=.\generic\sashwin.cpp
# End Source File # End Source File
# Begin Source File # Begin Source File
SOURCE=.\generic\scrolwin.cpp SOURCE=.\generic\scrlwing.cpp
# End Source File # End Source File
# Begin Source File # Begin Source File

View File

@@ -634,7 +634,7 @@ SOURCE=.\generic\sashwin.cpp
# End Source File # End Source File
# Begin Source File # Begin Source File
SOURCE=.\generic\scrolwin.cpp SOURCE=.\generic\scrlwing.cpp
# End Source File # End Source File
# Begin Source File # Begin Source File

View File

@@ -664,7 +664,7 @@ SOURCE=.\generic\sashwin.cpp
# End Source File # End Source File
# Begin Source File # Begin Source File
SOURCE=.\generic\scrolwin.cpp SOURCE=.\generic\scrlwing.cpp
# End Source File # End Source File
# Begin Source File # Begin Source File