Added wxUSE_DC_CACHEING and associated code to wxMSW
Added EnableCache, CacheEnabled to wxDCBase Added mask source args to DoBlit, Blit Added cache testing code to dragimag sample Added wxSystemOptions, regenerated makefiles git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@10962 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -57,9 +57,6 @@ public:
|
||||
|
||||
private:
|
||||
DECLARE_DYNAMIC_CLASS(wxSystemSettingsModule)
|
||||
|
||||
static wxArrayString sm_optionNames;
|
||||
static wxArrayString sm_optionValues;
|
||||
};
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
@@ -78,9 +75,6 @@ static wxFont *gs_fontDefault = NULL;
|
||||
|
||||
IMPLEMENT_DYNAMIC_CLASS(wxSystemSettingsModule, wxModule)
|
||||
|
||||
wxArrayString wxSystemSettingsModule::sm_optionNames;
|
||||
wxArrayString wxSystemSettingsModule::sm_optionValues;
|
||||
|
||||
bool wxSystemSettingsModule::OnInit()
|
||||
{
|
||||
return TRUE;
|
||||
@@ -88,9 +82,8 @@ bool wxSystemSettingsModule::OnInit()
|
||||
|
||||
void wxSystemSettingsModule::OnExit()
|
||||
{
|
||||
sm_optionNames.Clear();
|
||||
sm_optionValues.Clear();
|
||||
delete gs_fontDefault;
|
||||
gs_fontDefault = NULL;
|
||||
}
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
@@ -274,45 +267,3 @@ int wxSystemSettings::GetSystemMetric(int index)
|
||||
// __WXMICROWIN__
|
||||
}
|
||||
|
||||
// Option functions (arbitrary name/value mapping)
|
||||
void wxSystemSettings::SetOption(const wxString& name, const wxString& value)
|
||||
{
|
||||
int idx = wxSystemSettingsModule::sm_optionNames.Index(name, FALSE);
|
||||
if (idx == wxNOT_FOUND)
|
||||
{
|
||||
wxSystemSettingsModule::sm_optionNames.Add(name);
|
||||
wxSystemSettingsModule::sm_optionValues.Add(value);
|
||||
}
|
||||
else
|
||||
{
|
||||
wxSystemSettingsModule::sm_optionNames[idx] = name;
|
||||
wxSystemSettingsModule::sm_optionValues[idx] = value;
|
||||
}
|
||||
}
|
||||
|
||||
void wxSystemSettings::SetOption(const wxString& name, int value)
|
||||
{
|
||||
wxString valStr;
|
||||
valStr.Printf(wxT("%d"), value);
|
||||
SetOption(name, valStr);
|
||||
}
|
||||
|
||||
wxString wxSystemSettings::GetOption(const wxString& name)
|
||||
{
|
||||
int idx = wxSystemSettingsModule::sm_optionNames.Index(name, FALSE);
|
||||
if (idx == wxNOT_FOUND)
|
||||
return wxEmptyString;
|
||||
else
|
||||
return wxSystemSettingsModule::sm_optionValues[idx];
|
||||
}
|
||||
|
||||
int wxSystemSettings::GetOptionInt(const wxString& name)
|
||||
{
|
||||
return wxAtoi(GetOption(name));
|
||||
}
|
||||
|
||||
bool wxSystemSettings::HasOption(const wxString& name)
|
||||
{
|
||||
return (wxSystemSettingsModule::sm_optionNames.Index(name, FALSE) != wxNOT_FOUND);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user