diff options
| author | 2018-05-18 13:08:54 +0300 | |
|---|---|---|
| committer | 2018-05-18 13:09:00 +0300 | |
| commit | 4d3566cfa7b6fcfcb8b89beb44798924ddbfc627 (patch) | |
| tree | 4ca6755ba2131fd330628c53abe4547d132e5fac /src/emu/save.cpp | |
| parent | af1b9542ce959a2b35a785446a758e8dad4cf79b (diff) | |
WARNING emu.h recompile!
debugger: Show save state items in alphabetical order in the debugger view. [Curt Coder]
Diffstat (limited to 'src/emu/save.cpp')
| -rw-r--r-- | src/emu/save.cpp | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/src/emu/save.cpp b/src/emu/save.cpp index 767aadb5ad9..33aaf60e725 100644 --- a/src/emu/save.cpp +++ b/src/emu/save.cpp @@ -108,6 +108,28 @@ const char *save_manager::indexed_item(int index, void *&base, u32 &valsize, u32 //------------------------------------------------- +// named_item - return an item with the given +// name +//------------------------------------------------- + +void save_manager::named_item(std::string name, void *&base, u32 &valsize, u32 &valcount) const +{ + for (auto it = m_entry_list.begin(); it != m_entry_list.end(); ++it) + { + if (it->get()->m_name.compare(name) == 0) + { + state_entry *entry = it->get(); + + base = entry->m_data; + valsize = entry->m_typesize; + valcount = entry->m_typecount; + break; + } + } +} + + +//------------------------------------------------- // register_presave - register a pre-save // function callback //------------------------------------------------- |
