diff options
author | lordjaxom <lordjaxom> | 2005-01-05 19:28:52 +0000 |
---|---|---|
committer | lordjaxom <lordjaxom> | 2005-01-05 19:28:52 +0000 |
commit | c988360698b2ba87b76cc33e7e9b0e63d0274415 (patch) | |
tree | 3febce6f1a4e91db75e02daf8303113cd660140a | |
parent | 9af1355019ec5a65848299cd319c53364f42bcf8 (diff) | |
download | vdr-plugin-text2skin-c988360698b2ba87b76cc33e7e9b0e63d0274415.tar.gz vdr-plugin-text2skin-c988360698b2ba87b76cc33e7e9b0e63d0274415.tar.bz2 |
- implemented list methods for audio tracks menu
- introduces SetMaxItems (useful for some skins, together with
patches/vdr-1.3.17-osdbase-maxitems.diff)
-rw-r--r-- | display.h | 15 |
1 files changed, 12 insertions, 3 deletions
@@ -1,5 +1,5 @@ /* - * $Id: display.h,v 1.4 2005/01/02 19:55:36 lordjaxom Exp $ + * $Id: display.h,v 1.5 2005/01/05 19:28:52 lordjaxom Exp $ */ #ifndef VDR_TEXT2SKIN_SKIN_H @@ -157,12 +157,13 @@ protected: virtual int GetTab(int n) { return cSkinDisplayMenu::Tab(n); } virtual bool HasTabText(int Index, int n); virtual void SetEditableWidth(int Width) { cSkinDisplayMenu::SetEditableWidth(Width); } + virtual int MaxItems(void) { return mMaxItems;} + virtual void SetMaxItems(int MaxItems) { mMaxItems = MaxItems; } public: cText2SkinDisplayMenu(cText2SkinLoader *Loader); virtual ~cText2SkinDisplayMenu(); - virtual int MaxItems(void) { return mMaxItems; } virtual void Clear(void); virtual void SetTitle(const char *Title); virtual void SetButtons(const char *Red, const char *Green, const char *Yellow, const char *Blue); @@ -182,7 +183,7 @@ inline bool cText2SkinDisplayMenu::HasTabText(int Index, int n) if (Index < 0 || mItems.size () > (uint)Index) return n == -1 ? mItems[Index].text.length() > 0 - : mItems[Index].tabs[n].length() > 0; + : mItems[Index].tabs[n].length() > 0; return false; } @@ -205,6 +206,7 @@ private: protected: virtual cxType GetTokenData(const txToken &Token); + virtual bool HasTabText(int Index, int n); public: cText2SkinDisplayTracks(cText2SkinLoader *Loader, const char *Title, int NumTracks, @@ -215,6 +217,13 @@ public: virtual void Flush(void) { cText2SkinRender::Flush(); } }; + +inline bool cText2SkinDisplayTracks::HasTabText(int Index, int n) +{ + if (Index < 0 || mItems.size () > (uint)Index && n <= 0) + return mItems[Index].text.length() > 0; + return false; +} #endif #endif // VDR_TEXT2SKIN_SKIN_H |