summaryrefslogtreecommitdiff
path: root/Source/Core
diff options
context:
space:
mode:
authorkostamarino@hotmail.com <kostamarino@hotmail.com>2011-12-18 14:52:40 +0200
committerkostamarino@hotmail.com <kostamarino@hotmail.com>2011-12-18 14:52:40 +0200
commit9829beab42d6774ddc6f6b01950489ced40eec72 (patch)
tree70ff786b79c2673e1264ccff41c9d5486dd1c8d3 /Source/Core
parentd00b719966eda3c27b5fcb96bce50038f52611d5 (diff)
Gameini database update, mainly changes to the emulation issues lines (make them shorter, with more substance and less bla bla, update outdated stuff). The emulation issues lines can be further improved(this is a start).
Also re - implement the emulation issues column that was reverted, make it a bit bigger since sentences need more words and delete the issues portion of the emustate tooltip since it is unnecessary now.
Diffstat (limited to 'Source/Core')
-rw-r--r--Source/Core/DolphinWX/Src/GameListCtrl.cpp53
-rw-r--r--Source/Core/DolphinWX/Src/GameListCtrl.h2
2 files changed, 19 insertions, 36 deletions
diff --git a/Source/Core/DolphinWX/Src/GameListCtrl.cpp b/Source/Core/DolphinWX/Src/GameListCtrl.cpp
index 05f8c8365a..ac0b88269c 100644
--- a/Source/Core/DolphinWX/Src/GameListCtrl.cpp
+++ b/Source/Core/DolphinWX/Src/GameListCtrl.cpp
@@ -91,16 +91,6 @@ static int CompareGameListItems(const GameListItem* iso1, const GameListItem* is
case CGameListCtrl::COLUMN_TITLE:
return strcasecmp(iso1->GetName(indexOne).c_str(),
iso2->GetName(indexOther).c_str()) * t;
- case CGameListCtrl::COLUMN_NOTES:
- {
- std::string cmp1 =
- (iso1->GetPlatform() == GameListItem::GAMECUBE_DISC) ?
- iso1->GetCompany() : iso1->GetDescription(indexOne);
- std::string cmp2 =
- (iso2->GetPlatform() == GameListItem::GAMECUBE_DISC) ?
- iso2->GetCompany() : iso2->GetDescription(indexOther);
- return strcasecmp(cmp1.c_str(), cmp2.c_str()) * t;
- }
case CGameListCtrl::COLUMN_COUNTRY:
if(iso1->GetCountry() > iso2->GetCountry())
return 1 * t;
@@ -133,7 +123,10 @@ static int CompareGameListItems(const GameListItem* iso1, const GameListItem* is
else
return 0;
}
- break;
+ case CGameListCtrl::COLUMN_EMULATION_NOTES:
+ return strcasecmp(iso1->GetIssues().c_str(),
+ iso2->GetIssues().c_str()) * t;
+ break;
}
return 0;
@@ -294,19 +287,20 @@ void CGameListCtrl::Update()
// Instead of showing the notes + the company, which is unknown with
// wii titles We show in the same column : company for GC games and
// description for wii/wad games
- InsertColumn(COLUMN_NOTES, _("Notes"));
+ InsertColumn(COLUMN_EMULATION_NOTES, _("Emulation Notes"));
InsertColumn(COLUMN_COUNTRY, _T(""));
InsertColumn(COLUMN_SIZE, _("Size"));
InsertColumn(COLUMN_EMULATION_STATE, _("State"));
-
+
// set initial sizes for columns
SetColumnWidth(COLUMN_PLATFORM, 35);
SetColumnWidth(COLUMN_BANNER, 96);
SetColumnWidth(COLUMN_TITLE, 200);
- SetColumnWidth(COLUMN_NOTES, 200);
+ SetColumnWidth(COLUMN_EMULATION_NOTES, 200);
SetColumnWidth(COLUMN_COUNTRY, 32);
SetColumnWidth(COLUMN_EMULATION_STATE, 50);
+
// add all items
for (int i = 0; i < (int)m_ISOFiles.size(); i++)
@@ -483,18 +477,12 @@ void CGameListCtrl::InsertItemInReportView(long _Index)
wxString name = wxString(rISOFile.GetName(0).c_str(), SJISConv);
m_gameList.append(StringFromFormat("%s (J)\n", (const char *)name.c_str()));
SetItem(_Index, COLUMN_TITLE, name, -1);
- SetItem(_Index, COLUMN_NOTES, wxString(company.size() ?
- company.c_str() : rISOFile.GetDescription(0).c_str(),
- SJISConv), -1);
}
break;
case DiscIO::IVolume::COUNTRY_USA:
m_gameList.append(StringFromFormat("%s (U)\n", rISOFile.GetName(0).c_str()));
SetItem(_Index, COLUMN_TITLE,
wxString::From8BitData(rISOFile.GetName(0).c_str()), -1);
- SetItem(_Index, COLUMN_NOTES,
- wxString::From8BitData(company.size() ?
- company.c_str() : rISOFile.GetDescription(0).c_str()), -1);
break;
default:
m_gameList.append(StringFromFormat("%s (E)\n",
@@ -503,11 +491,6 @@ void CGameListCtrl::InsertItemInReportView(long _Index)
wxString::From8BitData(
rISOFile.GetName(SConfig::GetInstance().m_LocalCoreStartupParameter.SelectedLanguage).c_str()),
-1);
- SetItem(_Index, COLUMN_NOTES,
- wxString::From8BitData(company.size() ?
- company.c_str() :
- rISOFile.GetDescription(SConfig::GetInstance().m_LocalCoreStartupParameter.SelectedLanguage).c_str()),
- -1);
break;
}
}
@@ -516,8 +499,6 @@ void CGameListCtrl::InsertItemInReportView(long _Index)
m_gameList.append(StringFromFormat("%s (WAD)\n", rISOFile.GetName(0).c_str()));
SetItem(_Index, COLUMN_TITLE,
wxString(rISOFile.GetName(0).c_str(), SJISConv), -1);
- SetItem(_Index, COLUMN_NOTES,
- wxString(rISOFile.GetDescription(0).c_str(), SJISConv), -1);
}
#ifndef _WIN32
@@ -531,6 +512,10 @@ void CGameListCtrl::InsertItemInReportView(long _Index)
// File size
SetItem(_Index, COLUMN_SIZE, NiceSizeFormat(rISOFile.GetFileSize()), -1);
+ // Emulation notes
+ SetItem(_Index, COLUMN_EMULATION_NOTES, wxString::From8BitData(rISOFile.GetIssues().c_str()), -1);
+ SetColumnWidth(COLUMN_SIZE, wxLIST_AUTOSIZE);
+
// Background color
SetBackgroundColor();
@@ -713,7 +698,7 @@ void CGameListCtrl::ScanForISOs()
void CGameListCtrl::OnColBeginDrag(wxListEvent& event)
{
- if (event.GetColumn() != COLUMN_TITLE && event.GetColumn() != COLUMN_NOTES)
+ if (event.GetColumn() != COLUMN_TITLE && event.GetColumn() != COLUMN_EMULATION_NOTES)
event.Veto();
}
@@ -855,14 +840,12 @@ void CGameListCtrl::OnMouseMotion(wxMouseEvent& event)
const GameListItem& rISO = *m_ISOFiles[GetItemData(item)];
const int emu_state = rISO.GetEmuState();
- const std::string& issues = rISO.GetIssues();
-
+
// Show a tooltip containing the EmuState and the state description
if (emu_state > 0 && emu_state < 6)
{
char temp[2048];
- sprintf(temp, "^ %s%s%s", emuState[emu_state - 1],
- issues.size() > 0 ? " :\n" : "", issues.c_str());
+ sprintf(temp, "^ %s", emuState[emu_state - 1]);
toolTip = new wxEmuStateTip(this, wxString(temp, *wxConvCurrent), &toolTip);
}
else
@@ -1331,13 +1314,13 @@ void CGameListCtrl::AutomaticColumnWidth()
// We hide the Notes column if the window is too small
if (resizable > 400)
{
- SetColumnWidth(COLUMN_TITLE, resizable / 2);
- SetColumnWidth(COLUMN_NOTES, resizable / 2);
+ SetColumnWidth(COLUMN_TITLE, resizable * 0.4);
+ SetColumnWidth(COLUMN_EMULATION_NOTES, resizable * 0.6);
}
else
{
SetColumnWidth(COLUMN_TITLE, resizable);
- SetColumnWidth(COLUMN_NOTES, 0);
+ SetColumnWidth(COLUMN_EMULATION_NOTES, 0);
}
}
}
diff --git a/Source/Core/DolphinWX/Src/GameListCtrl.h b/Source/Core/DolphinWX/Src/GameListCtrl.h
index 8fca14f632..48b1a118c4 100644
--- a/Source/Core/DolphinWX/Src/GameListCtrl.h
+++ b/Source/Core/DolphinWX/Src/GameListCtrl.h
@@ -60,7 +60,7 @@ public:
COLUMN_PLATFORM = 0,
COLUMN_BANNER,
COLUMN_TITLE,
- COLUMN_NOTES,
+ COLUMN_EMULATION_NOTES,
COLUMN_COUNTRY,
COLUMN_SIZE,
COLUMN_EMULATION_STATE,