ubitx-iop/ubitx_iop/menu.h

53 lines
1.1 KiB
C
Raw Normal View History

//======================================================================
// menu.h
//======================================================================
#ifndef __menu_h__
#define __menu_h__
// 16 characters on display
#define MAX_TEXT_LEN 16
#define MENU_SELECTED_CHAR '>'
/*
public class MenuItem {
public:
MenuItem(bool active = true, int timeout = 0): _active(active), _timeout(timeout), _elapsed(0) {}
void update() {
if ((_timeout > 0) && (_elapsed > _timeout)) {
_active = false;
}
}
inline void activate() { _active = true; _elapsed = 0; }
inline void deactivate() { _active = false; }
virtual MenuItem* accept();
virtual MenuItem* reject();
virtual MenuItem* next();
virtual MenuItem* prev();
private:
bool _active;
int _timeout;
elapsedMillis _elapsed;
};
public class SSBMenu {
public:
private:
};
public class DigiMenu {
public:
private:
}
public class CWMenu {
public:
private:
};
*/
#endif
//======================================================================
// EOF
//======================================================================