mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-26 15:49:50 -06:00
Import r67258 of the wxWidgets trunk, which I expect will before
long become wxWidgets 2.9.2, which in turn is expected to be the last 2.9 release before the 3.0 stable release. Since the full wxWidgets distribution is rather large, I have imported only the parts that we use, on a subdirectory basis: art include/wx/*.* include/wx/aui include/wx/cocoa include/wx/generic include/wx/gtk include/wx/meta include/wx/msw include/wx/osx include/wx/persist include/wx/private include/wx/protocol include/wx/unix src/aui src/common src/generic src/gtk src/msw src/osx src/unix git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7380 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
74
Externals/wxWidgets3/include/wx/fmappriv.h
vendored
Normal file
74
Externals/wxWidgets3/include/wx/fmappriv.h
vendored
Normal file
@ -0,0 +1,74 @@
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
// Name: wx/fmappriv.h
|
||||
// Purpose: private wxFontMapper stuff, not to be used by the library users
|
||||
// Author: Vadim Zeitlin
|
||||
// Modified by:
|
||||
// Created: 21.06.2003 (extracted from common/fontmap.cpp)
|
||||
// RCS-ID: $Id: fmappriv.h 58757 2009-02-08 11:45:59Z VZ $
|
||||
// Copyright: (c) 1999-2003 Vadim Zeitlin <vadim@wxwidgets.org>
|
||||
// Licence: wxWindows licence
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef _WX_FMAPPRIV_H_
|
||||
#define _WX_FMAPPRIV_H_
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// constants
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
// a special pseudo encoding which means "don't ask me about this charset
|
||||
// any more" -- we need it to avoid driving the user crazy with asking him
|
||||
// time after time about the same charset which he [presumably] doesn't
|
||||
// have the fonts for
|
||||
enum { wxFONTENCODING_UNKNOWN = -2 };
|
||||
|
||||
// the config paths we use
|
||||
#if wxUSE_CONFIG
|
||||
|
||||
#define FONTMAPPER_ROOT_PATH wxT("/wxWindows/FontMapper")
|
||||
#define FONTMAPPER_CHARSET_PATH wxT("Charsets")
|
||||
#define FONTMAPPER_CHARSET_ALIAS_PATH wxT("Aliases")
|
||||
|
||||
#endif // wxUSE_CONFIG
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// wxFontMapperPathChanger: change the config path during our lifetime
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
#if wxUSE_CONFIG && wxUSE_FILECONFIG
|
||||
|
||||
class wxFontMapperPathChanger
|
||||
{
|
||||
public:
|
||||
wxFontMapperPathChanger(wxFontMapperBase *fontMapper, const wxString& path)
|
||||
{
|
||||
m_fontMapper = fontMapper;
|
||||
m_ok = m_fontMapper->ChangePath(path, &m_pathOld);
|
||||
}
|
||||
|
||||
bool IsOk() const { return m_ok; }
|
||||
|
||||
~wxFontMapperPathChanger()
|
||||
{
|
||||
if ( IsOk() )
|
||||
m_fontMapper->RestorePath(m_pathOld);
|
||||
}
|
||||
|
||||
private:
|
||||
// the fontmapper object we're working with
|
||||
wxFontMapperBase *m_fontMapper;
|
||||
|
||||
// the old path to be restored if m_ok
|
||||
wxString m_pathOld;
|
||||
|
||||
// have we changed the path successfully?
|
||||
bool m_ok;
|
||||
|
||||
|
||||
wxDECLARE_NO_COPY_CLASS(wxFontMapperPathChanger);
|
||||
};
|
||||
|
||||
#endif // wxUSE_CONFIG
|
||||
|
||||
#endif // _WX_FMAPPRIV_H_
|
||||
|
Reference in New Issue
Block a user