Home2L - C/C++ API v1.4-0-g38cc (2024-05-25)
Smart Tools for a Private Home
|
Screen with an input line widget.
Since the on-screen keyboard requires some space, it is useful to use CInputLine indirectly with this screen. It shows an input line on top and a button bar below. The button bar shows a back/escape button on the left, an "OK" and standard editing buttons on the right and may contain optional user buttons in the center.
Definition at line 899 of file ui_widgets.H.
#include "ui_widgets.H"
Public Member Functions | |
Setup ... | |
void | Setup (const char *label, const char *inputPreset, TColor color=GREY, int userBtns=0, CButton **userBtnList=NULL, const int *userBtnWidth=NULL) |
Accessing the input line ... | |
CInputLine * | InputLine () |
void | SetInput (const char *_inputStr=NULL, int _mark0=0, int _markD=0) |
see CInputLine::SetInput (). | |
void | GetInput (CString *ret) |
see CInputLine::GetInput (). | |
bool | InputModified () |
see CInputLine::InputModified (). | |
Public Member Functions inherited from CScreen | |
void | AddWidget (CWidget *widget, int layer=0) |
void | DelWidget (CWidget *widget) |
void | DelAllWidgets () |
void | Run () |
Activate the screen, iterate until Return() is called and then return to the previously active screen. More... | |
void | Return () |
Let Run() return at next occasion. | |
void | SetKeyboard (bool on) |
bool | HasKeyboard () |
bool | IsActive () |
virtual void | Activate (bool on=true) |
void | Deactivate () |
Protected Member Functions | |
Callbacks for derived classes ... | |
virtual void | Commit () |
Called on push of the "OK" button. May call Return() on success or not to continue editing. | |
virtual void | Cancel () |
virtual void | OnUserButtonPushed (CButton *btn, bool longPush) |
Called on push of any user button. | |
Additional Inherited Members | |
Static Public Member Functions inherited from CScreen | |
static void | ClassInit () |
static void | ClassDone () |
static void | Refresh () |
Refresh screen (e.g. after the app has been woken up in Android). | |
static void | EmulateOff (bool off) |
Emulate screen off. | |
static void | EmulateStandby (bool standby) |
Emulate screen standby mode. | |
static class CScreen * | ActiveScreen () |
void CInputScreen::Setup | ( | const char * | label, |
const char * | inputPreset, | ||
TColor | color = GREY , |
||
int | userBtns = 0 , |
||
CButton ** | userBtnList = NULL , |
||
const int * | userBtnWidth = NULL |
||
) |
Set up the screen.
label | is an optional label printed before the input line (may be NULL for no label). |
inputPreset | is the preset for the input string. |
color | is the button color, individual colors may be set afterwards. |
userBtns | is the number of user buttons. |
userBtnList | is a list of pointers to the user button (may be NULL if userBtns == 0). |
userBtnWidth | is a list of width arguments for the user button (see LayoutRow(); may be NULL if userBtns == 0). For the user buttons, the area and color are set according to the parameters. The label must be set by the caller. |
|
inlineprotectedvirtual |
Called on push of the "back" button and after an eventual "are you sure?" confirmation. Must call Return().
Definition at line 938 of file ui_widgets.H.