Include order is wxprec.h=>defs.h=>platform.h=>setup.h so remove explicit setup.h inclusion not touched by chckconf.h.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@37162 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Włodzimierz Skiba
2006-01-26 16:50:23 +00:00
parent 665b537f51
commit 521bf4ff3e
50 changed files with 311 additions and 362 deletions

View File

@@ -28,7 +28,6 @@
#ifndef WX_PRECOMP
#include <stdio.h>
#include "wx/setup.h"
#include "wx/window.h"
#include "wx/dcclient.h"
#include "wx/dcscreen.h"

View File

@@ -25,7 +25,6 @@
#endif
#ifndef WX_PRECOMP
#include "wx/setup.h"
#include "wx/list.h"
#include "wx/utils.h"
#include "wx/app.h"
@@ -1048,4 +1047,3 @@ bool wxFont::IsFixedWidth() const
return wxFontBase::IsFixedWidth();
}

View File

@@ -1,5 +1,5 @@
/////////////////////////////////////////////////////////////////////////////
// Name: gdiobj.cpp
// Name: src/msw/gdiobj.cpp
// Purpose: wxGDIObject class
// Author: Julian Smart
// Modified by:
@@ -18,7 +18,6 @@
#ifndef WX_PRECOMP
#include <stdio.h>
#include "wx/setup.h"
#include "wx/list.h"
#include "wx/utils.h"
#include "wx/app.h"
@@ -58,4 +57,3 @@ void wxGDIObject::DecrementResourceUsage(void)
};
*/

View File

@@ -1,6 +1,6 @@
/* -------------------------------------------------------------------------
* Project: GSocket (Generic Socket)
* Name: gsocket.cpp
* Name: src/msw/gsocket.cpp
* Copyright: (c) Guilhem Lavaux
* Licence: wxWindows Licence
* Author: Guillermo Rodriguez Garcia <guille@iies.es>
@@ -55,7 +55,6 @@
#ifndef __GSOCKET_STANDALONE__
# include "wx/platform.h"
# include "wx/setup.h"
#endif
#if wxUSE_SOCKETS || defined(__GSOCKET_STANDALONE__)
@@ -1562,4 +1561,3 @@ GSocketError GAddress_UNIX_GetPath(GAddress *address, char *WXUNUSED(path), size
typedef void (*wxDummy)();
#endif /* wxUSE_SOCKETS || defined(__GSOCKET_STANDALONE__) */

View File

@@ -52,7 +52,6 @@
#ifndef __GSOCKET_STANDALONE__
# include "wx/platform.h"
# include "wx/setup.h"
#endif
#if wxUSE_SOCKETS || defined(__GSOCKET_STANDALONE__)

View File

@@ -27,7 +27,6 @@
#if wxUSE_MDI && !defined(__WXUNIVERSAL__)
#ifndef WX_PRECOMP
#include "wx/setup.h"
#include "wx/frame.h"
#include "wx/menu.h"
#include "wx/app.h"

View File

