SASC-NG
DVBSoftCAM

cOptInt Class Reference

#include <opts.h>

Inheritance diagram for cOptInt:

List of all members.

Public Member Functions

 cOptInt (const char *Name, const char *Title, int *Storage, int Min, int Max)
virtual void Parse (const char *Value)
virtual void Backup (void)
virtual bool Set (void)
virtual void Store (const char *PreStr)
virtual void Create (cOsdMenu *menu)

Protected Attributes

int * storage
int value
int min
int max

Detailed Description

Definition at line 52 of file opts.h.


Constructor & Destructor Documentation

cOptInt::cOptInt ( const char *  Name,
const char *  Title,
int *  Storage,
int  Min,
int  Max 
)

Definition at line 279 of file sc.c.

References max, min, and storage.

:cOpt(Name,Title)
{
  storage=Storage; min=Min; max=Max;
}

Member Function Documentation

void cOptInt::Backup ( void  ) [virtual]

Implements cOpt.

Definition at line 290 of file sc.c.

References storage, and value.

{
  value=*storage;
}
void cOptInt::Create ( cOsdMenu *  menu) [virtual]

Implements cOpt.

Reimplemented in cOptSel, and cOptBool.

Definition at line 306 of file sc.c.

References cOsdMenu::Add(), max, min, cOpt::title, tr, and value.

{
  menu->Add(new cMenuEditIntItem(tr(title),&value,min,max));
}
void cOptInt::Parse ( const char *  Value) [virtual]

Implements cOpt.

Definition at line 285 of file sc.c.

References storage.

{
  *storage=atoi(Value);
}
bool cOptInt::Set ( void  ) [virtual]

Implements cOpt.

Definition at line 295 of file sc.c.

References storage, and value.

{
  if(value!=*storage) { *storage=value; return true; }
  return false;
}
void cOptInt::Store ( const char *  PreStr) [virtual]

Implements cOpt.

Definition at line 301 of file sc.c.

References cOpt::FullName(), cPlugin::SetupStore(), and storage.


Member Data Documentation

int cOptInt::max [protected]

Definition at line 54 of file opts.h.

Referenced by cOptInt(), cOptSel::Create(), and Create().

int cOptInt::min [protected]

Definition at line 54 of file opts.h.

Referenced by cOptInt(), and Create().

int* cOptInt::storage [protected]

Definition at line 54 of file opts.h.

Referenced by Backup(), cOptInt(), Parse(), Set(), and Store().

int cOptInt::value [protected]

Definition at line 54 of file opts.h.

Referenced by Backup(), cOptBool::Create(), cOptSel::Create(), Create(), and Set().


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines