kremotecontrol
modedialog.cpp
Go to the documentation of this file.
35 ModeDialog::ModeDialog(Remote *remote, Mode *mode, QWidget *parent): KDialog(parent), m_remote(remote), m_mode(mode) {
43 connect(ui.cbButtonForward, SIGNAL(currentIndexChanged(int)), this, SLOT(forwardButtonChanged()));
44 connect(ui.cbButtonBackward, SIGNAL(currentIndexChanged(int)), this, SLOT(backwardButtonChanged()));
68 ui.cbButtonBackward->setCurrentIndex(ui.cbButtonBackward->findData(remote->previousModeButton()));
88 connect(new RemoteControl(remote->name()), SIGNAL(buttonPressed(RemoteControlButton)), SLOT(buttonPressed(RemoteControlButton)));
126 m_remote->setNextModeButton(ui.cbButtonForward->itemData(ui.cbButtonForward->currentIndex()).toString());
127 m_remote->setPreviousModeButton(ui.cbButtonBackward->itemData(ui.cbButtonBackward->currentIndex()).toString());
135 disconnect(ui.cbButtonBackward, SIGNAL(currentIndexChanged(int)), this, SLOT(backwardButtonChanged()));
136 QString forwardButton = ui.cbButtonForward->itemData(ui.cbButtonForward->currentIndex()).toString();
138 connect(ui.cbButtonBackward, SIGNAL(currentIndexChanged(int)), this, SLOT(backwardButtonChanged()));
142 disconnect(ui.cbButtonForward, SIGNAL(currentIndexChanged(int)), this, SLOT(forwardButtonChanged()));
143 QString backwardButton = ui.cbButtonBackward->itemData(ui.cbButtonBackward->currentIndex()).toString();
145 connect(ui.cbButtonForward, SIGNAL(currentIndexChanged(int)), this, SLOT(forwardButtonChanged()));
158 Remote::ModeChangeMode modeChangeMode = ui.gbModeCycle->isChecked() ? Remote::Cycle : Remote::Group;
161 if(KMessageBox::questionYesNo(this, i18n("Using the cycle function will remove all duplicate button assignments from your modes. Are you sure that you would like to proceed?"), i18n("Change mode switch behavior")) == KMessageBox::Yes){
void addButtons(const QStringList &buttonList)
Definition: modedialog.cpp:176
QString remoteName() const
Retrieves the name of the RemoteControl this button comes from.
Definition: remotecontrolbutton.cpp:305
void considerButtonEvents(const QString &remoteName)
Definition: dbusinterface.cpp:270
Definition: remote.h:39
Definition: remotecontrol.h:35
void setPreviousModeButton(const QString &button)
Definition: remote.cpp:409
void ignoreButtonEvents(const QString &remoteName)
Definition: dbusinterface.cpp:280
void setModeChangeMode(ModeChangeMode modeChangeMode)
Definition: remote.cpp:367
QStringList availableModeSwitchButtons(const Mode *mode=0) const
Get buttons available for this mode (Free buttons + the current button for this mode) ...
Definition: remote.cpp:377
Definition: remote.h:39
Definition: remotecontrolbutton.h:30
Definition: remote.h:32
ModeDialog(Remote *remote, Mode *mode=0, QWidget *parent=0)
Creates a ModeDialog for the given Remote.
Definition: modedialog.cpp:35
QStringList availableModeCycleButtons() const
Get buttons available for switching to the next or previous mode (Free buttons + the current nextMode...
Definition: remote.cpp:385
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 23:07:43 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 23:07:43 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.