/*
 * cdda_menu.h: The menu implementations
 *
 * See the README file for copyright information and how to reach the author.
 *
 * $Id: cdda_menu.h,v 1.1.1.4 2005/06/27 13:34:02 cm Exp $
 */

#ifndef __CDDAMENU_H
#define __CDDAMENU_H

#include <vdr/osd.h>
#include <vdr/menu.h>
#include <vdr/menuitems.h>
#include "cdda_player.h"
#include "cdda_playlist.h"

class cCddaMenu : public cOsdMenu {
  private:
    cCddaPlaylist *po_playlist;
    void Initialize();
    void Set();
  public:
    cCddaMenu();
    ~cCddaMenu();
    eOSState ProcessKey(eKeys Key);
};

class cCddaMenuCommands : public cOsdMenu {
  private:
    unsigned int selectedTrack;
    cCddaPlaylist *po_playlist;
    void Set();
  public:
    cCddaMenuCommands(cCddaPlaylist *playlist, unsigned int track);
    ~cCddaMenuCommands();
    eOSState ProcessKey(eKeys Key);
};

class cCddaMenuTrackInfo : public cOsdMenu {
  private:
    const char *ConcatStrings(const char *desc, const char *text, bool indent = false);
    void Set(cCddaDisc *disc, cCddaTrack *track);
  public:
    cCddaMenuTrackInfo(const char *Title, cCddaDisc *disc, cCddaTrack *track);
    virtual ~cCddaMenuTrackInfo();
};

class cCddaSetupMenu : public cMenuSetupPage {
  private:
    int newMenuEntry;
    int newSkipSeconds;
    int newAudioOnly;
    int newSkipBackMargin;
    int newAutoReplay;
    int newCddbCache;
    int newCddbPriority;
    char *p_newCddbServerFqdn;
    int newCddbServerPort;
    int newInfoView;
    const char *cddbPriorityTexts[3];
  protected:
    void Store(void);
  public:
    cCddaSetupMenu(void);
};

#endif
