summaryrefslogtreecommitdiffhomepage
path: root/Stars45/CmpSelectDlg.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'Stars45/CmpSelectDlg.cpp')
-rw-r--r--Stars45/CmpSelectDlg.cpp25
1 files changed, 13 insertions, 12 deletions
diff --git a/Stars45/CmpSelectDlg.cpp b/Stars45/CmpSelectDlg.cpp
index 47ce573..4e21257 100644
--- a/Stars45/CmpSelectDlg.cpp
+++ b/Stars45/CmpSelectDlg.cpp
@@ -23,6 +23,7 @@
#include "Player.h"
#include "Game.h"
+#include "ContentBundle.h"
#include "DataLoader.h"
#include "Button.h"
#include "ListBox.h"
@@ -54,7 +55,7 @@ selected_mission(-1), show_saved(false), loading(false),
loaded(false), hproc(0)
{
stars = Starshatter::GetInstance();
- select_msg = Game::GetInstance()->GetText("CmpSelectDlg.select_msg");
+ select_msg = ContentBundle::GetInstance()->GetText("CmpSelectDlg.select_msg");
Init(def);
}
@@ -139,7 +140,7 @@ CmpSelectDlg::ExecFrame()
campaign->Name() +
Text("<font Verdana>\n\n") +
Text("<color ffff80>") +
- Game::GetInstance()->GetText("CmpSelectDlg.scenario") +
+ ContentBundle::GetInstance()->GetText("CmpSelectDlg.scenario") +
Text("<color ffffff>\n\t") +
campaign->Description());
}
@@ -156,15 +157,15 @@ CmpSelectDlg::ExecFrame()
campaign->Name() +
Text("<font Verdana>\n\n") +
Text("<color ffff80>") +
- Game::GetInstance()->GetText("CmpSelectDlg.scenario") +
+ ContentBundle::GetInstance()->GetText("CmpSelectDlg.scenario") +
Text("<color ffffff>\n\t") +
campaign->Description() +
Text("\n\n<color ffff80>") +
- Game::GetInstance()->GetText("CmpSelectDlg.campaign-time") +
+ ContentBundle::GetInstance()->GetText("CmpSelectDlg.campaign-time") +
Text("<color ffffff>\n\t") +
time_buf +
Text("\n\n<color ffff80>") +
- Game::GetInstance()->GetText("CmpSelectDlg.assignment") +
+ ContentBundle::GetInstance()->GetText("CmpSelectDlg.assignment") +
Text("<color ffffff>\n\t");
if (campaign->GetPlayerGroup())
@@ -173,7 +174,7 @@ CmpSelectDlg::ExecFrame()
desc += "n/a";
desc += Text("\n\n<color ffff80>") +
- Game::GetInstance()->GetText("CmpSelectDlg.team-score") +
+ ContentBundle::GetInstance()->GetText("CmpSelectDlg.team-score") +
Text("<color ffffff>\n\t") +
score_buf;
@@ -208,7 +209,7 @@ CmpSelectDlg::ShowNewCampaigns()
AutoThreadSync a(sync);
if (loading && description) {
- description->SetText(Game::GetInstance()->GetText("CmpSelectDlg.already-loading"));
+ description->SetText(ContentBundle::GetInstance()->GetText("CmpSelectDlg.already-loading"));
Button::PlaySound(Button::SND_REJECT);
return;
}
@@ -285,7 +286,7 @@ CmpSelectDlg::ShowSavedCampaigns()
AutoThreadSync a(sync);
if (loading && description) {
- description->SetText(Game::GetInstance()->GetText("CmpSelectDlg.already-loading"));
+ description->SetText(ContentBundle::GetInstance()->GetText("CmpSelectDlg.already-loading"));
Button::PlaySound(Button::SND_REJECT);
return;
}
@@ -334,7 +335,7 @@ CmpSelectDlg::OnCampaignSelect(AWEvent* event)
AutoThreadSync a(sync);
if (loading) {
- description->SetText(Game::GetInstance()->GetText("CmpSelectDlg.already-loading"));
+ description->SetText(ContentBundle::GetInstance()->GetText("CmpSelectDlg.already-loading"));
Button::PlaySound(Button::SND_REJECT);
return;
}
@@ -455,9 +456,9 @@ CmpSelectDlg::OnDelete(AWEvent* event)
ConfirmDlg* confirm = manager->GetConfirmDlg();
if (confirm) {
char msg[256];
- sprintf_s(msg, Game::GetInstance()->GetText("CmpSelectDlg.are-you-sure"), load_file.data());
+ sprintf_s(msg, ContentBundle::GetInstance()->GetText("CmpSelectDlg.are-you-sure"), load_file.data());
confirm->SetMessage(msg);
- confirm->SetTitle(Game::GetInstance()->GetText("CmpSelectDlg.confirm"));
+ confirm->SetTitle(ContentBundle::GetInstance()->GetText("CmpSelectDlg.confirm"));
manager->ShowConfirmDlg();
}
@@ -533,7 +534,7 @@ CmpSelectDlg::StartLoadProc()
loaded = false;
if (description)
- description->SetText(Game::GetInstance()->GetText("CmpSelectDlg.loading"));
+ description->SetText(ContentBundle::GetInstance()->GetText("CmpSelectDlg.loading"));
DWORD thread_id = 0;
hproc = CreateThread(0, 4096, CmpSelectDlgLoadProc, (LPVOID) this, 0, &thread_id);