Project::OSiRiON - Git repositories
Project::OSiRiON
News . About . Screenshots . Downloads . Forum . Wiki . Tracker . Git
summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/client/infowidget.cc6
-rw-r--r--src/client/infowidget.h2
-rw-r--r--src/client/mainwindow.cc2
-rw-r--r--src/client/video.cc2
4 files changed, 6 insertions, 6 deletions
diff --git a/src/client/infowidget.cc b/src/client/infowidget.cc
index 752c09b..c99a3f2 100644
--- a/src/client/infowidget.cc
+++ b/src/client/infowidget.cc
@@ -207,19 +207,19 @@ void ClockInfoWidget::draw()
sys::get_localtime(hours, minutes, seconds);
std::ostringstream clockstr;
- clockstr << std::setfill('0') << std::setw(2);
+ clockstr << std::setfill(' ') << std::setw(2);
if (mode() == Clock12Hours) {
std::string suffix("am");
if (hours >= 12) {
- suffix[1] = 'p';
+ suffix[0] = 'p';
hours -= 12;
}
if (hours == 0) {
hours += 12;
}
- clockstr << hours << ":" << std::setfill('0') << std::setw(2) << minutes << suffix;
+ clockstr << hours << ":" << std::setfill('0') << std::setw(2) << minutes << " " << suffix;
} else {
clockstr << " " << hours << ":" << std::setfill('0') << std::setw(2) << minutes;
}
diff --git a/src/client/infowidget.h b/src/client/infowidget.h
index d2936e4..4ace7ea 100644
--- a/src/client/infowidget.h
+++ b/src/client/infowidget.h
@@ -65,7 +65,7 @@ class ClockInfoWidget : public ui::Widget
{
public:
/// clock mode
- enum Mode {ClockOff=0, Clock24Hours=1, Clock12Hours=2};
+ enum Mode {ClockOff=0, Clock12Hours=1, Clock24Hours=2};
/// default constructor
ClockInfoWidget(ui::Widget *parent = 0);
diff --git a/src/client/mainwindow.cc b/src/client/mainwindow.cc
index 698c5b3..6574303 100644
--- a/src/client/mainwindow.cc
+++ b/src/client/mainwindow.cc
@@ -104,7 +104,7 @@ void MainWindow::draw()
if (draw_clock->value() <= 0) {
mainwindow_clockwidget->set_mode(ClockInfoWidget::ClockOff);
- } else if (draw_clock->value() >= 2) {
+ } else if (draw_clock->value() == 1) {
mainwindow_clockwidget->set_mode(ClockInfoWidget::Clock12Hours);
} else {
mainwindow_clockwidget->set_mode(ClockInfoWidget::Clock24Hours);
diff --git a/src/client/video.cc b/src/client/video.cc
index f00b7f9..7f15eea 100644
--- a/src/client/video.cc
+++ b/src/client/video.cc
@@ -99,7 +99,7 @@ bool init()
draw_keypress->set_info("[bool] draw keypress key names");
draw_clock = core::Cvar::get("draw_clock", "0", core::Cvar::Archive);
- draw_clock->set_info("[int] draw clock (0=Off, 1=24hr, 2=12hr)");
+ draw_clock->set_info("[int] draw clock (0=Off, 1=12hr, 2=24hr)");
draw_ui = core::Cvar::get("draw_ui", "1", core::Cvar::Archive);
draw_ui->set_info("[bool] draw the user interface");