MythTV  0.26-pre
expertsettingseditor.h
Go to the documentation of this file.
00001 #ifndef EXPERTSETTINGSEDITOR_H
00002 #define EXPERTSETTINGSEDITOR_H
00003 
00004 #include "mythcorecontext.h"
00005 #include "mythdbcon.h"
00006 #include "rawsettingseditor.h"
00007 
00008 class ExpertSettingsEditor : public RawSettingsEditor
00009 {
00010     Q_OBJECT
00011 
00012   public:
00013     ExpertSettingsEditor(MythScreenStack *parent, const char *name = 0)
00014       : RawSettingsEditor(parent, name)
00015     {
00016         MSqlQuery query(MSqlQuery::InitCon());
00017 
00018         query.prepare("SELECT value, data "
00019                         "FROM settings "
00020                         "WHERE hostname = :HOSTNAME");
00021         query.bindValue(":HOSTNAME", gCoreContext->GetHostName());
00022 
00023         if (query.exec())
00024         {
00025             while (query.next())
00026             {
00027                 m_settings[query.value(0).toString()] =
00028                     query.value(0).toString();
00029             }
00030         }
00031 
00032         m_title = tr("Expert Settings Editor");
00033         m_settings["EventCmdRecPending"] = tr("Recording Pending");
00034     }
00035 };
00036 
00037 #endif
00038 
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends