Use an enum instead of type-unsafe "int" for the second parameter of the recently added wxStandardPaths::MakeConfigFileName(). This also avoids unnatural dependency of wxStandardPaths on wxCONFIG_USE_SUBDIR constant defined in a higher level wxFileConfig class. No real changes, but just make things a bit more robust and hopefully more clear.
		
			
				
	
	
		
			46 lines
		
	
	
		
			1.7 KiB
		
	
	
	
		
			C++
		
	
	
	
	
	
			
		
		
	
	
			46 lines
		
	
	
		
			1.7 KiB
		
	
	
	
		
			C++
		
	
	
	
	
	
| /////////////////////////////////////////////////////////////////////////////
 | |
| // Name:        wx/osx/cocoa/stdpaths.h
 | |
| // Purpose:     wxStandardPaths for Cocoa
 | |
| // Author:      Tobias Taschner
 | |
| // Created:     2015-09-09
 | |
| // Copyright:   (c) 2015 wxWidgets development team
 | |
| // Licence:     wxWindows licence
 | |
| /////////////////////////////////////////////////////////////////////////////
 | |
| 
 | |
| #ifndef _WX_COCOA_STDPATHS_H_
 | |
| #define _WX_COCOA_STDPATHS_H_
 | |
| 
 | |
| // ----------------------------------------------------------------------------
 | |
| // wxStandardPaths
 | |
| // ----------------------------------------------------------------------------
 | |
| 
 | |
| class WXDLLIMPEXP_BASE wxStandardPaths : public wxStandardPathsBase
 | |
| {
 | |
| public:
 | |
|     virtual ~wxStandardPaths();
 | |
| 
 | |
|     // implement base class pure virtuals
 | |
|     virtual wxString GetExecutablePath() const wxOVERRIDE;
 | |
|     virtual wxString GetConfigDir() const wxOVERRIDE;
 | |
|     virtual wxString GetUserConfigDir() const wxOVERRIDE;
 | |
|     virtual wxString GetDataDir() const wxOVERRIDE;
 | |
|     virtual wxString GetLocalDataDir() const wxOVERRIDE;
 | |
|     virtual wxString GetUserDataDir() const wxOVERRIDE;
 | |
|     virtual wxString GetPluginsDir() const wxOVERRIDE;
 | |
|     virtual wxString GetResourcesDir() const wxOVERRIDE;
 | |
|     virtual wxString
 | |
|     GetLocalizedResourcesDir(const wxString& lang,
 | |
|                              ResourceCat category = ResourceCat_None) const wxOVERRIDE;
 | |
|     virtual wxString GetUserDir(Dir userDir) const wxOVERRIDE;
 | |
|     virtual wxString MakeConfigFileName(const wxString& basename,
 | |
|                                         ConfigFileConv conv) const wxOVERRIDE;
 | |
| 
 | |
| protected:
 | |
|     // Ctor is protected, use wxStandardPaths::Get() instead of instantiating
 | |
|     // objects of this class directly.
 | |
|     wxStandardPaths();
 | |
| };
 | |
| 
 | |
| 
 | |
| #endif // _WX_COCOA_STDPATHS_H_
 |