wx/wxprec.h already includes wx/defs.h (with other minor cleaning).

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@38791 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Włodzimierz Skiba
2006-04-18 09:56:17 +00:00
parent 18f3decb46
commit 7520f3da33
70 changed files with 284 additions and 392 deletions

View File

@@ -14,7 +14,6 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#include "wx/defs.h"
#include "wx/cursor.h" #include "wx/cursor.h"
/* Current cursor, in order to hang on to /* Current cursor, in order to hang on to

View File

@@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
// Name: mgl/dir.cpp // Name: src/mgl/dir.cpp
// Purpose: wxDir implementation for MGL // Purpose: wxDir implementation for MGL
// Author: Vaclav Slavik, Vadim Zeitlin // Author: Vaclav Slavik, Vadim Zeitlin
// Modified by: // Modified by:
@@ -10,14 +10,6 @@
// Licence: wxWindows licence // Licence: wxWindows licence
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
// ============================================================================
// declarations
// ============================================================================
// ----------------------------------------------------------------------------
// headers
// ----------------------------------------------------------------------------
// For compilers that support precompilation, includes "wx.h". // For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h" #include "wx/wxprec.h"
@@ -25,7 +17,13 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#include "wx/defs.h" // ============================================================================
// declarations
// ============================================================================
// ----------------------------------------------------------------------------
// headers
// ----------------------------------------------------------------------------
#ifndef __UNIX__ #ifndef __UNIX__
@@ -272,4 +270,3 @@ bool wxDir::GetNext(wxString *filename) const
} }
#endif // !__UNIX__ #endif // !__UNIX__

View File

@@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
// Name: src/unix/fontenum.cpp // Name: src/mgl/fontenum.cpp
// Purpose: wxFontEnumerator class for MGL // Purpose: wxFontEnumerator class for MGL
// Author: Vaclav Slavik // Author: Vaclav Slavik
// RCS-ID: $Id$ // RCS-ID: $Id$
@@ -7,6 +7,13 @@
// Licence: wxWindows licence // Licence: wxWindows licence
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
// For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h"
#ifdef __BORLANDC__
#pragma hdrstop
#endif
// ============================================================================ // ============================================================================
// declarations // declarations
// ============================================================================ // ============================================================================
@@ -15,14 +22,6 @@
// headers // headers
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
// For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h"
#ifdef __BORLANDC__
#pragma hdrstop
#endif
#include "wx/defs.h"
#include "wx/dynarray.h" #include "wx/dynarray.h"
#include "wx/string.h" #include "wx/string.h"
#include "wx/utils.h" #include "wx/utils.h"
@@ -45,7 +44,7 @@
bool wxFontEnumerator::EnumerateFacenames(wxFontEncoding encoding, bool wxFontEnumerator::EnumerateFacenames(wxFontEncoding encoding,
bool fixedWidthOnly) bool fixedWidthOnly)
{ {
bool found = FALSE; bool found = false;
wxMGLFontFamilyList *list = wxTheFontsManager->GetFamilyList(); wxMGLFontFamilyList *list = wxTheFontsManager->GetFamilyList();
wxMGLFontFamilyList::Node *node; wxMGLFontFamilyList::Node *node;
wxMGLFontFamily *f = NULL; wxMGLFontFamily *f = NULL;
@@ -61,9 +60,9 @@ bool wxFontEnumerator::EnumerateFacenames(wxFontEncoding encoding,
if ( (!fixedWidthOnly || f->GetInfo()->isFixed) && if ( (!fixedWidthOnly || f->GetInfo()->isFixed) &&
(encoding == wxFONTENCODING_SYSTEM || wxTestFontEncoding(info)) ) (encoding == wxFONTENCODING_SYSTEM || wxTestFontEncoding(info)) )
{ {
found = TRUE; found = true;
if ( !OnFacename(f->GetName()) ) if ( !OnFacename(f->GetName()) )
return TRUE; return true;
} }
} }
@@ -141,5 +140,5 @@ bool wxFontEnumerator::EnumerateEncodings(const wxString& family)
break; break;
} }
return TRUE; return true;
} }

View File

@@ -7,6 +7,13 @@
// Licence: wxWindows licence // Licence: wxWindows licence
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
// For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h"
#ifdef __BORLANDC__
#pragma hdrstop
#endif
// ============================================================================ // ============================================================================
// declarations // declarations
// ============================================================================ // ============================================================================
@@ -15,15 +22,7 @@
// headers // headers
// ---------------------------------------------------------------------------- // ----------------------------------------------------------------------------
// For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h"
#ifdef __BORLANDC__
#pragma hdrstop
#endif
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/defs.h"
#include "wx/toplevel.h" #include "wx/toplevel.h"
#include "wx/app.h" #include "wx/app.h"
#endif // WX_PRECOMP #endif // WX_PRECOMP

View File

@@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
// Name: bmpbuttn.cpp // Name: src/motif/bmpbuttn.cpp
// Purpose: wxBitmapButton // Purpose: wxBitmapButton
// Author: Julian Smart // Author: Julian Smart
// Modified by: // Modified by:
@@ -16,8 +16,6 @@
#define XtScreen XTSCREEN #define XtScreen XTSCREEN
#endif #endif
#include "wx/defs.h"
#include "wx/bmpbuttn.h" #include "wx/bmpbuttn.h"
#ifdef __VMS__ #ifdef __VMS__
@@ -265,4 +263,3 @@ wxSize wxBitmapButton::DoGetBestSize() const
return ret; return ret;
} }

View File

@@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
// Name: bitmap.cpp // Name: src/motif/bmpmotif.cpp
// Purpose: wxBitmap // Purpose: wxBitmap
// Author: Julian Smart, originally in bitmap.cpp // Author: Julian Smart, originally in bitmap.cpp
// Modified by: // Modified by:
@@ -17,7 +17,6 @@
#define XtDisplay XTDISPLAY #define XtDisplay XTDISPLAY
#endif #endif
#include "wx/defs.h"
#include "wx/motif/bmpmotif.h" #include "wx/motif/bmpmotif.h"
#ifdef __VMS__ #ifdef __VMS__

View File

@@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
// Name: button.cpp // Name: src/motif/button.cpp
// Purpose: wxButton // Purpose: wxButton
// Author: Julian Smart // Author: Julian Smart
// Modified by: // Modified by:
@@ -16,8 +16,6 @@
#define XtDisplay XTDISPLAY #define XtDisplay XTDISPLAY
#endif #endif
#include "wx/defs.h"
#include "wx/button.h" #include "wx/button.h"
#ifdef __VMS__ #ifdef __VMS__

View File

@@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
// Name: checkbox.cpp // Name: src/motif/checkbox.cpp
// Purpose: wxCheckBox // Purpose: wxCheckBox
// Author: Julian Smart // Author: Julian Smart
// Modified by: // Modified by:
@@ -16,8 +16,6 @@
#define XtDisplay XTDISPLAY #define XtDisplay XTDISPLAY
#endif #endif
#include "wx/defs.h"
#include "wx/checkbox.h" #include "wx/checkbox.h"
#include "wx/tglbtn.h" #include "wx/tglbtn.h"
#include "wx/utils.h" #include "wx/utils.h"

View File

@@ -18,8 +18,6 @@
#if wxUSE_CHECKLISTBOX #if wxUSE_CHECKLISTBOX
#include "wx/defs.h"
#include "wx/checklst.h" #include "wx/checklst.h"
#include "wx/arrstr.h" #include "wx/arrstr.h"

View File

@@ -21,8 +21,6 @@
#define XtDisplay XTDISPLAY #define XtDisplay XTDISPLAY
#endif #endif
#include "wx/defs.h"
#if wxUSE_CLIPBOARD #if wxUSE_CLIPBOARD
#include "wx/app.h" #include "wx/app.h"

View File

@@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
// Name: control.cpp // Name: src/motif/control.cpp
// Purpose: wxControl class // Purpose: wxControl class
// Author: Julian Smart // Author: Julian Smart
// Modified by: // Modified by:
@@ -12,8 +12,6 @@
// For compilers that support precompilation, includes "wx.h". // For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h" #include "wx/wxprec.h"
#include "wx/defs.h"
#include "wx/control.h" #include "wx/control.h"
#include "wx/panel.h" #include "wx/panel.h"
#include "wx/utils.h" #include "wx/utils.h"

View File

@@ -1,5 +1,5 @@
/////////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////
// Name: dataobj.cpp // Name: src/motif/dataobj.cpp
// Purpose: wxDataObject class // Purpose: wxDataObject class
// Author: Julian Smart // Author: Julian Smart
// Id: $Id$ // Id: $Id$
@@ -10,8 +10,6 @@
// For compilers that support precompilation, includes "wx.h". // For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h" #include "wx/wxprec.h"
#include "wx/defs.h"
#if wxUSE_CLIPBOARD #if wxUSE_CLIPBOARD
#include "wx/dataobj.h" #include "wx/dataobj.h"

View File

@@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
// Name: dc.cpp // Name: src/motif/dc.cpp
// Purpose: wxDC class // Purpose: wxDC class
// Author: Julian Smart // Author: Julian Smart
// Modified by: // Modified by:
@@ -14,9 +14,8 @@
#include "wx/dc.h" #include "wx/dc.h"
#include "wx/dcmemory.h" #include "wx/dcmemory.h"
#include "wx/defs.h"
IMPLEMENT_ABSTRACT_CLASS(wxDC, wxObject) IMPLEMENT_ABSTRACT_CLASS(wxDC, wxObject)
//----------------------------------------------------------------------------- //-----------------------------------------------------------------------------
// wxDC // wxDC
@@ -212,4 +211,3 @@ void wxDC::ComputeScaleAndOrigin()
m_scaleX = m_logicalScaleX * m_userScaleX; m_scaleX = m_logicalScaleX * m_userScaleX;
m_scaleY = m_logicalScaleY * m_userScaleY; m_scaleY = m_logicalScaleY * m_userScaleY;
} }

View File

@@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
// Name: filedlg.cpp // Name: src/motif/filedlg.cpp
// Purpose: wxFileDialog // Purpose: wxFileDialog
// Author: Julian Smart // Author: Julian Smart
// Modified by: // Modified by:
@@ -18,7 +18,6 @@
#define XtWindow XTWINDOW #define XtWindow XTWINDOW
#endif #endif
#include "wx/defs.h"
#include "wx/utils.h" #include "wx/utils.h"
#include "wx/filedlg.h" #include "wx/filedlg.h"
#include "wx/intl.h" #include "wx/intl.h"

View File

@@ -20,8 +20,6 @@
// For compilers that support precompilation, includes "wx.h". // For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h" #include "wx/wxprec.h"
#include "wx/defs.h"
#ifdef __VMS #ifdef __VMS
#pragma message disable nosimpint #pragma message disable nosimpint
#include "wx/vms_x_fix.h" #include "wx/vms_x_fix.h"
@@ -434,7 +432,7 @@ int wxFont::GetPointSize() const
wxString wxFont::GetFaceName() const wxString wxFont::GetFaceName() const
{ {
wxCHECK_MSG( Ok(), wxT(""), wxT("invalid font") ); wxCHECK_MSG( Ok(), wxEmptyString, wxT("invalid font") );
return M_FONTDATA->m_faceName ; return M_FONTDATA->m_faceName ;
} }
@@ -478,7 +476,7 @@ const wxNativeFontInfo *wxFont::GetNativeFontInfo() const
{ {
wxCHECK_MSG( Ok(), (wxNativeFontInfo *)NULL, wxT("invalid font") ); wxCHECK_MSG( Ok(), (wxNativeFontInfo *)NULL, wxT("invalid font") );
if(M_FONTDATA->m_nativeFontInfo.GetXFontName().IsEmpty()) if(M_FONTDATA->m_nativeFontInfo.GetXFontName().empty())
GetInternalFont(); GetInternalFont();
return &(M_FONTDATA->m_nativeFontInfo); return &(M_FONTDATA->m_nativeFontInfo);

View File

@@ -20,8 +20,6 @@
// For compilers that support precompilation, includes "wx.h". // For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h" #include "wx/wxprec.h"
#include "wx/defs.h"
#include "wx/menu.h" #include "wx/menu.h"
#include "wx/menuitem.h" #include "wx/menuitem.h"
#include "wx/log.h" #include "wx/log.h"
@@ -731,4 +729,3 @@ bool wxMenuBar::SetFont(const wxFont& font)
return true; return true;
} }

View File

@@ -1,5 +1,5 @@
/////////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////
// Name: menuitem.cpp // Name: src/motif/menuitem.cpp
// Purpose: wxMenuItem implementation // Purpose: wxMenuItem implementation
// Author: Julian Smart // Author: Julian Smart
// Modified by: // Modified by:
@@ -20,8 +20,6 @@
// For compilers that support precompilation, includes "wx.h". // For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h" #include "wx/wxprec.h"
#include "wx/defs.h"
#include "wx/menu.h" #include "wx/menu.h"
#include "wx/menuitem.h" #include "wx/menuitem.h"
#include "wx/utils.h" #include "wx/utils.h"
@@ -171,7 +169,7 @@ void wxMenuItem::CreateItem (WXWidget menu, wxMenuBar * menuBar,
(wxStripMenuCodes(m_text), (wxStripMenuCodes(m_text),
xmLabelGadgetClass, (Widget) menu, NULL); xmLabelGadgetClass, (Widget) menu, NULL);
} }
else if ((!m_text.IsNull() && m_text != "") && (!m_subMenu)) else if (!m_text.empty() && !m_subMenu)
{ {
wxString strName = wxStripMenuCodes(m_text); wxString strName = wxStripMenuCodes(m_text);
if (IsCheckable()) if (IsCheckable())
@@ -258,7 +256,7 @@ void wxMenuItem::DestroyItem(bool full)
; // Nothing ; // Nothing
} }
else if ((!m_text.IsNull() && (m_text != "")) && !m_subMenu) else if (!m_text.empty() && !m_subMenu)
{ {
if (m_buttonWidget) if (m_buttonWidget)
{ {
@@ -412,4 +410,3 @@ wxMenuItemDisarmCallback (Widget WXUNUSED(w), XtPointer clientData,
} }
} }
} }

View File

@@ -20,8 +20,6 @@
// For compilers that support precompilation, includes "wx.h". // For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h" #include "wx/wxprec.h"
#include "wx/defs.h"
#ifdef __VMS #ifdef __VMS
#define XtDisplay XTDISPLAY #define XtDisplay XTDISPLAY
#pragma message disable nosimpint #pragma message disable nosimpint

View File

@@ -16,8 +16,6 @@
#define XtDisplay XTDISPLAY #define XtDisplay XTDISPLAY
#endif #endif
#include "wx/defs.h"
#include "wx/radiobut.h" #include "wx/radiobut.h"
#include "wx/utils.h" #include "wx/utils.h"

View File

@@ -12,7 +12,6 @@
// For compilers that support precompilation, includes "wx.h". // For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h" #include "wx/wxprec.h"
#include "wx/defs.h"
#include "wx/scrolbar.h" #include "wx/scrolbar.h"
#ifdef __VMS__ #ifdef __VMS__

View File

@@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
// Name: slider.cpp // Name: src/motif/slider.cpp
// Purpose: wxSlider // Purpose: wxSlider
// Author: Julian Smart // Author: Julian Smart
// Modified by: // Modified by:
@@ -12,8 +12,6 @@
// For compilers that support precompilation, includes "wx.h". // For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h" #include "wx/wxprec.h"
#include "wx/defs.h"
#if wxUSE_SLIDER #if wxUSE_SLIDER
#include "wx/slider.h" #include "wx/slider.h"

View File

@@ -12,8 +12,6 @@
// For compilers that support precompilation, includes "wx.h". // For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h" #include "wx/wxprec.h"
#include "wx/defs.h"
#if wxUSE_SPINBTN #if wxUSE_SPINBTN
#include "wx/spinbutt.h" #include "wx/spinbutt.h"

View File

@@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
// Name: statbmp.cpp // Name: src/motif/statbmp.cpp
// Purpose: wxStaticBitmap // Purpose: wxStaticBitmap
// Author: Julian Smart // Author: Julian Smart
// Modified by: // Modified by:
@@ -12,8 +12,6 @@
// For compilers that support precompilation, includes "wx.h". // For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h" #include "wx/wxprec.h"
#include "wx/defs.h"
#include "wx/statbmp.h" #include "wx/statbmp.h"
#ifdef __VMS__ #ifdef __VMS__
@@ -156,4 +154,3 @@ void wxStaticBitmap::ChangeForegroundColour()
m_bitmapCache.SetColoursChanged(); m_bitmapCache.SetColoursChanged();
wxWindow::ChangeForegroundColour(); wxWindow::ChangeForegroundColour();
} }

View File

@@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
// Name: statbox.cpp // Name: src/motif/statbox.cpp
// Purpose: wxStaticBox // Purpose: wxStaticBox
// Author: Julian Smart // Author: Julian Smart
// Modified by: // Modified by:
@@ -16,8 +16,6 @@
#define XtDisplay XTDISPLAY #define XtDisplay XTDISPLAY
#endif #endif
#include "wx/defs.h"
#include "wx/statbox.h" #include "wx/statbox.h"
#include "wx/utils.h" #include "wx/utils.h"
@@ -101,8 +99,7 @@ bool wxStaticBox::Create(wxWindow *parent, wxWindowID id,
// XmNshadowType, XmSHADOW_IN, // XmNshadowType, XmSHADOW_IN,
NULL); NULL);
bool hasLabel = (!label.IsNull() && !label.IsEmpty()) ; if (!label.empty())
if (hasLabel)
{ {
wxString label1(wxStripMenuCodes(label)); wxString label1(wxStripMenuCodes(label));
wxXmString text(label1); wxXmString text(label1);

View File

@@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
// Name: stattext.cpp // Name: src/motif/stattext.cpp
// Purpose: wxStaticText // Purpose: wxStaticText
// Author: Julian Smart // Author: Julian Smart
// Modified by: // Modified by:
@@ -16,8 +16,6 @@
#define XtDisplay XTDISPLAY #define XtDisplay XTDISPLAY
#endif #endif
#include "wx/defs.h"
#if wxUSE_STATTEXT #if wxUSE_STATTEXT
#include "wx/stattext.h" #include "wx/stattext.h"

View File

@@ -24,8 +24,6 @@
#define XtParent XTPARENT #define XtParent XTPARENT
#endif #endif
#include "wx/defs.h"
#include <sys/types.h> #include <sys/types.h>
#include <sys/stat.h> #include <sys/stat.h>
#include <ctype.h> #include <ctype.h>
@@ -488,7 +486,7 @@ void wxTextCtrl::ShowPosition(long pos)
int wxTextCtrl::GetLineLength(long lineNo) const int wxTextCtrl::GetLineLength(long lineNo) const
{ {
wxString str = GetLineText (lineNo); wxString str = GetLineText (lineNo);
return (int) str.Length(); return (int) str.length();
} }
wxString wxTextCtrl::GetLineText(long lineNo) const wxString wxTextCtrl::GetLineText(long lineNo) const

View File

@@ -16,9 +16,7 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#ifndef WX_PRECOMP #if wxUSE_MIMETYPE
#include "wx/defs.h"
#endif
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/string.h" #include "wx/string.h"
@@ -27,8 +25,6 @@
#endif #endif
#endif //WX_PRECOMP #endif //WX_PRECOMP
#if wxUSE_MIMETYPE
#include "wx/log.h" #include "wx/log.h"
#include "wx/file.h" #include "wx/file.h"
#include "wx/intl.h" #include "wx/intl.h"

View File

@@ -26,7 +26,6 @@
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include <stdio.h> #include <stdio.h>
#include "wx/defs.h"
#include "wx/colour.h" #include "wx/colour.h"
#include "wx/gdicmn.h" #include "wx/gdicmn.h"
#include "wx/utils.h" #include "wx/utils.h"

View File

@@ -27,7 +27,6 @@
#if wxUSE_FONTDLG #if wxUSE_FONTDLG
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/defs.h"
#include "wx/utils.h" #include "wx/utils.h"
#include "wx/dialog.h" #include "wx/dialog.h"
#endif #endif

View File

@@ -24,12 +24,11 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#ifndef WX_PRECOMP
#include "wx/defs.h"
#endif
#if wxUSE_GAUGE #if wxUSE_GAUGE
#ifndef WX_PRECOMP
#endif
#include "wx/gauge.h" #include "wx/gauge.h"
#include "wx/msw/private.h" #include "wx/msw/private.h"

View File

@@ -17,11 +17,10 @@
#endif #endif
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/defs.h" #include "wx/log.h"
#endif #endif
#include "wx/filefn.h" #include "wx/filefn.h"
#include "wx/log.h"
#if wxUSE_HELP && wxUSE_MS_HTML_HELP \ #if wxUSE_HELP && wxUSE_MS_HTML_HELP \
&& wxUSE_WXHTML_HELP && !defined(__WXUNIVERSAL__) && wxUSE_WXHTML_HELP && !defined(__WXUNIVERSAL__)

View File

@@ -13,15 +13,14 @@
#include "wx/wxprec.h" #include "wx/wxprec.h"
#ifdef __BORLANDC__ #ifdef __BORLANDC__
#pragma hdrstop #pragma hdrstop
#endif
#ifndef WX_PRECOMP
#include "wx/defs.h"
#endif #endif
#if wxUSE_HELP #if wxUSE_HELP
#ifndef WX_PRECOMP
#endif
#include "wx/filefn.h" #include "wx/filefn.h"
#include "wx/msw/helpwin.h" #include "wx/msw/helpwin.h"
@@ -53,14 +52,14 @@ bool wxWinHelpController::Initialize(const wxString& filename)
bool wxWinHelpController::LoadFile(const wxString& file) bool wxWinHelpController::LoadFile(const wxString& file)
{ {
if (!file.IsEmpty()) if (!file.empty())
m_helpFile = file; m_helpFile = file;
return true; return true;
} }
bool wxWinHelpController::DisplayContents(void) bool wxWinHelpController::DisplayContents(void)
{ {
if (m_helpFile.IsEmpty()) return false; if (m_helpFile.empty()) return false;
wxString str = GetValidFilename(m_helpFile); wxString str = GetValidFilename(m_helpFile);
@@ -70,7 +69,7 @@ bool wxWinHelpController::DisplayContents(void)
bool wxWinHelpController::DisplaySection(int section) bool wxWinHelpController::DisplaySection(int section)
{ {
// Use context number // Use context number
if (m_helpFile.IsEmpty()) return false; if (m_helpFile.empty()) return false;
wxString str = GetValidFilename(m_helpFile); wxString str = GetValidFilename(m_helpFile);
@@ -79,7 +78,7 @@ bool wxWinHelpController::DisplaySection(int section)
bool wxWinHelpController::DisplayContextPopup(int contextId) bool wxWinHelpController::DisplayContextPopup(int contextId)
{ {
if (m_helpFile.IsEmpty()) return false; if (m_helpFile.empty()) return false;
wxString str = GetValidFilename(m_helpFile); wxString str = GetValidFilename(m_helpFile);
@@ -95,7 +94,7 @@ bool wxWinHelpController::DisplayBlock(long block)
bool wxWinHelpController::KeywordSearch(const wxString& k, bool wxWinHelpController::KeywordSearch(const wxString& k,
wxHelpSearchMode WXUNUSED(mode)) wxHelpSearchMode WXUNUSED(mode))
{ {
if (m_helpFile.IsEmpty()) return false; if (m_helpFile.empty()) return false;
wxString str = GetValidFilename(m_helpFile); wxString str = GetValidFilename(m_helpFile);
@@ -115,7 +114,7 @@ wxString wxWinHelpController::GetValidFilename(const wxString& file) const
wxSplitPath(file, & path, & name, & ext); wxSplitPath(file, & path, & name, & ext);
wxString fullName; wxString fullName;
if (path.IsEmpty()) if (path.empty())
fullName = name + wxT(".hlp"); fullName = name + wxT(".hlp");
else if (path.Last() == wxT('\\')) else if (path.Last() == wxT('\\'))
fullName = path + name + wxT(".hlp"); fullName = path + name + wxT(".hlp");

View File

@@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
// Name: msw/icon.cpp // Name: src/msw/icon.cpp
// Purpose: wxIcon class // Purpose: wxIcon class
// Author: Julian Smart // Author: Julian Smart
// Modified by: 20.11.99 (VZ): don't derive from wxBitmap any more // Modified by: 20.11.99 (VZ): don't derive from wxBitmap any more
@@ -151,4 +151,3 @@ bool wxIcon::LoadFile(const wxString& filename,
return handler->Load(this, filename, type, desiredWidth, desiredHeight); return handler->Load(this, filename, type, desiredWidth, desiredHeight);
} }

View File

@@ -13,12 +13,11 @@
#include "wx/wxprec.h" #include "wx/wxprec.h"
#ifdef __BORLANDC__ #ifdef __BORLANDC__
#pragma hdrstop #pragma hdrstop
#endif #endif
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/app.h" #include "wx/app.h"
#include "wx/defs.h"
#include "wx/utils.h" #include "wx/utils.h"
#include "wx/dialog.h" #include "wx/dialog.h"
#include "wx/msgdlg.h" #include "wx/msgdlg.h"
@@ -126,4 +125,3 @@ int wxMessageDialog::ShowModal()
} }
return ans; return ans;
} }

View File

@@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
// Name: msw/mslu.cpp // Name: src/msw/mslu.cpp
// Purpose: Fixes for bugs in MSLU // Purpose: Fixes for bugs in MSLU
// Author: Vaclav Slavik // Author: Vaclav Slavik
// Modified by: // Modified by:
@@ -13,12 +13,11 @@
#include "wx/wxprec.h" #include "wx/wxprec.h"
#ifdef __BORLANDC__ #ifdef __BORLANDC__
#pragma hdrstop #pragma hdrstop
#include <dir.h> #include <dir.h>
#endif #endif
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/defs.h"
#include "wx/utils.h" #include "wx/utils.h"
#endif #endif

View File

@@ -13,11 +13,9 @@
#include "wx/wxprec.h" #include "wx/wxprec.h"
#if defined(__BORLANDC__) #if defined(__BORLANDC__)
#pragma hdrstop #pragma hdrstop
#endif #endif
#include "wx/defs.h"
// Watcom C++ gives a linker error if this is compiled in. // Watcom C++ gives a linker error if this is compiled in.
// With Borland C++, all samples crash if this is compiled in. // With Borland C++, all samples crash if this is compiled in.
#if wxUSE_OLE && !(defined(__BORLANDC__) && (__BORLANDC__ < 0x520)) && !defined(__CYGWIN10__) #if wxUSE_OLE && !(defined(__BORLANDC__) && (__BORLANDC__ < 0x520)) && !defined(__CYGWIN10__)

View File

@@ -1,5 +1,5 @@
/////////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////
// Name: msw/popupwin.cpp // Name: src/msw/popupwin.cpp
// Purpose: implements wxPopupWindow for MSW // Purpose: implements wxPopupWindow for MSW
// Author: Vadim Zeitlin // Author: Vadim Zeitlin
// Modified by: // Modified by:
@@ -24,12 +24,11 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#ifndef WX_PRECOMP
#include "wx/defs.h"
#endif //WX_PRECOMP
#if wxUSE_POPUPWIN #if wxUSE_POPUPWIN
#ifndef WX_PRECOMP
#endif //WX_PRECOMP
#include "wx/popupwin.h" #include "wx/popupwin.h"
#include "wx/msw/private.h" // for GetDesktopWindow() #include "wx/msw/private.h" // for GetDesktopWindow()
@@ -112,4 +111,3 @@ bool wxPopupWindow::Show(bool show)
} }
#endif // #if wxUSE_POPUPWIN #endif // #if wxUSE_POPUPWIN

View File

@@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
// Name: printwin.cpp // Name: src/msw/printwin.cpp
// Purpose: wxWindowsPrinter framework // Purpose: wxWindowsPrinter framework
// Author: Julian Smart // Author: Julian Smart
// Modified by: // Modified by:
@@ -24,8 +24,6 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#include "wx/defs.h"
// Don't use the Windows printer if we're in wxUniv mode and using // Don't use the Windows printer if we're in wxUniv mode and using
// the PostScript architecture // the PostScript architecture
#if wxUSE_PRINTING_ARCHITECTURE && (!defined(__WXUNIVERSAL__) || !wxUSE_POSTSCRIPT_ARCHITECTURE_IN_MSW) #if wxUSE_PRINTING_ARCHITECTURE && (!defined(__WXUNIVERSAL__) || !wxUSE_POSTSCRIPT_ARCHITECTURE_IN_MSW)

View File

@@ -14,15 +14,14 @@
#include "wx/wxprec.h" #include "wx/wxprec.h"
#ifdef __BORLANDC__ #ifdef __BORLANDC__
#pragma hdrstop #pragma hdrstop
#endif #endif
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/defs.h" #include "wx/window.h"
#include "wx/window.h" #include "wx/frame.h"
#include "wx/frame.h" #include "wx/utils.h"
#include "wx/utils.h" #include "wx/menu.h"
#include "wx/menu.h"
#endif #endif
#include "wx/msw/private.h" #include "wx/msw/private.h"

View File

@@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
// Name: filefn.cpp // Name: src/msw/wince/filefn.cpp
// Purpose: File- and directory-related functions // Purpose: File- and directory-related functions
// Author: Julian Smart // Author: Julian Smart
// Modified by: // Modified by:
@@ -19,13 +19,13 @@
// For compilers that support precompilation, includes "wx.h". // For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h" #include "wx/wxprec.h"
#include "wx/defs.h"
#include "wx/file.h"
#ifdef __BORLANDC__ #ifdef __BORLANDC__
#pragma hdrstop #pragma hdrstop
#endif #endif
#include "wx/file.h"
#include <ctype.h> #include <ctype.h>
#include <stdio.h> #include <stdio.h>
#include <stdlib.h> #include <stdlib.h>

View File

@@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
// Name: combobox.cpp // Name: src/os2/combobox.cpp
// Purpose: wxComboBox class // Purpose: wxComboBox class
// Author: David Webster // Author: David Webster
// Modified by: // Modified by:
@@ -12,13 +12,12 @@
// For compilers that support precompilation, includes "wx.h". // For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h" #include "wx/wxprec.h"
#if wxUSE_COMBOBOX
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/defs.h"
#include "wx/settings.h" #include "wx/settings.h"
#endif #endif
#if wxUSE_COMBOBOX
#include "wx/combobox.h" #include "wx/combobox.h"
#include "wx/clipbrd.h" #include "wx/clipbrd.h"
#include "wx/os2/private.h" #include "wx/os2/private.h"

View File

@@ -20,14 +20,13 @@
// For compilers that support precompilation, includes "wx.h". // For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h" #include "wx/wxprec.h"
#if wxUSE_DATAOBJ
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/defs.h"
#include "wx/intl.h" #include "wx/intl.h"
#include "wx/log.h" #include "wx/log.h"
#endif #endif
#if wxUSE_DATAOBJ
#include "wx/dataobj.h" #include "wx/dataobj.h"
#include "wx/mstream.h" #include "wx/mstream.h"
#include "wx/image.h" #include "wx/image.h"

View File

@@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
// Name: dirdlg.cpp // Name: src/os2/dirdlg.cpp
// Purpose: wxDirDialog // Purpose: wxDirDialog
// Author: David Webster // Author: David Webster
// Modified by: // Modified by:
@@ -13,11 +13,10 @@
#include "wx/wxprec.h" #include "wx/wxprec.h"
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include <stdio.h> #include <stdio.h>
#include "wx/defs.h" #include "wx/utils.h"
#include "wx/utils.h" #include "wx/dialog.h"
#include "wx/dialog.h" #include "wx/dirdlg.h"
#include "wx/dirdlg.h"
#endif #endif
#include "wx/os2/private.h" #include "wx/os2/private.h"
@@ -46,4 +45,3 @@ int wxDirDialog::ShowModal()
// TODO // TODO
return wxID_CANCEL; return wxID_CANCEL;
} }

View File

@@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
// Name: fontdlg.cpp // Name: src/os2/fontdlg.cpp
// Purpose: wxFontDialog class. NOTE: you can use the generic class // Purpose: wxFontDialog class. NOTE: you can use the generic class
// if you wish, instead of implementing this. // if you wish, instead of implementing this.
// Author: David Webster // Author: David Webster
@@ -14,11 +14,10 @@
#include "wx/wxprec.h" #include "wx/wxprec.h"
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include <stdio.h> #include <stdio.h>
#include "wx/defs.h" #include "wx/utils.h"
#include "wx/utils.h" #include "wx/dialog.h"
#include "wx/dialog.h" #include "wx/math.h"
#include "wx/math.h"
#endif #endif
#include "wx/fontdlg.h" #include "wx/fontdlg.h"
@@ -98,4 +97,3 @@ int wxFontDialog::ShowModal()
} }
return wxID_CANCEL; return wxID_CANCEL;
} // end of wxFontDialg::ShowModal } // end of wxFontDialg::ShowModal

View File

@@ -13,7 +13,6 @@
#include "wx/wxprec.h" #include "wx/wxprec.h"
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/defs.h"
#include "wx/object.h" #include "wx/object.h"
#include "wx/dynarray.h" #include "wx/dynarray.h"
#include "wx/list.h" #include "wx/list.h"

View File

@@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
// Name: gauge.cpp // Name: src/os2/gauge.cpp
// Purpose: wxGauge class // Purpose: wxGauge class
// Author: David Webster // Author: David Webster
// Modified by: // Modified by:
@@ -12,9 +12,8 @@
#include "wx/wxprec.h" #include "wx/wxprec.h"
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/defs.h" #include "wx/utils.h"
#include "wx/utils.h" #include "wx/scrolwin.h"
#include "wx/scrolwin.h"
#endif #endif
#include "wx/os2/private.h" #include "wx/os2/private.h"
@@ -241,12 +240,10 @@ int wxGauge::GetValue() const
return m_nGaugePos; return m_nGaugePos;
} // end of wxGauge::GetValue } // end of wxGauge::GetValue
bool wxGauge::SetBackgroundColour( bool wxGauge::SetBackgroundColour( const wxColour& rColour )
const wxColour& rColour
)
{ {
if (!wxControl::SetBackgroundColour(rColour)) if (!wxControl::SetBackgroundColour(rColour))
return FALSE; return false;
LONG lColor = (LONG)rColour.GetPixel(); LONG lColor = (LONG)rColour.GetPixel();
@@ -255,7 +252,7 @@ bool wxGauge::SetBackgroundColour(
,sizeof(LONG) ,sizeof(LONG)
,(PVOID)&lColor ,(PVOID)&lColor
); );
return TRUE; return true;
} // end of wxGauge::SetBackgroundColour } // end of wxGauge::SetBackgroundColour
void wxGauge::SetBezelFace( void wxGauge::SetBezelFace(
@@ -264,12 +261,10 @@ void wxGauge::SetBezelFace(
{ {
} // end of wxGauge::SetBezelFace } // end of wxGauge::SetBezelFace
bool wxGauge::SetForegroundColour( bool wxGauge::SetForegroundColour( const wxColour& rColour )
const wxColour& rColour
)
{ {
if (!wxControl::SetForegroundColour(rColour)) if (!wxControl::SetForegroundColour(rColour))
return FALSE; return false;
LONG lColor = (LONG)rColour.GetPixel(); LONG lColor = (LONG)rColour.GetPixel();
@@ -279,7 +274,7 @@ bool wxGauge::SetForegroundColour(
,(PVOID)&lColor ,(PVOID)&lColor
); );
return TRUE; return true;
} // end of wxGauge::SetForegroundColour } // end of wxGauge::SetForegroundColour
void wxGauge::SetRange( void wxGauge::SetRange(

View File

@@ -9,8 +9,6 @@
// For compilers that support precompilation, includes "wx.h". // For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h" #include "wx/wxprec.h"
#include "wx/defs.h"
#if wxUSE_SOCKETS #if wxUSE_SOCKETS
#include <stdlib.h> #include <stdlib.h>

View File

@@ -12,13 +12,13 @@
// For compilers that support precompilation, includes "wx.h". // For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h" #include "wx/wxprec.h"
#if wxUSE_HELP
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/defs.h"
#endif #endif
#include "wx/os2/helpwin.h" #include "wx/os2/helpwin.h"
#if wxUSE_HELP
#include <time.h> #include <time.h>
#include "wx/os2/private.h" #include "wx/os2/private.h"
@@ -150,4 +150,5 @@ bool wxWinHelpController::Quit()
void wxWinHelpController::OnQuit() void wxWinHelpController::OnQuit()
{ {
} }
#endif // wxUSE_HELP #endif // wxUSE_HELP

View File

@@ -13,11 +13,10 @@
#include "wx/wxprec.h" #include "wx/wxprec.h"
#ifdef __BORLANDC__ #ifdef __BORLANDC__
#pragma hdrstop #pragma hdrstop
#endif #endif
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/defs.h"
#include "wx/list.h" #include "wx/list.h"
#include "wx/utils.h" #include "wx/utils.h"
#include "wx/app.h" #include "wx/app.h"

View File

@@ -14,8 +14,6 @@
// //
#include "wx/wxprec.h" #include "wx/wxprec.h"
#include "wx/defs.h"
#if wxUSE_JOYSTICK #if wxUSE_JOYSTICK
#include "wx/string.h" #include "wx/string.h"

View File

@@ -13,13 +13,12 @@
#include "wx/wxprec.h" #include "wx/wxprec.h"
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include <stdio.h> #include <stdio.h>
#include "wx/defs.h" #include "wx/utils.h"
#include "wx/utils.h" #include "wx/dialog.h"
#include "wx/dialog.h" #include "wx/app.h"
#include "wx/app.h" #include "wx/msgdlg.h"
#include "wx/msgdlg.h" #include "wx/math.h"
#include "wx/math.h"
#endif #endif
#include "wx/os2/private.h" #include "wx/os2/private.h"

View File

@@ -13,12 +13,11 @@
#include "wx/wxprec.h" #include "wx/wxprec.h"
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include <stdio.h> #include <stdio.h>
#include "wx/defs.h" #include "wx/string.h"
#include "wx/string.h" #include "wx/os2/private.h"
#include "wx/os2/private.h" #include "wx/palette.h"
#include "wx/palette.h" #include "wx/app.h"
#include "wx/app.h"
#endif #endif
#define INCL_PM #define INCL_PM

View File

@@ -13,11 +13,10 @@
#include "wx/wxprec.h" #include "wx/wxprec.h"
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include <stdio.h> #include <stdio.h>
#include "wx/defs.h" #include "wx/pen.h"
#include "wx/pen.h" #include "wx/brush.h"
#include "wx/brush.h" #include "wx/gdicmn.h"
#include "wx/gdicmn.h"
#endif #endif
#include "wx/module.h" #include "wx/module.h"

View File

@@ -25,7 +25,6 @@
#endif #endif
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/defs.h"
#include "wx/intl.h" #include "wx/intl.h"
#endif #endif

View File

@@ -27,7 +27,6 @@
#if wxUSE_FONTDLG #if wxUSE_FONTDLG
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/defs.h"
#include "wx/utils.h" #include "wx/utils.h"
#include "wx/dialog.h" #include "wx/dialog.h"
#include "wx/math.h" #include "wx/math.h"

View File

@@ -24,12 +24,11 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#ifndef WX_PRECOMP
#include "wx/defs.h"
#endif
#if wxUSE_GAUGE #if wxUSE_GAUGE
#ifndef WX_PRECOMP
#endif
#include "wx/gauge.h" #include "wx/gauge.h"
#include "wx/palmos/private.h" #include "wx/palmos/private.h"

View File

@@ -16,12 +16,11 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#ifndef WX_PRECOMP
#include "wx/defs.h"
#endif
#if wxUSE_HELP #if wxUSE_HELP
#ifndef WX_PRECOMP
#endif
#include "wx/filefn.h" #include "wx/filefn.h"
#include <time.h> #include <time.h>

View File

@@ -25,7 +25,6 @@
#endif #endif
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/defs.h"
#include "wx/list.h" #include "wx/list.h"
#include "wx/utils.h" #include "wx/utils.h"
#include "wx/app.h" #include "wx/app.h"
@@ -90,4 +89,3 @@ bool wxIcon::LoadFile(const wxString& filename,
{ {
return false; return false;
} }

View File

@@ -13,12 +13,11 @@
#include "wx/wxprec.h" #include "wx/wxprec.h"
#ifdef __BORLANDC__ #ifdef __BORLANDC__
#pragma hdrstop #pragma hdrstop
#endif #endif
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/app.h" #include "wx/app.h"
#include "wx/defs.h"
#include "wx/utils.h" #include "wx/utils.h"
#include "wx/dialog.h" #include "wx/dialog.h"
#include "wx/msgdlg.h" #include "wx/msgdlg.h"
@@ -149,4 +148,3 @@ int wxMessageDialog::ShowModal()
return wxResult; return wxResult;
} }

View File

@@ -24,12 +24,11 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#ifndef WX_PRECOMP
#include "wx/defs.h"
#endif //WX_PRECOMP
#if wxUSE_POPUPWIN #if wxUSE_POPUPWIN
#ifndef WX_PRECOMP
#endif //WX_PRECOMP
#include "wx/popupwin.h" #include "wx/popupwin.h"
#include "wx/palmos/private.h" // for GetDesktopWindow() #include "wx/palmos/private.h" // for GetDesktopWindow()
@@ -65,4 +64,3 @@ bool wxPopupWindow::Show(bool show)
} }
#endif // #if wxUSE_POPUPWIN #endif // #if wxUSE_POPUPWIN

View File

@@ -24,8 +24,6 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#include "wx/defs.h"
// Don't use the Windows printer if we're in wxUniv mode and using // Don't use the Windows printer if we're in wxUniv mode and using
// the PostScript architecture // the PostScript architecture
#if wxUSE_PRINTING_ARCHITECTURE && (!defined(__WXUNIVERSAL__) || !wxUSE_POSTSCRIPT_ARCHITECTURE_IN_MSW) #if wxUSE_PRINTING_ARCHITECTURE && (!defined(__WXUNIVERSAL__) || !wxUSE_POSTSCRIPT_ARCHITECTURE_IN_MSW)

View File

@@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////
// File: taskbar.cpp // File: src/palmos/taskbar.cpp
// Purpose: Implements wxTaskBarIcon class for manipulating icons on // Purpose: Implements wxTaskBarIcon class for manipulating icons on
// the task bar. // the task bar.
// Author: Julian Smart // Author: Julian Smart
@@ -14,15 +14,14 @@
#include "wx/wxprec.h" #include "wx/wxprec.h"
#ifdef __BORLANDC__ #ifdef __BORLANDC__
#pragma hdrstop #pragma hdrstop
#endif #endif
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
#include "wx/defs.h" #include "wx/window.h"
#include "wx/window.h" #include "wx/frame.h"
#include "wx/frame.h" #include "wx/utils.h"
#include "wx/utils.h" #include "wx/menu.h"
#include "wx/menu.h"
#endif #endif
#if defined(__WIN95__) #if defined(__WIN95__)
@@ -107,4 +106,3 @@ long wxTaskBarIcon::WindowProc(unsigned int msg,
} }
#endif // __WIN95__ #endif // __WIN95__

View File

@@ -15,10 +15,9 @@
#if wxUSE_DIALUP_MANAGER #if wxUSE_DIALUP_MANAGER
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
# include "wx/defs.h" #include "wx/string.h"
#endif // !PCH #endif // !PCH
#include "wx/string.h"
#include "wx/event.h" #include "wx/event.h"
#include "wx/dialup.h" #include "wx/dialup.h"
#include "wx/timer.h" #include "wx/timer.h"

View File

@@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
// Name: joystick.cpp // Name: src/unix/joystick.cpp
// Purpose: wxJoystick class // Purpose: wxJoystick class
// Author: Ported to Linux by Guilhem Lavaux // Author: Ported to Linux by Guilhem Lavaux
// Modified by: // Modified by:
@@ -12,8 +12,6 @@
// for compilers that support precompilation, includes "wx.h". // for compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h" #include "wx/wxprec.h"
#include "wx/defs.h"
#if wxUSE_JOYSTICK #if wxUSE_JOYSTICK
#include "wx/joystick.h" #include "wx/joystick.h"
@@ -489,4 +487,3 @@ bool wxJoystick::ReleaseCapture()
return false; return false;
} }
#endif // wxUSE_JOYSTICK #endif // wxUSE_JOYSTICK

View File

@@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
// Name: unix/mimetype.cpp // Name: src/unix/mimetype.cpp
// Purpose: classes and functions to manage MIME types // Purpose: classes and functions to manage MIME types
// Author: Vadim Zeitlin // Author: Vadim Zeitlin
// Modified by: // Modified by:
@@ -36,10 +36,6 @@
#pragma hdrstop #pragma hdrstop
#endif #endif
#ifndef WX_PRECOMP
#include "wx/defs.h"
#endif
#if wxUSE_MIMETYPE && wxUSE_FILE && wxUSE_TEXTFILE #if wxUSE_MIMETYPE && wxUSE_FILE && wxUSE_TEXTFILE
#ifndef WX_PRECOMP #ifndef WX_PRECOMP
@@ -2703,4 +2699,3 @@ static bool IsKnownUnimportantField(const wxString& fieldAll)
#endif #endif
// wxUSE_MIMETYPE && wxUSE_FILE && wxUSE_TEXTFILE // wxUSE_MIMETYPE && wxUSE_FILE && wxUSE_TEXTFILE

View File

@@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
// Name: unix/utilsunx.cpp // Name: src/unix/utilsunx.cpp
// Purpose: generic Unix implementation of many wx functions // Purpose: generic Unix implementation of many wx functions
// Author: Vadim Zeitlin // Author: Vadim Zeitlin
// Id: $Id$ // Id: $Id$
@@ -18,8 +18,9 @@
// for compilers that support precompilation, includes "wx.h". // for compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h" #include "wx/wxprec.h"
#include "wx/defs.h" #ifndef WX_PRECOMP
#include "wx/string.h" #include "wx/string.h"
#endif
#include "wx/intl.h" #include "wx/intl.h"
#include "wx/log.h" #include "wx/log.h"
@@ -280,7 +281,7 @@ long wxExecute( const wxString& command, int flags, wxProcess *process )
// split the command line in arguments // split the command line in arguments
do do
{ {
argument=wxT(""); argument = wxEmptyString;
quotechar = wxT('\0'); quotechar = wxT('\0');
// eat leading whitespace: // eat leading whitespace:
@@ -884,7 +885,7 @@ wxString wxGetOsDescription()
return wxString::FromAscii( buf ); return wxString::FromAscii( buf );
} }
wxFAIL_MSG( _T("uname failed") ); wxFAIL_MSG( _T("uname failed") );
return _T(""); return wxEmptyString;
} }
#endif // !__WXMAC__ #endif // !__WXMAC__

View File

@@ -1,5 +1,5 @@
/////////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////
// Name: dataobj.cpp // Name: src/x11/dataobj.cpp
// Purpose: wxDataObject class // Purpose: wxDataObject class
// Author: Julian Smart // Author: Julian Smart
// Id: $Id$ // Id: $Id$
@@ -7,7 +7,8 @@
// Licence: wxWindows licence // Licence: wxWindows licence
/////////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////
#include "wx/defs.h" // for compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h"
#if wxUSE_DATAOBJ #if wxUSE_DATAOBJ
@@ -196,7 +197,7 @@ bool wxFileDataObject::GetDataHere(void *buf) const
memcpy( buf, filenames.mbc_str(), filenames.Len() + 1 ); memcpy( buf, filenames.mbc_str(), filenames.Len() + 1 );
return TRUE; return true;
} }
size_t wxFileDataObject::GetDataSize() const size_t wxFileDataObject::GetDataSize() const
@@ -278,7 +279,7 @@ bool wxFileDataObject::SetData(size_t WXUNUSED(size), const void *buf)
} }
#endif // 0/1 #endif // 0/1
return TRUE; return true;
} }
void wxFileDataObject::AddFile( const wxString &filename ) void wxFileDataObject::AddFile( const wxString &filename )
@@ -323,12 +324,12 @@ bool wxBitmapDataObject::GetDataHere(void *buf) const
{ {
wxFAIL_MSG( wxT("attempt to copy empty bitmap failed") ); wxFAIL_MSG( wxT("attempt to copy empty bitmap failed") );
return FALSE; return false;
} }
memcpy(buf, m_pngData, m_pngSize); memcpy(buf, m_pngData, m_pngSize);
return TRUE; return true;
} }
bool wxBitmapDataObject::SetData(size_t size, const void *buf) bool wxBitmapDataObject::SetData(size_t size, const void *buf)
@@ -346,14 +347,14 @@ bool wxBitmapDataObject::SetData(size_t size, const void *buf)
wxPNGHandler handler; wxPNGHandler handler;
if ( !handler.LoadFile( &image, mstream ) ) if ( !handler.LoadFile( &image, mstream ) )
{ {
return FALSE; return false;
} }
m_bitmap = image; m_bitmap = image;
return m_bitmap.Ok(); return m_bitmap.Ok();
#else #else
return FALSE; return false;
#endif #endif
} }
@@ -378,4 +379,3 @@ void wxBitmapDataObject::DoConvertToPng()
} }
#endif // wxUSE_DATAOBJ #endif // wxUSE_DATAOBJ

View File

@@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
// Name: dc.cpp // Name: src/x11/dc.cpp
// Purpose: wxDC class // Purpose: wxDC class
// Author: Julian Smart // Author: Julian Smart
// Modified by: // Modified by:
@@ -9,9 +9,11 @@
// Licence: wxWindows licence // Licence: wxWindows licence
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
// for compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h"
#include "wx/dc.h" #include "wx/dc.h"
#include "wx/dcmemory.h" #include "wx/dcmemory.h"
#include "wx/defs.h"
IMPLEMENT_ABSTRACT_CLASS(wxDC, wxObject) IMPLEMENT_ABSTRACT_CLASS(wxDC, wxObject)
@@ -21,7 +23,7 @@ IMPLEMENT_ABSTRACT_CLASS(wxDC, wxObject)
wxDC::wxDC() wxDC::wxDC()
{ {
m_ok = FALSE; m_ok = false;
#if 1 #if 1
m_mm_to_pix_x = 1.0; m_mm_to_pix_x = 1.0;
@@ -33,8 +35,8 @@ wxDC::wxDC()
(double)wxGetDisplaySizeMM().GetHeight(); (double)wxGetDisplaySizeMM().GetHeight();
#endif #endif
m_needComputeScaleX = FALSE; /* not used yet */ m_needComputeScaleX = false; /* not used yet */
m_needComputeScaleY = FALSE; /* not used yet */ m_needComputeScaleY = false; /* not used yet */
m_logicalFunction = wxCOPY; m_logicalFunction = wxCOPY;
@@ -44,12 +46,12 @@ wxDC::wxDC()
m_backgroundMode = wxTRANSPARENT; m_backgroundMode = wxTRANSPARENT;
m_isInteractive = FALSE; // ??? m_isInteractive = false; // ???
} }
void wxDC::DoSetClippingRegion( wxCoord x, wxCoord y, wxCoord width, wxCoord height ) void wxDC::DoSetClippingRegion( wxCoord x, wxCoord y, wxCoord width, wxCoord height )
{ {
m_clipping = TRUE; m_clipping = true;
m_clipX1 = x; m_clipX1 = x;
m_clipY1 = y; m_clipY1 = y;
m_clipX2 = x + width; m_clipX2 = x + width;
@@ -97,8 +99,8 @@ void wxDC::SetMapMode( int mode )
} }
if (mode != wxMM_TEXT) if (mode != wxMM_TEXT)
{ {
m_needComputeScaleX = TRUE; m_needComputeScaleX = true;
m_needComputeScaleY = TRUE; m_needComputeScaleY = true;
} }
} }
@@ -185,4 +187,3 @@ void wxDC::ComputeScaleAndOrigin()
m_scaleX = m_logicalScaleX * m_userScaleX; m_scaleX = m_logicalScaleX * m_userScaleX;
m_scaleY = m_logicalScaleY * m_userScaleY; m_scaleY = m_logicalScaleY * m_userScaleY;
} }

