Project::OSiRiON - Git repositories
Project::OSiRiON
News . About . Screenshots . Downloads . Forum . Wiki . Tracker . Git
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStijn Buys <ingar@osirion.org>2011-09-04 17:54:51 +0000
committerStijn Buys <ingar@osirion.org>2011-09-04 17:54:51 +0000
commit69eed715f80c24c2435c82bb9fa1954697bf3af0 (patch)
treea21aa14d2ecfa86b94d3b122c2c972d758425782 /src/ui/widget.cc
parentedd5dfcd15198f5d5d277835fdf75108eb67472d (diff)
Moved main menu infrastructure into client namespace,
removed ui::Container and ui::Menu classes.
Diffstat (limited to 'src/ui/widget.cc')
-rw-r--r--src/ui/widget.cc14
1 files changed, 11 insertions, 3 deletions
diff --git a/src/ui/widget.cc b/src/ui/widget.cc
index 709731e..6d0fb84 100644
--- a/src/ui/widget.cc
+++ b/src/ui/widget.cc
@@ -76,10 +76,18 @@ void Widget::print(const size_t indent) const
{
if (indent) {
std::string marker;
- if (widget_focus)
- marker.assign("^B* ^N");
- else
+ if (!widget_enabled) {
+ marker.assign("^B- ");
+ } else if (widget_focus) {
+ marker.assign("^B* ");
+ } else {
marker.assign(" ");
+ }
+ if (widget_visible) {
+ marker.append("^N");
+ } else {
+ marker.append("^D");
+ }
con_print << aux::pad_left(marker, indent*2) << label() << std::endl;
}
}