diff options
| author | phintuka <phintuka> | 2010-01-19 22:06:52 +0000 |
|---|---|---|
| committer | phintuka <phintuka> | 2010-01-19 22:06:52 +0000 |
| commit | 99bc9402134aaf6196c388adc3b5916d38aeee0e (patch) | |
| tree | 1db61509f134b0073879a7779b79d7de7603a4c5 | |
| parent | 9c43caf1121ebb02651b77164df2ad9ed9f831c5 (diff) | |
| download | xineliboutput-99bc9402134aaf6196c388adc3b5916d38aeee0e.tar.gz xineliboutput-99bc9402134aaf6196c388adc3b5916d38aeee0e.tar.bz2 | |
Menu item helpers
| -rw-r--r-- | menuitems.h | 29 |
1 files changed, 28 insertions, 1 deletions
diff --git a/menuitems.h b/menuitems.h index cbbc6d79..73cbaef5 100644 --- a/menuitems.h +++ b/menuitems.h @@ -4,7 +4,7 @@ * See the main source file 'xineliboutput.c' for copyright information and * how to reach the author. * - * $Id: menuitems.h,v 1.9 2009-08-03 12:11:35 phintuka Exp $ + * $Id: menuitems.h,v 1.10 2010-01-19 22:06:52 phintuka Exp $ * */ @@ -13,6 +13,33 @@ #include <vdr/menuitems.h> +static inline cString Label_SubMenu(const char *Label) +{ + return cString::sprintf("%s >>", Label); +} + +static inline cString Label_Ident(const char *Label) +{ + return cString::sprintf(" %s", Label); +} + +static inline cString Label_Separator(const char *Label) +{ + return cString::sprintf("----- %s -----", Label); +} + +static inline cOsdItem *SubMenuItem(const char *Label, eOSState state) +{ + return new cOsdItem(Label_SubMenu(Label), state); +} + +static inline cOsdItem *SeparatorItem(const char *Label) +{ + cOsdItem *Item = new cOsdItem(Label_Separator(Label)); + Item->SetSelectable(false); + return Item; +} + // --- cMenuEditTypedIntItem ------------------------------------------------- class cMenuEditTypedIntItem : public cMenuEditIntItem |
