22 m_title(tr(
"Settings Editor"))
42 LOG(VB_GENERAL, LOG_EMERG,
43 "Theme is missing critical theme elements.");
55 for (
int i = -8; i <= 8; i++)
58 (
GetChild(QString(
"value%1%2").arg(i >= 0?
"+" :
"").arg(i)));
63 (
GetChild(QString(
"shape%1%2").arg(i >= 0?
"+" :
"").arg(i)));
87 QList<QString>settingsList =
m_settings.keys();
88 QList<QString>::iterator it = settingsList.begin();
93 while (it != settingsList.end())
108 QList<QString>settingsList =
m_settings.keys();
109 QList<QString>::iterator it = settingsList.begin();
111 while (it != settingsList.end())
114 QVariant::fromValue(*it));
134 bool changed =
false;
136 QHash <QString, QString>::const_iterator it =
m_settingValues.constBegin();
139 if ((!it.value().isEmpty()) ||
189 for (
int i = -8; i <= 8; i++)
193 if (((i < 0) && ((curPos + i) >= 0)) ||
194 ((i > 0) && (((recs-1) - i) >= curPos)))
static bool BackendIsRunning(void)
a backend process is running on this host
void SaveSetting(const QString &key, int newValue)
QString GetSetting(const QString &key, const QString &defaultval="")
void SendMessage(const QString &message)
bool IsMasterHost(void)
is this the same host as the master
Screen in which all other widgets are contained and rendered.
void LoadInBackground(const QString &message="")
void BuildFocusList(void)
A widget for rendering primitive shapes and lines.
A text entry and edit widget.
QString GetText(void) const
void SetText(const QString &text, bool moveCursor=true)
All purpose text widget, displays a text string.
virtual void SetText(const QString &text)
MythUIType * GetChild(const QString &name) const
Get a named child of this UIType.
void Init(void) override
Initialize the settings screen with the loaded data.
QHash< QString, QString > m_origValues
void selectionChanged(MythUIButtonListItem *item)
Slot handler for buttonlist current item changes.
void Load(void) override
Loads the current values for the specified settings list.
RawSettingsEditor(MythScreenStack *parent, const char *name=nullptr)
Raw Settings Editor constructor.
bool Create(void) override
Creates the UI screen.
MythUIButton * m_saveButton
QHash< int, MythUIText * > m_prevNextTexts
QHash< QString, QString > m_settingValues
MythUIButton * m_cancelButton
void Save(void)
Save editted values and clear settings cache if necessary.
QMap< QString, QString > m_settings
QHash< int, MythUIShape * > m_prevNextShapes
MythUITextEdit * m_settingValue
void valueChanged(void)
Tracks current value for a setting when the value is editted.
MythUIButtonList * m_settingsList
void updatePrevNextTexts(void)
Updates previous and next text areas.
static bool LoadWindowFromXML(const QString &xmlfile, const QString &windowname, MythUIType *parent)
MythCoreContext * gCoreContext
This global variable contains the MythCoreContext instance for the app.
#define LOG(_MASK_, _LEVEL_, _QSTRING_)