make more wxFileName methods const (closes #10887)

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@61022 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin 2009-06-12 15:28:45 +00:00
parent 517add0d35
commit d9e80dce15
3 changed files with 13 additions and 13 deletions

View File

@ -243,10 +243,10 @@ public:
// (any of the pointers may be NULL)
bool SetTimes(const wxDateTime *dtAccess,
const wxDateTime *dtMod,
const wxDateTime *dtCreate);
const wxDateTime *dtCreate) const;
// set the access and modification times to the current moment
bool Touch();
bool Touch() const;
// return the last access, last modification and create times
// (any of the pointers may be NULL)
@ -265,7 +265,7 @@ public:
#if defined( __WXOSX_MAC__ ) && wxOSX_USE_CARBON
bool MacSetTypeAndCreator( wxUint32 type , wxUint32 creator ) ;
bool MacGetTypeAndCreator( wxUint32 *type , wxUint32 *creator ) ;
bool MacGetTypeAndCreator( wxUint32 *type , wxUint32 *creator ) const;
// gets the 'common' type and creator for a certain extension
static bool MacFindDefaultTypeAndCreator( const wxString& ext , wxUint32 *type , wxUint32 *creator ) ;
// registers application defined extensions and their default type and creator
@ -281,7 +281,7 @@ public:
static wxString GetCwd(const wxString& volume = wxEmptyString);
// change the current working directory
bool SetCwd();
bool SetCwd() const;
static bool SetCwd( const wxString &cwd );
// get the value of user home (Unix only mainly)
@ -358,7 +358,7 @@ public:
// the arguments
bool GetShortcutTarget(const wxString& shortcutPath,
wxString& targetFilename,
wxString* arguments = NULL);
wxString* arguments = NULL) const;
#endif
#ifndef __WXWINCE__

View File

@ -1035,7 +1035,7 @@ public:
/**
Changes the current working directory.
*/
bool SetCwd();
bool SetCwd() const;
/**
Changes the current working directory.
@ -1080,7 +1080,7 @@ public:
*/
bool SetTimes(const wxDateTime* dtAccess,
const wxDateTime* dtMod,
const wxDateTime* dtCreate);
const wxDateTime* dtCreate) const;
/**
Sets the volume specifier.
@ -1162,7 +1162,7 @@ public:
/**
Sets the access and modification times to the current moment.
*/
bool Touch();
bool Touch() const;
/**
Returns @true if the filenames are different. The string @e filenames

View File

@ -592,7 +592,7 @@ wxString wxFileName::GetCwd(const wxString& volume)
return cwd;
}
bool wxFileName::SetCwd()
bool wxFileName::SetCwd() const
{
return wxFileName::SetCwd( GetPath() );
}
@ -1433,7 +1433,7 @@ bool wxFileName::ReplaceHomeDir(wxPathFormat format)
bool wxFileName::GetShortcutTarget(const wxString& shortcutPath,
wxString& targetFilename,
wxString* arguments)
wxString* arguments) const
{
wxString path, file, ext;
wxFileName::SplitPath(shortcutPath, & path, & file, & ext);
@ -2277,7 +2277,7 @@ wxString wxFileName::StripExtension(const wxString& fullpath)
bool wxFileName::SetTimes(const wxDateTime *dtAccess,
const wxDateTime *dtMod,
const wxDateTime *dtCreate)
const wxDateTime *dtCreate) const
{
#if defined(__WIN32__)
FILETIME ftAccess, ftCreate, ftWrite;
@ -2350,7 +2350,7 @@ bool wxFileName::SetTimes(const wxDateTime *dtAccess,
return false;
}
bool wxFileName::Touch()
bool wxFileName::Touch() const
{
#if defined(__UNIX_LIKE__)
// under Unix touching file is simple: just pass NULL to utime()
@ -2608,7 +2608,7 @@ bool wxFileName::MacSetTypeAndCreator( wxUint32 type , wxUint32 creator )
return false ;
}
bool wxFileName::MacGetTypeAndCreator( wxUint32 *type , wxUint32 *creator )
bool wxFileName::MacGetTypeAndCreator( wxUint32 *type , wxUint32 *creator ) const
{
FSRef fsRef ;
FSCatalogInfo catInfo;