#include "irctrl.h"
+#include <cstdlib>
IrCtrl::IrCtrl()
{
+ std::system("./lircctl start");
+}
+
+IrCtrl::~IrCtrl()
+{
+ std::system("./lircctl stop");
}
void IrCtrl::setRemoteName(const QString &newRemoteName)
Q_OBJECT
public:
IrCtrl();
+ ~IrCtrl();
void setRemoteName(const QString &newRemoteName);
"/usr/share/icons/hicolor/48x48/hildon/statusarea_volume_mute.png"
};
- char *buttonTitles[] = {
- "Vol Up",
- "Vol Down",
- "Ch Up",
- "Ch Down",
- "Power Off",
- "Mute"
- };
-
for (int i = 0; i < BUTTON_COUNT; ++i)
{
QToolButton *button = new QToolButton(this);
this->setAttribute(Qt::WA_TranslucentBackground);
}
- void MainWidget::paintEvent(QPaintEvent *event)
+ void MainWidget::paintEvent(QPaintEvent*)
{
QPainter p(this);
p.setBrush(QColor(0, 0, 0, 128));
SettingsDlg::SettingsDlg(QWidget *parent)
: QDialog(parent)
{
+ this->setWindowTitle(tr("Settings"));
layout = new QHBoxLayout(this);
- layout->addWidget(new QLabel("foo"));
+
+ alphabetList = new QListWidget(this);
+ for (char c = 'a'; c <= 'z'; ++c)
+ {
+ alphabetList.addItem(QString(c));
+ }
+ layout->addWidget(alphabetList);
+
layout->addWidget(new QLabel("bar"));
layout->addWidget(new QLabel("baz"));
this->setLayout(layout);