mirror of
https://github.com/holub/mame
synced 2025-04-24 17:30:55 +03:00
Incorporating Vas Crabb feedback
This commit is contained in:
parent
a1e4e90619
commit
7e729626ce
@ -402,8 +402,8 @@ void software_list_device::find_approx_matches(const char *name, int matches, co
|
||||
// iterate over our info (will cause a parse if needed)
|
||||
for (const software_info &swinfo : get_info())
|
||||
{
|
||||
const software_part *part = &swinfo.parts().front();
|
||||
if ((interface == nullptr || part->matches_interface(interface)) && part->is_compatible(*this) == SOFTWARE_IS_COMPATIBLE)
|
||||
const software_part &part = swinfo.parts().front();
|
||||
if ((interface == nullptr || part.matches_interface(interface)) && part.is_compatible(*this) == SOFTWARE_IS_COMPATIBLE)
|
||||
{
|
||||
// pick the best match between driver name and description
|
||||
int longpenalty = driver_list::penalty_compare(name, swinfo.longname().c_str());
|
||||
|
@ -212,7 +212,7 @@ public:
|
||||
|
||||
// getters that may trigger a parse
|
||||
const char *description() { if (!m_parsed) parse(); return m_description.c_str(); }
|
||||
bool valid() { if (!m_parsed) parse(); return m_infolist.size() > 0; }
|
||||
bool valid() { if (!m_parsed) parse(); return !m_infolist.empty(); }
|
||||
const char *errors_string() { if (!m_parsed) parse(); return m_errors.c_str(); }
|
||||
const std::list<software_info> &get_info() { if (!m_parsed) parse(); return m_infolist; }
|
||||
|
||||
|
@ -527,8 +527,8 @@ void menu_select_software::build_software_list()
|
||||
m_filter.swlist.description.push_back(swlist.description());
|
||||
for (const software_info &swinfo : swlist.get_info())
|
||||
{
|
||||
const software_part *part = &swinfo.parts().front();
|
||||
if (part->is_compatible(swlist) == SOFTWARE_IS_COMPATIBLE)
|
||||
const software_part &part = swinfo.parts().front();
|
||||
if (part.is_compatible(swlist) == SOFTWARE_IS_COMPATIBLE)
|
||||
{
|
||||
const char *instance_name = nullptr;
|
||||
const char *type_name = nullptr;
|
||||
@ -536,7 +536,7 @@ void menu_select_software::build_software_list()
|
||||
for (device_image_interface &image : image_interface_iterator(config.root_device()))
|
||||
{
|
||||
const char *interface = image.image_interface();
|
||||
if (interface != nullptr && part->matches_interface(interface))
|
||||
if (interface != nullptr && part.matches_interface(interface))
|
||||
{
|
||||
instance_name = image.instance_name();
|
||||
if (instance_name != nullptr)
|
||||
@ -558,10 +558,10 @@ void menu_select_software::build_software_list()
|
||||
tmpmatches.year = swinfo.year();
|
||||
tmpmatches.publisher = swinfo.publisher();
|
||||
tmpmatches.supported = swinfo.supported();
|
||||
tmpmatches.part = part->name();
|
||||
tmpmatches.part = part.name();
|
||||
tmpmatches.driver = m_driver;
|
||||
tmpmatches.listname = strensure(swlist.list_name());
|
||||
tmpmatches.interface = part->interface();
|
||||
tmpmatches.interface = part.interface();
|
||||
tmpmatches.startempty = 0;
|
||||
tmpmatches.parentlongname.clear();
|
||||
tmpmatches.usage.clear();
|
||||
|
Loading…
Reference in New Issue
Block a user