mirror of https://github.com/stella-emu/stella.git
Beginning of the properties restructuring.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1015 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
This commit is contained in:
parent
6209912e4a
commit
e6b236ef2e
|
@ -13,7 +13,7 @@
|
|||
// See the file "license" for information on usage and redistribution of
|
||||
// this file, and for a DISCLAIMER OF ALL WARRANTIES.
|
||||
//
|
||||
// $Id: PropsSet.cxx,v 1.18 2006-01-25 01:42:47 stephena Exp $
|
||||
// $Id: PropsSet.cxx,v 1.19 2006-03-03 19:58:35 stephena Exp $
|
||||
//============================================================================
|
||||
|
||||
#include <assert.h>
|
||||
|
@ -27,6 +27,7 @@ PropertiesSet::PropertiesSet()
|
|||
mySize(0)
|
||||
{
|
||||
myDefaultProperties = &defaultProperties();
|
||||
loadInternalDefaults();
|
||||
}
|
||||
|
||||
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
||||
|
@ -205,6 +206,11 @@ bool PropertiesSet::merge(const Properties& properties, const string& filename)
|
|||
return false;
|
||||
}
|
||||
|
||||
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
||||
void PropertiesSet::loadInternalDefaults()
|
||||
{
|
||||
}
|
||||
|
||||
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
||||
const Properties& PropertiesSet::defaultProperties()
|
||||
{
|
||||
|
|
|
@ -13,7 +13,7 @@
|
|||
// See the file "license" for information on usage and redistribution of
|
||||
// this file, and for a DISCLAIMER OF ALL WARRANTIES.
|
||||
//
|
||||
// $Id: PropsSet.hxx,v 1.10 2005-10-19 00:59:51 stephena Exp $
|
||||
// $Id: PropsSet.hxx,v 1.11 2006-03-03 19:58:35 stephena Exp $
|
||||
//============================================================================
|
||||
|
||||
#ifndef PROPERTIES_SET_HXX
|
||||
|
@ -25,6 +25,32 @@
|
|||
|
||||
class Properties;
|
||||
|
||||
enum PropertyType {
|
||||
Cartridge_Cheats,
|
||||
Cartridge_Filename,
|
||||
Cartridge_MD5,
|
||||
Cartridge_Manufacturer,
|
||||
Cartridge_ModelNo,
|
||||
Cartridge_Name,
|
||||
Cartridge_Note,
|
||||
Cartridge_Rarity,
|
||||
Cartridge_Sound,
|
||||
Cartridge_Type,
|
||||
Console_LeftDifficulty,
|
||||
Console_RightDifficulty,
|
||||
Console_TelevisionType,
|
||||
Console_SwapPorts,
|
||||
Controller_Left,
|
||||
Controller_Right,
|
||||
Display_Format,
|
||||
Display_XStart,
|
||||
Display_Width,
|
||||
Display_YStart,
|
||||
Display_Height,
|
||||
Display_Phosphor,
|
||||
Emulation_HmoveBlanks
|
||||
};
|
||||
|
||||
/**
|
||||
This class maintains a sorted collection of properties. The objects
|
||||
are maintained in a binary search tree sorted by md5, since this is
|
||||
|
@ -117,6 +143,8 @@ class PropertiesSet
|
|||
bool save;
|
||||
};
|
||||
|
||||
void loadInternalDefaults();
|
||||
|
||||
/**
|
||||
Insert a node in the bst, keeping the tree sorted.
|
||||
|
||||
|
|
Loading…
Reference in New Issue