View File

@@ -9,6 +9,9 @@
// Licence: wxWindows licence // Licence: wxWindows licence
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
// for compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h"
// ============================================================================ // ============================================================================
// declarations // declarations
// ============================================================================ // ============================================================================
@@ -26,7 +29,6 @@
#pragma message enable nosimpint #pragma message enable nosimpint
#endif #endif
#include "wx/defs.h"
#include "wx/string.h" #include "wx/string.h"
#include "wx/font.h" #include "wx/font.h"
#include "wx/gdicmn.h" #include "wx/gdicmn.h"
@@ -95,7 +97,7 @@ public:
int family = wxDEFAULT, int family = wxDEFAULT,
int style = wxDEFAULT, int style = wxDEFAULT,
int weight = wxDEFAULT, int weight = wxDEFAULT,
bool underlined = FALSE, bool underlined = false,
const wxString& faceName = wxEmptyString, const wxString& faceName = wxEmptyString,
wxFontEncoding encoding = wxFONTENCODING_DEFAULT); wxFontEncoding encoding = wxFONTENCODING_DEFAULT);
@@ -118,7 +120,7 @@ public:
void SetFaceName(const wxString& facename); void SetFaceName(const wxString& facename);
void SetEncoding(wxFontEncoding encoding); void SetEncoding(wxFontEncoding encoding);
void SetNoAntiAliasing( bool no = TRUE ) { m_noAA = no; } void SetNoAntiAliasing( bool no = true ) { m_noAA = no; }
bool GetNoAntiAliasing() const { return m_noAA; } bool GetNoAntiAliasing() const { return m_noAA; }
// and this one also modifies all the other font data fields // and this one also modifies all the other font data fields
@@ -213,7 +215,7 @@ void wxFontRefData::Init(int pointSize,
void wxFontRefData::InitFromNative() void wxFontRefData::InitFromNative()
{ {
m_noAA = FALSE; m_noAA = false;
#if wxUSE_UNICODE #if wxUSE_UNICODE
// Get native info // Get native info
@@ -273,7 +275,7 @@ void wxFontRefData::InitFromNative()
} }
// Pango description are never underlined (?) // Pango description are never underlined (?)
m_underlined = FALSE; m_underlined = false;
// Cannot we choose that // Cannot we choose that
m_encoding = wxFONTENCODING_SYSTEM; m_encoding = wxFONTENCODING_SYSTEM;
@@ -343,7 +345,7 @@ void wxFontRefData::InitFromNative()
} }
// X fonts are never underlined... // X fonts are never underlined...
m_underlined = FALSE; m_underlined = false;
// deal with font encoding // deal with font encoding
wxString wxString
@@ -550,7 +552,7 @@ bool wxFont::Create(int pointSize,
m_refData = new wxFontRefData(pointSize, family, style, weight, m_refData = new wxFontRefData(pointSize, family, style, weight,
underlined, faceName, encoding); underlined, faceName, encoding);
return TRUE; return true;
} }
#if !wxUSE_UNICODE #if !wxUSE_UNICODE
@@ -560,7 +562,7 @@ bool wxFont::Create(const wxString& fontname, wxFontEncoding enc)
if( !fontname ) if( !fontname )
{ {
*this = wxSystemSettings::GetFont( wxSYS_DEFAULT_GUI_FONT); *this = wxSystemSettings::GetFont( wxSYS_DEFAULT_GUI_FONT);
return TRUE; return true;
} }
m_refData = new wxFontRefData(); m_refData = new wxFontRefData();
@@ -653,9 +655,9 @@ bool wxFont::Create(const wxString& fontname, wxFontEncoding enc)
} }
//else: unknown encoding - may be give a warning here? //else: unknown encoding - may be give a warning here?
else else
return FALSE; return false;
} }
return TRUE; return true;
} }
#endif // !wxUSE_UNICODE #endif // !wxUSE_UNICODE
@@ -695,7 +697,7 @@ int wxFont::GetPointSize() const
wxString wxFont::GetFaceName() const wxString wxFont::GetFaceName() const
{ {
wxCHECK_MSG( Ok(), wxT(""), wxT("invalid font") ); wxCHECK_MSG( Ok(), wxEmptyString, wxT("invalid font") );
return M_FONTDATA->m_faceName; return M_FONTDATA->m_faceName;
} }
@@ -723,7 +725,7 @@ int wxFont::GetWeight() const
bool wxFont::GetUnderlined() const bool wxFont::GetUnderlined() const
{ {
wxCHECK_MSG( Ok(), FALSE, wxT("invalid font") ); wxCHECK_MSG( Ok(), false, wxT("invalid font") );
return M_FONTDATA->m_underlined; return M_FONTDATA->m_underlined;
} }
@@ -757,13 +759,13 @@ const wxNativeFontInfo *wxFont::GetNativeFontInfo() const
bool wxFont::IsFixedWidth() const bool wxFont::IsFixedWidth() const
{ {
wxCHECK_MSG( Ok(), FALSE, wxT("invalid font") ); wxCHECK_MSG( Ok(), false, wxT("invalid font") );
#if wxUSE_UNICODE #if wxUSE_UNICODE
return wxFontBase::IsFixedWidth(); return wxFontBase::IsFixedWidth();
#else #else
// Robert, is this right? HasNativeFont doesn't exist. // Robert, is this right? HasNativeFont doesn't exist.
if ( TRUE ) if ( true )
// if ( M_FONTDATA->HasNativeFont() ) // if ( M_FONTDATA->HasNativeFont() )
{ {
// the monospace fonts are supposed to have "M" in the spacing field // the monospace fonts are supposed to have "M" in the spacing field

View File

@@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
// Name: popupwin.cpp // Name: srx/x11/popupwin.cpp
// Purpose: // Purpose:
// Author: Robert Roebling // Author: Robert Roebling
// Id: $Id$ // Id: $Id$
@@ -7,11 +7,13 @@
// Licence: wxWindows licence // Licence: wxWindows licence
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
#include "wx/defs.h" // for compilers that support precompilation, includes "wx.h".
#include "wx/log.h" #include "wx/wxprec.h"
#if wxUSE_POPUPWIN #if wxUSE_POPUPWIN
#include "wx/log.h"
#include "wx/popupwin.h" #include "wx/popupwin.h"
#include "wx/app.h" #include "wx/app.h"
#include "wx/settings.h" #include "wx/settings.h"
@@ -36,7 +38,7 @@ bool wxPopupWindow::Create( wxWindow *parent, int style )
if (!CreateBase( parent, -1, wxDefaultPosition, wxDefaultSize, style, wxDefaultValidator, wxT("popup") )) if (!CreateBase( parent, -1, wxDefaultPosition, wxDefaultSize, style, wxDefaultValidator, wxT("popup") ))
{ {
wxFAIL_MSG( wxT("wxPopupWindow creation failed") ); wxFAIL_MSG( wxT("wxPopupWindow creation failed") );
return FALSE; return false;
} }
// All dialogs should really have this style // All dialogs should really have this style
@@ -61,7 +63,7 @@ bool wxPopupWindow::Create( wxWindow *parent, int style )
bool need_two_windows = bool need_two_windows =
((( wxSUNKEN_BORDER | wxRAISED_BORDER | wxSIMPLE_BORDER | wxHSCROLL | wxVSCROLL ) & m_windowStyle) != 0); ((( wxSUNKEN_BORDER | wxRAISED_BORDER | wxSIMPLE_BORDER | wxHSCROLL | wxVSCROLL ) & m_windowStyle) != 0);
#else #else
bool need_two_windows = FALSE; bool need_two_windows = false;
#endif #endif
#if wxUSE_NANOX #if wxUSE_NANOX
@@ -161,7 +163,7 @@ bool wxPopupWindow::Create( wxWindow *parent, int style )
m_clientWindow = (WXWindow) xwindow; m_clientWindow = (WXWindow) xwindow;
wxAddClientWindowToTable( xwindow, (wxWindow*) this ); wxAddClientWindowToTable( xwindow, (wxWindow*) this );
m_isShown = FALSE; m_isShown = false;
XMapWindow( xdisplay, xwindow ); XMapWindow( xdisplay, xwindow );
} }
else else
@@ -194,7 +196,7 @@ bool wxPopupWindow::Create( wxWindow *parent, int style )
m_clientWindow = (WXWindow) xwindow; m_clientWindow = (WXWindow) xwindow;
wxAddWindowToTable( xwindow, (wxWindow*) this ); wxAddWindowToTable( xwindow, (wxWindow*) this );
m_isShown = FALSE; m_isShown = false;
// XMapWindow( xdisplay, xwindow ); // XMapWindow( xdisplay, xwindow );
} }
@@ -211,7 +213,7 @@ bool wxPopupWindow::Create( wxWindow *parent, int style )
XSetWMHints( xdisplay, (Window) m_mainWindow, &wm_hints); XSetWMHints( xdisplay, (Window) m_mainWindow, &wm_hints);
#endif #endif
return TRUE; return true;
} }
void wxPopupWindow::DoMoveWindow(int x, int y, int width, int height ) void wxPopupWindow::DoMoveWindow(int x, int y, int width, int height )