Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Cleanup core info code for blackberry (not tested)

  • Loading branch information...
commit 19ce56d91e7432bcfd74bd2dde7fa2e3da0ce217 1 parent 4f6df19
@meancoot meancoot authored
View
6 blackberry-qnx/bb10/src/RetroArch-Cascades.cpp
@@ -250,7 +250,7 @@ void RetroArch::onCoreSelected(QVariant value)
core.append(core_info_list->list[coreSelectedIndex].path);
emit coreChanged(core);
- romExtensions = QString("*.%1").arg(core_info_list->list[coreSelectedIndex].supportedExtensions);
+ romExtensions = QString("*.%1").arg(core_info_list->list[coreSelectedIndex].supported_extensions);
romExtensions.replace("|", "|*.");
emit romExtensionsChanged(romExtensions);
@@ -296,9 +296,9 @@ void RetroArch::populateCores(core_info_list_t * info)
//Populate DropDown
for (i = 0; i < info->count; ++i)
{
- qDebug() << info->list[i].displayName;
+ qDebug() << info->list[i].display_name;
- tmp = Option::create().text(QString(info->list[i].displayName))
+ tmp = Option::create().text(QString(info->list[i].display_name))
.value(i);
coreSelection->add(tmp);
View
13 core_info.c
@@ -65,9 +65,9 @@ core_info_list_t *get_core_info_list(const char *modules_path)
{
config_get_string(core_info[i].data, "display_name", &core_info[i].display_name);
- char* extensions;
- if (config_get_string(core_info[i].data, "supported_extensions", &extensions) && extensions)
- core_info[i].supported_extensions = string_split(extensions, "|");
+ if (config_get_string(core_info[i].data, "supported_extensions", &core_info[i].supported_extensions) &&
+ core_info[i].supported_extensions)
+ core_info[i].supported_extensions_list = string_split(core_info[i].supported_extensions, "|");
}
if (!core_info[i].display_name)
@@ -90,7 +90,8 @@ void free_core_info_list(core_info_list_t *core_info_list)
{
free(core_info_list->list[i].path);
free(core_info_list->list[i].display_name);
- string_list_free(core_info_list->list[i].supported_extensions);
+ free(core_info_list->list[i].supported_extensions);
+ string_list_free(core_info_list->list[i].supported_extensions_list);
config_file_free(core_info_list->list[i].data);
}
@@ -100,9 +101,9 @@ void free_core_info_list(core_info_list_t *core_info_list)
bool does_core_support_file(core_info_t* core, const char *path)
{
- if (!path || !core || !core->supported_extensions)
+ if (!path || !core || !core->supported_extensions_list)
return false;
- return string_list_find_elem_prefix(core->supported_extensions, ".", path_get_extension(path));
+ return string_list_find_elem_prefix(core->supported_extensions_list, ".", path_get_extension(path));
}
View
3  core_info.h
@@ -26,7 +26,8 @@ typedef struct {
char * path;
config_file_t* data;
char * display_name;
- struct string_list * supported_extensions;
+ char * supported_extensions;
+ struct string_list * supported_extensions_list;
} core_info_t;
typedef struct {
Please sign in to comment.
Something went wrong with that request. Please try again.