@@ -1,5 +1,5 @@
/////////////////////////////////////////////////////////////////////////////
// Name: msw/metafile.cpp
// Name: src/msw/metafile.cpp
// Purpose: wxMetafileDC etc.
// Author: Julian Smart
// Modified by: VZ 07.01.00: implemented wxMetaFileDataObject
@@ -24,10 +24,6 @@
#pragma hdrstop
#endif
#ifndef WX_PRECOMP
#include "wx/setup.h"
#endif
#ifndef WX_PRECOMP
#include "wx/utils.h"
#include "wx/app.h"
@@ -197,7 +193,7 @@ wxMetafileDC::wxMetafileDC(const wxString& file, int xext, int yext, int xorg, i
m_minY = 10000;
m_maxX = -10000;
m_maxY = -10000;
if ( !file.IsEmpty() && wxFileExists(file))
if ( !file.empty() && wxFileExists(file))
wxRemoveFile(file);
m_hDC = (WXHDC) CreateMetaFile(file);
@@ -521,4 +517,3 @@ bool wxMetafileDataObject::SetData(size_t WXUNUSED(len), const void *buf)
#endif // wxUSE_DRAG_AND_DROP
#endif // wxUSE_METAFILE

View File

@@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////////
// Name: msw/ole/access.cpp
// Name: src/msw/ole/access.cpp
// Purpose: implementation of wxIAccessible and wxAccessible
// Author: Julian Smart
// Modified by:
@@ -23,11 +23,10 @@
#if defined(__BORLANDC__)
#pragma hdrstop
#endif
#ifndef WX_PRECOMP
#include "wx/window.h"
#endif
#include "wx/setup.h"
#ifndef WX_PRECOMP
#include "wx/window.h"
#endif
#if wxUSE_OLE && wxUSE_ACCESSIBILITY
@@ -962,7 +961,7 @@ STDMETHODIMP wxIAccessible::get_accDescription ( VARIANT varID, BSTR* pszDescrip
}
else
{
if (description.IsEmpty())
if (description.empty())
{
* pszDescription = NULL;
return S_FALSE;
@@ -1019,7 +1018,7 @@ STDMETHODIMP wxIAccessible::get_accHelp ( VARIANT varID, BSTR* pszHelp)
}
else
{
if (helpString.IsEmpty())
if (helpString.empty())
{
* pszHelp = NULL;
return S_FALSE;
@@ -1124,7 +1123,7 @@ STDMETHODIMP wxIAccessible::get_accKeyboardShortcut ( VARIANT varID, BSTR* pszKe
}
else
{
if (keyboardShortcut.IsEmpty())
if (keyboardShortcut.empty())
{
* pszKeyboardShortcut = NULL;
return S_FALSE;

View File

@@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////////
// Name: msw/ole/dropsrc.cpp
// Name: src/msw/ole/dropsrc.cpp
// Purpose: implementation of wxIDropSource and wxDropSource
// Author: Vadim Zeitlin
// Modified by:
@@ -23,11 +23,10 @@
#if defined(__BORLANDC__)
#pragma hdrstop
#endif
#ifndef WX_PRECOMP
#include "wx/window.h"
#endif
#include "wx/setup.h"
#ifndef WX_PRECOMP
#include "wx/window.h"
#endif
#if wxUSE_OLE && wxUSE_DRAG_AND_DROP

View File

@@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////////
// Name: ole/droptgt.cpp
// Name: src/msw/ole/droptgt.cpp
// Purpose: wxDropTarget implementation
// Author: Vadim Zeitlin
// Modified by:
@@ -24,8 +24,6 @@
#pragma hdrstop
#endif
#include "wx/setup.h"
#if wxUSE_OLE && wxUSE_DRAG_AND_DROP
#include "wx/msw/private.h"

View File

@@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////////
// Name: ole/oleutils.cpp
// Name: src/msw/ole/oleutils.cpp
// Purpose: implementation of OLE helper functions
// Author: Vadim Zeitlin
// Modified by:
@@ -24,7 +24,6 @@
#pragma hdrstop
#endif
#include "wx/setup.h"
#include "wx/log.h"
#if wxUSE_OLE
@@ -109,9 +108,9 @@ wxBasicString::wxBasicString(const char *sz)
wxBasicString::wxBasicString(const wxString& str)
{
#if wxUSE_UNICODE
m_wzBuf = new OLECHAR[str.Length() + 1];
memcpy(m_wzBuf, str.c_str(), str.Length()*2);
m_wzBuf[str.Length()] = L'\0';
m_wzBuf = new OLECHAR[str.length() + 1];
memcpy(m_wzBuf, str.c_str(), str.length()*2);
m_wzBuf[str.length()] = L'\0';
#else
Init(str.c_str());
#endif
@@ -306,4 +305,3 @@ void wxLogRelease(const char *szInterface, ULONG cRef)
#endif
// wxUSE_OLE

View File

@@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////////
// Name: ole/uuid.cpp
// Name: src/msw/ole/uuid.cpp
// Purpose: implements Uuid class, see uuid.h for details
// Author: Vadim Zeitlin
// Modified by:
@@ -20,8 +20,6 @@
#pragma hdrstop
#endif
#include "wx/setup.h"
#if wxUSE_OLE && ( wxUSE_DRAG_AND_DROP || (defined(__WXDEBUG__) && wxUSE_DATAOBJ) )
// standard headers

View File

@@ -18,7 +18,6 @@
#ifndef WX_PRECOMP
#include <stdio.h>
#include "wx/setup.h"
#include "wx/list.h"
#include "wx/utils.h"
#include "wx/app.h"

View File

@@ -1,5 +1,5 @@
/////////////////////////////////////////////////////////////////////////////
// Name: penwin.cpp
// Name: src/msw/penwin.cpp
// Purpose: PenWindows code
// Author: Julian Smart
// Modified by:
@@ -17,8 +17,7 @@
#endif
#ifndef WX_PRECOMP
#include "wx/setup.h"
#include "wx/window.h"
#include "wx/window.h"
#endif
#include "wx/msw/private.h"
@@ -113,4 +112,3 @@ void wxCleanUpPenWin(void)
}
#endif
}

View File

@@ -17,7 +17,6 @@
#endif
#ifndef WX_PRECOMP
#include "wx/setup.h"
#include "wx/frame.h"
#include "wx/settings.h"
#include "wx/dcclient.h"

View File

@@ -28,7 +28,6 @@
#include "wx/msw/wrapwin.h"
#include "wx/window.h"
#include "wx/accel.h"
#include "wx/setup.h"
#include "wx/menu.h"
#include "wx/dc.h"
#include "wx/dcclient.h"

View File

@@ -1,5 +1,5 @@
/////////////////////////////////////////////////////////////////////////////
// Name: accel.cpp
// Name: src/os2/accel.cpp
// Purpose: wxAcceleratorTable
// Author: David Webster
// Modified by:
@@ -14,7 +14,6 @@
#ifndef WX_PRECOMP
#include <stdio.h>
#include "wx/setup.h"
#include "wx/window.h"
#include "wx/app.h"
#include "wx/frame.h"

View File

@@ -14,7 +14,6 @@
#ifndef WX_PRECOMP
#include <stdio.h>
#include "wx/setup.h"
#include "wx/list.h"
#include "wx/utils.h"
#include "wx/app.h"

View File

@@ -12,10 +12,6 @@
// For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h"
#ifndef WX_PRECOMP
#include "wx/setup.h"
#endif
#if wxUSE_CLIPBOARD
#ifndef WX_PRECOMP

View File

@@ -1,5 +1,5 @@
/////////////////////////////////////////////////////////////////////////////
// Name: cursor.cpp
// Name: src/os2/cursor.cpp
// Purpose: wxCursor class
// Author: David Webster
// Modified by:
@@ -14,7 +14,6 @@
#ifndef WX_PRECOMP
#include <stdio.h>
#include "wx/setup.h"
#include "wx/list.h"
#include "wx/utils.h"
#include "wx/app.h"

View File

@@ -1,5 +1,5 @@
/////////////////////////////////////////////////////////////////////////////
// Name: font.cpp
// Name: src/os2/font.cpp
// Purpose: wxFont class
// Author: David Webster
// Modified by:
@@ -22,7 +22,6 @@
#ifndef WX_PRECOMP
#include <stdio.h>
#include "wx/setup.h"
#include "wx/list.h"
#include "wx/utils.h"
#include "wx/app.h"
@@ -1115,7 +1114,7 @@ bool wxFont::GetUnderlined() const
wxString wxFont::GetFaceName() const
{
wxCHECK_MSG( Ok(), wxT(""), wxT("invalid font") );
wxCHECK_MSG( Ok(), wxEmptyString, wxT("invalid font") );
return M_FONTDATA->GetFaceName();
} // end of wxFont::GetFaceName

View File

@@ -22,7 +22,6 @@
#include "wx/intl.h"
#include "wx/log.h"
#include "wx/event.h"
#include "wx/setup.h"
#include "wx/frame.h"
#include "wx/menu.h"
#include "wx/app.h"

View File

@@ -1,5 +1,5 @@
/////////////////////////////////////////////////////////////////////////////
// Name: metafile.cpp
// Name: src/os2/metafile.cpp
// Purpose: wxMetaFile, wxMetaFileDC etc. These classes are optional.
// Author: David Webster
// Modified by:
@@ -12,10 +12,6 @@
// For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h"
#ifndef WX_PRECOMP
#include "wx/setup.h"
#endif
#if wxUSE_METAFILE
#ifndef WX_PRECOMP
@@ -62,7 +58,7 @@ wxMetafile::wxMetafile(const wxString& file)
M_METAFILEDATA->m_windowsMappingMode = wxMM_ANISOTROPIC;
M_METAFILEDATA->m_metafile = 0;
if (!file.IsNull() && (file.Cmp(wxT("")) == 0))
if (!file.empty())
M_METAFILEDATA->m_metafile = (WXHANDLE)0; // TODO: GetMetaFile(file);
}
@@ -144,7 +140,7 @@ wxMetafileDC::wxMetafileDC(const wxString& file)
// TODO
/*
if (!file.IsNull() && (file != wxT("")))
if (!file.empty())
m_hDC = (WXHDC) CreateMetaFile(file);
else
m_hDC = (WXHDC) CreateMetaFile(NULL);
@@ -170,7 +166,7 @@ wxMetafileDC::wxMetafileDC( const wxString& file,
m_minY = 10000;
m_maxX = -10000;
m_maxY = -10000;
if (file != wxT("") && wxFileExists(file))
if (!file.empty() && wxFileExists(file))
wxRemoveFile(file);
// m_hDC = (WXHDC) CreateMetaFile(file);

View File

@@ -15,7 +15,6 @@
#ifndef WX_PRECOMP
#include <stdio.h>
#include "wx/defs.h"
#include "wx/setup.h"
#include "wx/string.h"
#include "wx/os2/private.h"
#include "wx/palette.h"

View File

@@ -13,13 +13,12 @@
#include "wx/wxprec.h"
#ifndef WX_PRECOMP
#include <stdio.h>
#include "wx/setup.h"
#include "wx/list.h"
#include "wx/utils.h"
#include "wx/app.h"
#include "wx/pen.h"
#include "wx/log.h"
#include <stdio.h>
#include "wx/list.h"
#include "wx/utils.h"
#include "wx/app.h"
#include "wx/pen.h"
#include "wx/log.h"
#endif
#include "wx/os2/private.h"

View File

@@ -12,11 +12,10 @@
#include "wx/wxprec.h"
#ifndef WX_PRECOMP
#include <stdio.h>
#include "wx/setup.h"
#include "wx/list.h"
#include "wx/utils.h"
#include "wx/app.h"
#include <stdio.h>
#include "wx/list.h"
#include "wx/utils.h"
#include "wx/app.h"
#endif
#if wxUSE_PRINTING_ARCHITECTURE

View File

@@ -14,7 +14,6 @@
#ifndef WX_PRECOMP
#include <stdio.h>
#include "wx/setup.h"
#include "wx/wxchar.h"
#include "wx/string.h"
#include "wx/bitmap.h"
@@ -620,11 +619,9 @@ void wxRadioBox::GetSize( int* pnWidth, int* pnHeight ) const
} // end of wxRadioBox::GetSize
// Find string for position
wxString wxRadioBox::GetString(
int nNum
) const
wxString wxRadioBox::GetString( int nNum ) const
{
wxCHECK_MSG( IsValid(nNum), wxString(""), wxT("invalid radiobox index") );
wxCHECK_MSG( IsValid(nNum), wxEmptyString, wxT("invalid radiobox index") );
return wxGetWindowText(m_ahRadioButtons[nNum]);
} // end of wxRadioBox::GetString
@@ -656,7 +653,7 @@ wxSize wxRadioBox::GetTotalButtonSize( const wxSize& rSizeBtn ) const
// And also wide enough for its label
//
wxString sStr = wxGetWindowText(GetHwnd());
if (!sStr.IsEmpty())
if (!sStr.empty())
{
GetTextExtent( sStr
,&nWidthLabel

View File

@@ -1,5 +1,5 @@
/////////////////////////////////////////////////////////////////////////////
// Name: radiobut.cpp
// Name: src/os2/radiobut.cpp
// Purpose: wxRadioButton
// Author: David Webster
// Modified by:
@@ -17,12 +17,11 @@
#endif
#ifndef WX_PRECOMP
#include <stdio.h>
#include "wx/setup.h"
#include "wx/radiobut.h"
#include "wx/brush.h"
#include "wx/dcscreen.h"
#include "wx/settings.h"
#include <stdio.h>
#include "wx/radiobut.h"
#include "wx/brush.h"
#include "wx/dcscreen.h"
#include "wx/settings.h"
#endif
#include "wx/os2/private.h"

View File

@@ -1,5 +1,5 @@
/////////////////////////////////////////////////////////////////////////////
// Name: timer.cpp
// Name: src/os2/timer.cpp
// Purpose: wxTimer implementation
// Author: David Webster
// Modified by:
@@ -12,16 +12,14 @@
// For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h"
#include "wx/window.h"
#include "wx/os2/private.h"
#ifndef WX_PRECOMP
#include "wx/setup.h"
#include "wx/window.h"
#include "wx/list.h"
#include "wx/event.h"
#include "wx/app.h"
#endif
#include "wx/os2/private.h"
#include "wx/intl.h"
#include "wx/log.h"
@@ -206,4 +204,3 @@ ULONG wxTimerProc(
wxProcessTimer(*(node->second));
return 0;
}

View File

@@ -1,5 +1,5 @@
/////////////////////////////////////////////////////////////////////////////
// Name: utilsexec.cpp
// Name: src/os2/utilsexec.cpp
// Purpose: Various utilities
// Author: David Webster
// Modified by:
@@ -13,10 +13,9 @@
#include "wx/wxprec.h"
#ifndef WX_PRECOMP
#include "wx/setup.h"
#include "wx/utils.h"
#include "wx/app.h"
#include "wx/intl.h"
#include "wx/utils.h"
#include "wx/app.h"
#include "wx/intl.h"
#endif
#include "wx/log.h"

View File

@@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////////
// Name: os2/utilsgui.cpp
// Name: src/os2/utilsgui.cpp
// Purpose: Various utility functions only available in GUI
// Author: David Webster
// Modified by:
@@ -25,7 +25,6 @@
#endif
#ifndef WX_PRECOMP
#include "wx/setup.h"
#include "wx/utils.h"
#include "wx/app.h"
#include "wx/cursor.h"
@@ -69,7 +68,7 @@ bool wxWriteResource(
HAB hab = 0;
HINI hIni = 0;
if (rFile != "")
if (!rFile.empty())
{
hIni = ::PrfOpenProfile(hab, (PSZ)WXSTRINGCAST rFile);
if (hIni != 0L)
@@ -153,7 +152,7 @@ bool wxGetResource(
wxChar zDefunkt[] = _T("$$default");
char zBuf[1000];
if (rFile != "")
if (!rFile.empty())
{
hIni = ::PrfOpenProfile(hab, (PSZ)WXSTRINGCAST rFile);
if (hIni != 0L)
@@ -512,9 +511,7 @@ wxToolkitInfo & wxGUIAppTraits::GetToolkitInfo()
// window information functions
// ---------------------------------------------------------------------------
wxString WXDLLEXPORT wxGetWindowText(
WXHWND hWnd
)
wxString WXDLLEXPORT wxGetWindowText( WXHWND hWnd )
{
wxString vStr;
@@ -527,9 +524,7 @@ wxString WXDLLEXPORT wxGetWindowText(
return vStr;
}
wxString WXDLLEXPORT wxGetWindowClass(
WXHWND hWnd
)
wxString WXDLLEXPORT wxGetWindowClass( WXHWND hWnd )
{
wxString vStr;
if ( hWnd )

View File

@@ -20,7 +20,6 @@
#include <os2.h>
#include "wx/window.h"
#include "wx/accel.h"
#include "wx/setup.h"
#include "wx/menu.h"
#include "wx/dc.h"
#include "wx/dcclient.h"

View File

@@ -24,10 +24,6 @@
#pragma hdrstop
#endif
#ifndef WX_PRECOMP
#include "wx/setup.h"
#endif
#if wxUSE_CLIPBOARD
#ifndef WX_PRECOMP
@@ -203,4 +199,3 @@ bool wxClipboard::GetData( wxDataObject& data )
}
#endif // wxUSE_CLIPBOARD

View File

@@ -28,7 +28,6 @@
#ifndef WX_PRECOMP
#include <stdio.h>
#include "wx/setup.h"
#include "wx/window.h"
#include "wx/dcclient.h"
#include "wx/dcscreen.h"

View File

@@ -25,7 +25,6 @@
#endif
#ifndef WX_PRECOMP
#include "wx/setup.h"
#include "wx/list.h"
#include "wx/utils.h"
#include "wx/app.h"
@@ -523,4 +522,3 @@ bool wxFont::IsFixedWidth() const
{
return false;
}

View File

@@ -18,7 +18,6 @@
#ifndef WX_PRECOMP
#include <stdio.h>
#include "wx/setup.h"
#include "wx/list.h"
#include "wx/utils.h"
#include "wx/app.h"
@@ -38,4 +37,3 @@ void wxGDIObject::DecrementResourceUsage(void)
};
*/

View File

@@ -27,7 +27,6 @@
#if wxUSE_MDI && !defined(__WXUNIVERSAL__)
#ifndef WX_PRECOMP
#include "wx/setup.h"
#include "wx/frame.h"
#include "wx/menu.h"
#include "wx/app.h"
@@ -407,4 +406,3 @@ static void UnpackMDIActivate(WXWPARAM wParam, WXLPARAM lParam,
}
#endif // wxUSE_MDI && !defined(__WXUNIVERSAL__)

View File

@@ -24,10 +24,6 @@
#pragma hdrstop
#endif
#ifndef WX_PRECOMP
#include "wx/setup.h"
#endif
#ifndef WX_PRECOMP
#include "wx/utils.h"
#include "wx/app.h"
@@ -190,4 +186,3 @@ bool wxMetafileDataObject::SetData(size_t WXUNUSED(len), const void *buf)
#endif // wxUSE_DRAG_AND_DROP
#endif // wxUSE_METAFILE

View File

@@ -17,12 +17,11 @@
#endif
#ifndef WX_PRECOMP
#include <stdio.h>
#include "wx/setup.h"
#include "wx/list.h"
#include "wx/utils.h"
#include "wx/app.h"
#include "wx/pen.h"
#include <stdio.h>
#include "wx/list.h"
#include "wx/utils.h"
#include "wx/app.h"
#include "wx/pen.h"
#endif
static int wx2msPenStyle(int wx_style);

View File

@@ -17,7 +17,6 @@
#endif
#ifndef WX_PRECOMP
#include "wx/setup.h"
#include "wx/frame.h"
#include "wx/settings.h"
#include "wx/dcclient.h"
@@ -269,4 +268,3 @@ void wxStatusBarPalm::DoMoveWindow(int x, int y, int width, int height)
}
#endif // wxUSE_NATIVE_STATUSBAR

View File

@@ -27,7 +27,6 @@
#ifndef WX_PRECOMP
#include "wx/window.h"
#include "wx/accel.h"
#include "wx/setup.h"
#include "wx/menu.h"
#include "wx/dc.h"
#include "wx/dcclient.h"

View File

@@ -1,5 +1,5 @@
// -*- c++ -*- ////////////////////////////////////////////////////////////////
// Name: unix/dialup.cpp
// Name: src/unix/dialup.cpp
// Purpose: Network related wxWidgets classes and functions
// Author: Karsten Ball<6C>der
// Modified by:
@@ -12,8 +12,6 @@
// for compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h"
#include "wx/setup.h"
#if wxUSE_DIALUP_MANAGER
#ifndef WX_PRECOMP
@@ -400,7 +398,7 @@ void wxDialUpManagerImpl::DisableAutoCheckOnlineStatus()
void wxDialUpManagerImpl::SetWellKnownHost(const wxString& hostname, int portno)
{
if(hostname.Length() == 0)
if(hostname.length() == 0)
{
m_BeaconHost = WXDIALUP_MANAGER_DEFAULT_BEACONHOST;
m_BeaconPort = 80;
@@ -409,7 +407,7 @@ void wxDialUpManagerImpl::SetWellKnownHost(const wxString& hostname, int portno)
// does hostname contain a port number?
wxString port = hostname.After(wxT(':'));
if(port.Length())
if(port.length())
{
m_BeaconHost = hostname.Before(wxT(':'));
m_BeaconPort = wxAtoi(port);

View File

@@ -1,5 +1,5 @@
/////////////////////////////////////////////////////////////////////////////
// Name: sound.cpp
// Name: src/unix/sound.cpp
// Purpose: wxSound
// Author: Marcel Rasche, Vaclav Slavik
// Modified by:
@@ -12,8 +12,6 @@
// for compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h"
#include "wx/setup.h"
#if defined(__BORLANDC__)
#pragma hdrstop
#endif

View File

@@ -1,5 +1,5 @@
/////////////////////////////////////////////////////////////////////////////
// Name: sound_sdl.cpp
// Name: src/unix/sound_sdl.cpp
// Purpose: wxSound backend using SDL
// Author: Vaclav Slavik
// Modified by:
@@ -12,8 +12,6 @@
// for compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h"
#include "wx/setup.h"
#if defined(__BORLANDC__)
#pragma hdrstop
#endif

View File

@@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////////
// Name: dnd.cpp
// Name: src/x11/dnd.cpp
// Purpose: wxDropTarget, wxDropSource classes
// Author: Julian Smart
// Id: $Id$
@@ -7,7 +7,12 @@
// Licence: wxWindows licence
///////////////////////////////////////////////////////////////////////////////
#include "wx/setup.h"
// for compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h"
#if defined(__BORLANDC__)
#pragma hdrstop
#endif
#if wxUSE_DRAG_AND_DROP
@@ -44,14 +49,14 @@ wxDropTarget::~wxDropTarget()
bool wxTextDropTarget::OnDrop( long x, long y, const void *data, size_t WXUNUSED(size) )
{
OnDropText( x, y, (const char*)data );
return TRUE;
return true;
}
bool wxTextDropTarget::OnDropText( long x, long y, const char *psz )
{
wxLogDebug( "Got dropped text: %s.", psz );
wxLogDebug( "At x: %d, y: %d.", (int)x, (int)y );
return TRUE;
return true;
}
size_t wxTextDropTarget::GetFormatCount() const
@@ -77,7 +82,7 @@ bool wxFileDropTarget::OnDropFiles( long x, long y, size_t nFiles, const char *
{
wxLogDebug( aszFiles[i] );
}
return TRUE;
return true;
}
bool wxFileDropTarget::OnDrop(long x, long y, const void *data, size_t size )
@@ -88,7 +93,7 @@ bool wxFileDropTarget::OnDrop(long x, long y, const void *data, size_t size )
for (i = 0; i < size; i++)
if (text[i] == 0) number++;
if (number == 0) return TRUE;
if (number == 0) return true;
char **files = new char*[number];
@@ -136,7 +141,7 @@ wxDropSource::wxDropSource( wxWindow *win )
wxDropSource::wxDropSource( wxDataObject &data, wxWindow *win )
{
#if 0
g_blockEventsOnDrag = TRUE;
g_blockEventsOnDrag = true;
m_window = win;
m_widget = win->m_widget;

View File

@@ -1,5 +1,5 @@
/////////////////////////////////////////////////////////////////////////////
// Name: glcanvas.cpp
// Name: src/x11/glcanvas.cpp
// Purpose: wxGLCanvas, for using OpenGL with wxWidgets
// Uses the GLX extension.
// Author: Julian Smart and Wolfram Gloger
@@ -10,7 +10,12 @@
// Licence: wxWindows licence
/////////////////////////////////////////////////////////////////////////////
#include "wx/setup.h"
// for compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h"
#if defined(__BORLANDC__)
#pragma hdrstop
#endif
#if wxUSE_GLCANVAS
@@ -46,7 +51,8 @@ static inline WXWindow wxGetClientAreaWindow(wxWindow* win)
static int bitcount( unsigned long n )
{
int bits;
for (bits=0; n>0;) {
for (bits=0; n>0;)
{
if(n & 1) bits++;
n = n >> 1;
}
@@ -254,9 +260,10 @@ bool wxGLCanvas::Create( wxWindow *parent,
Display* display = (Display*) wxGetDisplay();
// Check for the presence of the GLX extension
if(!glXQueryExtension(display, NULL, NULL)) {
if(!glXQueryExtension(display, NULL, NULL))
{
wxLogDebug(wxT("wxGLCanvas: GLX extension is missing\n"));
return FALSE;
return false;
}
if(attribList) {
@@ -365,7 +372,7 @@ bool wxGLCanvas::Create( wxWindow *parent,
#endif
SetCurrent();
return TRUE;
return true;
}
wxGLCanvas::~wxGLCanvas(void)
@@ -402,4 +409,3 @@ void wxGLCanvas::SetColour(const wxChar *col)
#endif
// wxUSE_GLCANVAS

View File

@@ -1,12 +1,17 @@
/* -------------------------------------------------------------------------
* Project: GSocket (Generic Socket) for WX
* Name: gsockmot.c
* Name: src/x11/gsockx11.cpp
* Purpose: GSocket: X11 part
* Licence: The wxWindows licence
* CVSID: $Id$
* ------------------------------------------------------------------------- */
#include "wx/setup.h"
// for compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h"
#if defined(__BORLANDC__)
#pragma hdrstop
#endif
#if wxUSE_SOCKETS

View File

@@ -1,5 +1,5 @@
/////////////////////////////////////////////////////////////////////////////
// Name: reparent.cpp
// Name: src/x11/reparent.cpp
// Purpose: wxWindow
// Author: Julian Smart
// Modified by:
@@ -9,6 +9,13 @@
// Licence: wxWindows licence
/////////////////////////////////////////////////////////////////////////////
// for compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h"
#if defined(__BORLANDC__)
#pragma hdrstop
#endif
// ============================================================================
// declarations
// ============================================================================
@@ -17,8 +24,6 @@
// headers
// ----------------------------------------------------------------------------
#include "wx/setup.h"
#if !wxUSE_NANOX
#include "wx/x11/reparent.h"
@@ -88,7 +93,7 @@ bool wxReparenter::Reparent(wxWindow* newParent, wxAdoptedWindow* toReparent)
&children, &numchildren) || Xerror)
{
XSetErrorHandler(old);
return TRUE;
return true;
}
if (numchildren > 0)
@@ -118,7 +123,7 @@ bool wxReparenter::Reparent(wxWindow* newParent, wxAdoptedWindow* toReparent)
}
XSetErrorHandler(old);
return TRUE;
return true;
}
// Wait for an appropriate window to be created.
@@ -142,7 +147,7 @@ bool wxReparenter::WaitAndReparent(wxWindow* newParent, wxAdoptedWindow* toRepar
WM_STATE = XInternAtom(display, "WM_STATE", False);
#ifdef __WXDEBUG__
if (!windowName.IsEmpty())
if (!windowName.empty())
wxLogDebug(_T("Waiting for window %s"), windowName.c_str());
#endif
@@ -169,7 +174,7 @@ bool wxReparenter::WaitAndReparent(wxWindow* newParent, wxAdoptedWindow* toRepar
#endif
}
}
return TRUE;
return true;
}
bool wxReparenter::ProcessXEvent(WXEvent* event)

View File

@@ -1,5 +1,5 @@
/////////////////////////////////////////////////////////////////////////////
// Name: utils.cpp
// Name: src/x11/utils.cpp
// Purpose: Various utilities
// Author: Julian Smart
// Modified by:
@@ -9,6 +9,13 @@
// Licence: wxWindows licence
/////////////////////////////////////////////////////////////////////////////
// for compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h"
#if defined(__BORLANDC__)
#pragma hdrstop
#endif
// ============================================================================
// declarations
// ============================================================================
@@ -17,7 +24,6 @@
// headers
// ----------------------------------------------------------------------------
#include "wx/setup.h"
#include "wx/utils.h"
#include "wx/app.h"
#include "wx/apptrait.h"
@@ -198,11 +204,11 @@ bool wxSetDisplay(const wxString& display_name)
{
gs_displayName = display_name;
if ( display_name.IsEmpty() )
if ( display_name.empty() )
{
gs_currentDisplay = NULL;
return TRUE;
return true;
}
else
{
@@ -211,7 +217,7 @@ bool wxSetDisplay(const wxString& display_name)
if (display)
{
gs_currentDisplay = (WXDisplay*) display;
return TRUE;
return true;
}
else
return FALSE;

View File

@@ -9,6 +9,13 @@
// Licence: wxWindows licence
/////////////////////////////////////////////////////////////////////////////
// for compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h"
#if defined(__BORLANDC__)
#pragma hdrstop
#endif
// ============================================================================
// declarations
// ============================================================================
@@ -17,7 +24,6 @@
// headers
// ----------------------------------------------------------------------------
#include "wx/setup.h"
#include "wx/menu.h"
#include "wx/dc.h"
#include "wx/dcclient.h"