summaryrefslogtreecommitdiffstats
path: root/plugins/lirc
diff options
context:
space:
mode:
authorMichele Calgaro <michele.calgaro@yahoo.it>2022-05-30 19:40:31 +0900
committerSlávek Banko <slavek.banko@axis.cz>2022-05-30 21:55:12 +0200
commit9d7329284fd42187092c829ae6ed030561002776 (patch)
tree1d53503d17938eca725caee7ff783fccf52ca509 /plugins/lirc
parentfac82f62f156c76cb4b23c313111283b30a778b5 (diff)
downloadtderadio-9d7329284fd42187092c829ae6ed030561002776.tar.gz
tderadio-9d7329284fd42187092c829ae6ed030561002776.zip
Standardize folder structure.
Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it> (cherry picked from commit d95a4fea540b371fa86493d069fdbd54f33c5b40)
Diffstat (limited to 'plugins/lirc')
-rw-r--r--plugins/lirc/CMakeL10n.txt6
-rw-r--r--plugins/lirc/Makefile.am28
-rw-r--r--plugins/lirc/default-dot-lircrc6
-rw-r--r--plugins/lirc/lirc-configuration-ui.ui110
-rw-r--r--plugins/lirc/lirc-configuration.cpp193
-rw-r--r--plugins/lirc/lirc-configuration.h61
-rw-r--r--plugins/lirc/lircsupport.cpp553
-rw-r--r--plugins/lirc/lircsupport.h160
-rw-r--r--plugins/lirc/listviewitem_lirc.cpp51
-rw-r--r--plugins/lirc/listviewitem_lirc.h52
-rw-r--r--plugins/lirc/po/Makefile.am2
-rw-r--r--plugins/lirc/po/de.po208
-rw-r--r--plugins/lirc/po/pt.po195
-rw-r--r--plugins/lirc/po/ru.po202
-rw-r--r--plugins/lirc/po/tderadio-lirc.pot198
15 files changed, 2025 insertions, 0 deletions
diff --git a/plugins/lirc/CMakeL10n.txt b/plugins/lirc/CMakeL10n.txt
new file mode 100644
index 0000000..e864b38
--- /dev/null
+++ b/plugins/lirc/CMakeL10n.txt
@@ -0,0 +1,6 @@
+##### create translation templates ##############
+
+tde_l10n_create_template(
+ CATALOG "tderadio-lirc"
+ DESTINATION "po"
+)
diff --git a/plugins/lirc/Makefile.am b/plugins/lirc/Makefile.am
new file mode 100644
index 0000000..1ede5f5
--- /dev/null
+++ b/plugins/lirc/Makefile.am
@@ -0,0 +1,28 @@
+
+SUBDIRS = po .
+
+INCLUDES = $(all_includes)
+METASOURCES = AUTO
+
+libtderadio_LTLIBRARIES = liblirc.la
+liblirc_la_SOURCES = lircsupport.cpp lirc-configuration-ui.ui \
+ lirc-configuration.cpp listviewitem_lirc.cpp
+liblirc_la_LDFLAGS = -module -avoid-version $(KDE_RPATH) $(all_libraries)
+liblirc_la_LIBADD = $(LIB_LIRC)
+
+noinst_HEADERS = lircsupport.h lirc-configuration.h listviewitem_lirc.h
+
+
+install-data-local:
+ $(mkinstalldirs) "$(DESTDIR)$(kde_datadir)/tderadio/"
+ $(INSTALL_DATA) "$(srcdir)/default-dot-lircrc" "$(DESTDIR)$(kde_datadir)/tderadio/default-dot-lircrc"
+
+uninstall-local:
+ -rm -f "$(DESTDIR)$(kde_datadir)/tderadio/default-dot-lircrc"
+
+#messages: rc.cpp
+# $(XGETTEXT) *.cpp *.h -o po/tderadio-lirc.pot
+
+messages: rc.cpp
+ $(EXTRACTRC) *.rc *.ui >> rc.cpp
+ $(XGETTEXT) rc.cpp *.h *.cpp -o po/tderadio-lirc.pot
diff --git a/plugins/lirc/default-dot-lircrc b/plugins/lirc/default-dot-lircrc
new file mode 100644
index 0000000..0462104
--- /dev/null
+++ b/plugins/lirc/default-dot-lircrc
@@ -0,0 +1,6 @@
+
+begin
+ prog = tderadio
+ config = eventmap
+ repeat = 1
+end
diff --git a/plugins/lirc/lirc-configuration-ui.ui b/plugins/lirc/lirc-configuration-ui.ui
new file mode 100644
index 0000000..ca0ce59
--- /dev/null
+++ b/plugins/lirc/lirc-configuration-ui.ui
@@ -0,0 +1,110 @@
+<!DOCTYPE UI><UI version="3.3" stdsetdef="1">
+<class>LIRCConfigurationUI</class>
+<author>Ernst Martin Witte</author>
+<widget class="TQWidget">
+ <property name="name">
+ <cstring>LIRCConfigurationUI</cstring>
+ </property>
+ <property name="geometry">
+ <rect>
+ <x>0</x>
+ <y>0</y>
+ <width>600</width>
+ <height>585</height>
+ </rect>
+ </property>
+ <property name="caption">
+ <string>LIRCConfigurationUI</string>
+ </property>
+ <grid>
+ <property name="name">
+ <cstring>unnamed</cstring>
+ </property>
+ <widget class="TDEListView" row="0" column="0">
+ <column>
+ <property name="text">
+ <string>Action</string>
+ </property>
+ <property name="clickable">
+ <bool>true</bool>
+ </property>
+ <property name="resizable">
+ <bool>true</bool>
+ </property>
+ </column>
+ <column>
+ <property name="text">
+ <string>LIRC String</string>
+ </property>
+ <property name="clickable">
+ <bool>true</bool>
+ </property>
+ <property name="resizable">
+ <bool>true</bool>
+ </property>
+ </column>
+ <column>
+ <property name="text">
+ <string>Alternative LIRC String</string>
+ </property>
+ <property name="clickable">
+ <bool>true</bool>
+ </property>
+ <property name="resizable">
+ <bool>true</bool>
+ </property>
+ </column>
+ <property name="name">
+ <cstring>m_ActionList</cstring>
+ </property>
+ <property name="allColumnsShowFocus">
+ <bool>true</bool>
+ </property>
+ <property name="itemMargin">
+ <number>2</number>
+ </property>
+ <property name="rootIsDecorated">
+ <bool>false</bool>
+ </property>
+ <property name="resizeMode">
+ <enum>AllColumns</enum>
+ </property>
+ <property name="defaultRenameAction">
+ <enum>Accept</enum>
+ </property>
+ <property name="fullWidth">
+ <bool>true</bool>
+ </property>
+ </widget>
+ <widget class="Line" row="1" column="0">
+ <property name="name">
+ <cstring>line1</cstring>
+ </property>
+ <property name="frameShape">
+ <enum>HLine</enum>
+ </property>
+ <property name="frameShadow">
+ <enum>Sunken</enum>
+ </property>
+ <property name="orientation">
+ <enum>Horizontal</enum>
+ </property>
+ </widget>
+ <widget class="TQLabel" row="2" column="0">
+ <property name="name">
+ <cstring>m_LabelHints</cstring>
+ </property>
+ <property name="text">
+ <string>textLabel1</string>
+ </property>
+ </widget>
+ </grid>
+</widget>
+<customwidgets>
+</customwidgets>
+<pixmapfunction>SmallIconSet</pixmapfunction>
+<layoutdefaults spacing="6" margin="0"/>
+<includes>
+ <include location="global" impldecl="in implementation">tdelistview.h</include>
+</includes>
+</UI>
diff --git a/plugins/lirc/lirc-configuration.cpp b/plugins/lirc/lirc-configuration.cpp
new file mode 100644
index 0000000..470b2ff
--- /dev/null
+++ b/plugins/lirc/lirc-configuration.cpp
@@ -0,0 +1,193 @@
+/***************************************************************************
+ lirc-configuration.cpp - description
+ -------------------
+ begin : Sat May 21 2005
+ copyright : (C) 2005 by Martin Witte
+ email : witte@kawo1.rwth-aachen.de
+ ***************************************************************************/
+
+/***************************************************************************
+ * *
+ * This program is free software; you can redistribute it and/or modify *
+ * it under the terms of the GNU General Public License as published by *
+ * the Free Software Foundation; either version 2 of the License, or *
+ * (at your option) any later version. *
+ * *
+ ***************************************************************************/
+
+#include <tdelistview.h>
+#include <tdelocale.h>
+
+#include <tqlistview.h>
+#include <tqlabel.h>
+
+#include "lirc-configuration.h"
+#include "lircsupport.h"
+#include "listviewitem_lirc.h"
+
+LIRCConfiguration::LIRCConfiguration (TQWidget *parent, LircSupport *dev)
+ : LIRCConfigurationUI(parent),
+ m_LIRC (dev),
+ m_dirty(true),
+ m_ignore_gui_updates(false)
+{
+ m_descriptions[LIRC_DIGIT_0] = i18n("digit 0");
+ m_descriptions[LIRC_DIGIT_1] = i18n("digit 1");
+ m_descriptions[LIRC_DIGIT_2] = i18n("digit 2");
+ m_descriptions[LIRC_DIGIT_3] = i18n("digit 3");
+ m_descriptions[LIRC_DIGIT_4] = i18n("digit 4");
+ m_descriptions[LIRC_DIGIT_5] = i18n("digit 5");
+ m_descriptions[LIRC_DIGIT_6] = i18n("digit 6");
+ m_descriptions[LIRC_DIGIT_7] = i18n("digit 7");
+ m_descriptions[LIRC_DIGIT_8] = i18n("digit 8");
+ m_descriptions[LIRC_DIGIT_9] = i18n("digit 9");
+ m_descriptions[LIRC_POWER_ON] = i18n("Power On");
+ m_descriptions[LIRC_POWER_OFF] = i18n("Power Off");
+ m_descriptions[LIRC_PAUSE] = i18n("Pause");
+ m_descriptions[LIRC_RECORD_START] = i18n("Start Recording");
+ m_descriptions[LIRC_RECORD_STOP] = i18n("Stop Recording");
+ m_descriptions[LIRC_VOLUME_INC] = i18n("Increase Volume");
+ m_descriptions[LIRC_VOLUME_DEC] = i18n("Decrease Volume");
+ m_descriptions[LIRC_CHANNEL_NEXT] = i18n("Next Channel");
+ m_descriptions[LIRC_CHANNEL_PREV] = i18n("Previous Channel");
+ m_descriptions[LIRC_SEARCH_NEXT] = i18n("Search Next Channel");
+ m_descriptions[LIRC_SEARCH_PREV] = i18n("Search Previous Channel");
+ m_descriptions[LIRC_SLEEP] = i18n("Enable Sleep Countdown");
+ m_descriptions[LIRC_APPLICATION_QUIT] = i18n("Quit TDERadio");
+
+ int k = 0;
+ m_order[k++] = LIRC_DIGIT_0;
+ m_order[k++] = LIRC_DIGIT_1;
+ m_order[k++] = LIRC_DIGIT_2;
+ m_order[k++] = LIRC_DIGIT_3;
+ m_order[k++] = LIRC_DIGIT_4;
+ m_order[k++] = LIRC_DIGIT_5;
+ m_order[k++] = LIRC_DIGIT_6;
+ m_order[k++] = LIRC_DIGIT_7;
+ m_order[k++] = LIRC_DIGIT_8;
+ m_order[k++] = LIRC_DIGIT_9;
+ m_order[k++] = LIRC_POWER_ON;
+ m_order[k++] = LIRC_POWER_OFF;
+ m_order[k++] = LIRC_PAUSE;
+ m_order[k++] = LIRC_RECORD_START;
+ m_order[k++] = LIRC_RECORD_STOP;
+ m_order[k++] = LIRC_VOLUME_INC;
+ m_order[k++] = LIRC_VOLUME_DEC;
+ m_order[k++] = LIRC_CHANNEL_NEXT;
+ m_order[k++] = LIRC_CHANNEL_PREV;
+ m_order[k++] = LIRC_SEARCH_NEXT;
+ m_order[k++] = LIRC_SEARCH_PREV;
+ m_order[k++] = LIRC_SLEEP;
+ m_order[k++] = LIRC_APPLICATION_QUIT;
+
+ m_ActionList->setSorting(-1);
+ m_ActionList->setColumnWidthMode(0, TQListView::Maximum);
+ m_ActionList->setColumnWidthMode(1, TQListView::Maximum);
+ m_ActionList->setColumnWidthMode(2, TQListView::Maximum);
+
+ connect(m_ActionList, TQT_SIGNAL(itemRenamed(TQListViewItem*, int)), this, TQT_SLOT(slotSetDirty()));
+ slotCancel();
+}
+
+
+LIRCConfiguration::~LIRCConfiguration ()
+{
+}
+
+
+void LIRCConfiguration::slotOK()
+{
+ if (m_dirty && m_LIRC) {
+ TQListViewItem *item = m_ActionList->firstChild();
+
+ TQMap<LIRC_Actions, TQString> actions;
+ TQMap<LIRC_Actions, TQString> alt_actions;
+
+ for (int i = 0; item; ++i, item = item->nextSibling()) {
+ LIRC_Actions action = m_order[i];
+ actions[action] = item->text(1);
+ alt_actions[action] = item->text(2);
+ }
+ m_LIRC->setActions(actions, alt_actions);
+ }
+ m_dirty = false;
+}
+
+
+void LIRCConfiguration::slotCancel()
+{
+ if (m_dirty) {
+ m_ignore_gui_updates = true;
+ m_ActionList->clear();
+ if (m_LIRC) {
+ const TQMap<LIRC_Actions, TQString> &actions = m_LIRC->getActions();
+ const TQMap<LIRC_Actions, TQString> &alt_actions = m_LIRC->getAlternativeActions();
+
+ for (unsigned i = 0; m_order.contains(i) && i < m_order.count(); ++i) {
+ LIRC_Actions action = m_order[i];
+ addKey(m_descriptions[action], actions[action], alt_actions[action]);
+ }
+ }
+
+ slotRenamingStopped(NULL, -1);
+ m_ignore_gui_updates = false;
+ }
+ m_dirty = false;
+}
+
+
+void LIRCConfiguration::addKey(const TQString &descr, const TQString &key, const TQString &alt_key)
+{
+ ListViewItemLirc *item = new ListViewItemLirc(m_ActionList, m_ActionList->lastChild());
+ if (item) {
+ TQObject::connect(item, TQT_SIGNAL(sigRenamingStarted (ListViewItemLirc *, int)),
+ this, TQT_SLOT (slotRenamingStarted(ListViewItemLirc *, int)));
+ TQObject::connect(item, TQT_SIGNAL(sigRenamingStopped (ListViewItemLirc *, int)),
+ this, TQT_SLOT (slotRenamingStopped(ListViewItemLirc *, int)));
+ item->setText(0, descr);
+ item->setText(1, key);
+ item->setText(2, alt_key);
+ item->setRenameEnabled(1, true);
+ item->setRenameEnabled(2, true);
+ }
+}
+
+void LIRCConfiguration::slotUpdateConfig()
+{
+ slotSetDirty();
+ slotCancel();
+}
+
+void LIRCConfiguration::slotRawLIRCSignal(const TQString &val, int /*repeat_counter*/, bool &consumed)
+{
+ TQListViewItem *_it = m_ActionList->currentItem();
+ ListViewItemLirc *it = static_cast<ListViewItemLirc*>(_it);
+ if (it->isRenamingInProcess()) {
+ int col = it->getRenamingColumn();
+ it->cancelRename(col);
+ it->setText(col, val);
+ consumed = true;
+ m_dirty = true;
+ }
+}
+
+void LIRCConfiguration::slotRenamingStarted(ListViewItemLirc */*sender*/, int /*col*/)
+{
+ m_LabelHints->setText(i18n("Enter the key string of your remote or just press the button on your remote control"));
+}
+
+
+void LIRCConfiguration::slotRenamingStopped(ListViewItemLirc */*sender*/, int /*col*/)
+{
+ m_LabelHints->setText(i18n("Double Click on the entries to change the assignments"));
+}
+
+
+void LIRCConfiguration::slotSetDirty()
+{
+ if (!m_ignore_gui_updates) {
+ m_dirty = true;
+ }
+}
+
+#include "lirc-configuration.moc"
diff --git a/plugins/lirc/lirc-configuration.h b/plugins/lirc/lirc-configuration.h
new file mode 100644
index 0000000..70c1ae2
--- /dev/null
+++ b/plugins/lirc/lirc-configuration.h
@@ -0,0 +1,61 @@
+/***************************************************************************
+ lirc-configuration.h - description
+ -------------------
+ begin : Sat May 21 2005
+ copyright : (C) 2005 by Martin Witte
+ email : witte@kawo1.rwth-aachen.de
+ ***************************************************************************/
+
+/***************************************************************************
+ * *
+ * This program is free software; you can redistribute it and/or modify *
+ * it under the terms of the GNU General Public License as published by *
+ * the Free Software Foundation; either version 2 of the License, or *
+ * (at your option) any later version. *
+ * *
+ ***************************************************************************/
+
+#ifndef KRADIO_LIRC_CONFIGURATION_H
+#define KRADIO_LIRC_CONFIGURATION_H
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include "lirc-configuration-ui.h"
+#include "lircsupport.h"
+#include "listviewitem_lirc.h"
+
+class LIRCConfiguration : public LIRCConfigurationUI
+{
+Q_OBJECT
+
+public :
+ LIRCConfiguration (TQWidget *parent, LircSupport *);
+ ~LIRCConfiguration ();
+
+protected slots:
+
+ void slotOK();
+ void slotCancel();
+ void slotSetDirty();
+
+ void slotUpdateConfig();
+ void slotRawLIRCSignal(const TQString &val, int repeat_counter, bool &consumed);
+
+ void slotRenamingStarted(ListViewItemLirc *, int);
+ void slotRenamingStopped(ListViewItemLirc *, int);
+
+protected:
+ void addKey(const TQString &descr, const TQString &key, const TQString &alt_key);
+
+ LircSupport *m_LIRC;
+
+ TQMap<int, LIRC_Actions> m_order;
+ TQMap<LIRC_Actions, TQString> m_descriptions;
+
+ bool m_dirty;
+ bool m_ignore_gui_updates;
+};
+
+#endif
diff --git a/plugins/lirc/lircsupport.cpp b/plugins/lirc/lircsupport.cpp
new file mode 100644
index 0000000..8fef92f
--- /dev/null
+++ b/plugins/lirc/lircsupport.cpp
@@ -0,0 +1,553 @@
+/***************************************************************************
+ lircsupport.cpp - description
+ -------------------
+ begin : Mon Feb 4 2002
+ copyright : (C) 2002 by Martin Witte / Frank Schwanz
+ email : witte@kawo1.rwth-aachen.de / schwanz@fh-brandenburg.de
+ ***************************************************************************/
+
+/***************************************************************************
+ * *
+ * This program is free software; you can redistribute it and/or modify *
+ * it under the terms of the GNU General Public License as published by *
+ * the Free Software Foundation; either version 2 of the License, or *
+ * (at your option) any later version. *
+ * *
+ ***************************************************************************/
+
+#include "lircsupport.h"
+
+#ifdef HAVE_LIRC
+#include <lirc/lirc_client.h>
+#endif
+
+#include <tqsocketnotifier.h>
+#include <tqtimer.h>
+#include <tqfile.h>
+
+#include <tdeapplication.h>
+#include <tdeaboutdata.h>
+#include <kstandarddirs.h>
+
+#include "../../src/include/errorlog-interfaces.h"
+#include "../../src/include/radiodevice_interfaces.h"
+#include "../../src/include/stationlist.h"
+#include "../../src/include/aboutwidget.h"
+
+#include "lirc-configuration.h"
+
+#include <cstdlib>
+
+#define LIRCRC ".lircrc"
+
+///////////////////////////////////////////////////////////////////////
+//// plugin library functions
+
+//#ifdef HAVE_LIRC
+PLUGIN_LIBRARY_FUNCTIONS(LircSupport, "tderadio-lirc", i18n("Linux Infrared Control (LIRC) Support"));
+//#endif
+
+/////////////////////////////////////////////////////////////////////////////
+
+LircSupport::LircSupport(const TQString &name)
+ : PluginBase(name, i18n("LIRC Plugin")),
+ m_TakeRawLIRC(false)
+{
+
+#ifdef HAVE_LIRC
+ logDebug(i18n("initializing tderadio lirc plugin"));
+ fprintf (stderr, "%s\n", (const char*)i18n("initializing tderadio lirc plugin").utf8());
+ char *prg = (char*)"tderadio";
+
+ TQString slircrc = getenv("HOME");
+ slircrc += "/" LIRCRC;
+
+ TQFile lircrc(slircrc);
+ if (!lircrc.exists()) {
+ logWarning(i18n("%1 does not exist. File was created with TDERadio's default .lircrc proposal").arg(LIRCRC));
+ TQFile default_lircrc(locate("data", "tderadio/default-dot-lircrc"));
+ lircrc.open(IO_WriteOnly);
+ default_lircrc.open(IO_ReadOnly);
+ char *buf = new char [default_lircrc.size() + 1];
+ default_lircrc.readBlock(buf, default_lircrc.size());
+ lircrc.writeBlock(buf, default_lircrc.size());
+ lircrc.close();
+ default_lircrc.close();
+ delete buf;
+ }
+
+ m_fd_lirc = lirc_init(prg, 1);
+ m_lirc_notify = 0;
+ m_lircConfig = 0;
+
+ if (m_fd_lirc != -1) {
+ if (lirc_readconfig (NULL, &m_lircConfig, NULL) == 0) {
+ m_lirc_notify = new TQSocketNotifier(m_fd_lirc, TQSocketNotifier::Read, this, "lirc_notifier");
+ if (m_lirc_notify)
+ TQObject::connect(m_lirc_notify, TQT_SIGNAL(activated(int)), this, TQT_SLOT(slotLIRC(int)));
+
+ // check config
+ lirc_config_entry *found = NULL;
+ for (lirc_config_entry *e = m_lircConfig->first; e; e = e->next) {
+ if (TQString(e->prog) == prg)
+ found = e;
+ }
+ if (!found) {
+ logWarning(i18n("There is no entry for tderadio in any of your .lircrc files."));
+ logWarning(i18n("Please setup your .lircrc files correctly."));
+ m_TakeRawLIRC = true;
+ }
+
+ } else {
+ lirc_deinit();
+ m_fd_lirc = -1;
+ }
+ }
+
+ if (m_fd_lirc == -1) {
+ logWarning(i18n("Initializing tderadio lirc plugin failed"));
+ fprintf (stderr, "%s\n", (const char*)i18n("Initializing tderadio lirc plugin failed").utf8());
+ } else {
+ logDebug(i18n("Initializing tderadio lirc plugin successful"));
+ fprintf (stderr, "%s\n", (const char*)i18n("Initializing tderadio lirc plugin successful").utf8());
+ }
+#endif
+
+ m_kbdTimer = new TQTimer (this);
+ TQObject::connect (m_kbdTimer, TQT_SIGNAL(timeout()), this, TQT_SLOT(slotKbdTimedOut()));
+
+ m_addIndex = 0;
+}
+
+
+LircSupport::~LircSupport()
+{
+#ifdef HAVE_LIRC
+ if (m_fd_lirc != -1)
+ lirc_deinit();
+ if (m_lircConfig)
+ lirc_freeconfig(m_lircConfig);
+ m_fd_lirc = -1;
+ m_lircConfig = 0;
+#endif
+}
+
+
+void LircSupport::slotLIRC(int /*socket*/ )
+{
+#ifdef HAVE_LIRC
+ if (!m_lircConfig || !m_lirc_notify || m_fd_lirc == -1)
+ return;
+
+ char *code = 0, *c = 0;
+ if (lirc_nextcode(&code) == 0) {
+ while(m_TakeRawLIRC || (lirc_code2char (m_lircConfig, code, &c) == 0 && c != NULL)) {
+
+ TQString x = c;
+ int repeat_counter = 1;
+ if (m_TakeRawLIRC || (TQString(c) == "eventmap")) {
+ TQStringList l = TQStringList::split(" ", code);
+ if (l.count() >=4) {
+ x = l[2];
+ repeat_counter = l[1].toInt(NULL, 16);
+ }
+ }
+
+ bool consumed = false;
+ logDebug(TQString("LIRC: ") + x);
+
+ emit sigRawLIRCSignal(x, repeat_counter, consumed);
+
+ if (!consumed) {
+ if (!checkActions(x, repeat_counter, m_Actions))
+ checkActions(x, repeat_counter, m_AlternativeActions);
+ }
+ }
+ }
+ else {
+ // some error has occurred on the socket => close lirc plugin
+ logWarning(i18n("Reading from LIRC socket failed. Disabling LIRC Functions till next start of tderadio"));
+ delete m_lirc_notify;
+ m_lirc_notify = NULL;
+ }
+
+ if (code)
+ free (code);
+#endif
+}
+
+
+void LircSupport::slotKbdTimedOut()
+{
+ activateStation (m_addIndex);
+ m_addIndex = 0;
+}
+
+
+void LircSupport::activateStation (int i)
+{
+ if (! sendActivateStation(i - 1))
+ sendActivateStation( (i + 9) % 10);
+}
+
+
+bool LircSupport::connectI (Interface *i)
+{
+ bool a = IRadioClient::connectI (i);
+ bool b = ITimeControlClient::connectI (i);
+ bool c = IRadioDevicePoolClient::connectI (i);
+ bool d = PluginBase::connectI(i);
+ bool e = ISoundStreamClient::connectI(i);
+ return a || b || c || d || e;
+}
+
+
+bool LircSupport::disconnectI (Interface *i)
+{
+ bool a = IRadioClient::disconnectI (i);
+ bool b = ITimeControlClient::disconnectI (i);
+ bool c = IRadioDevicePoolClient::disconnectI (i);
+ bool d = PluginBase::disconnectI(i);
+ bool e = ISoundStreamClient::disconnectI(i);
+ return a || b || c || d || e;
+}
+
+
+
+void LircSupport::saveState (TDEConfig *c) const
+{
+ c->writeEntry("LIRC_DIGIT_0", m_Actions[LIRC_DIGIT_0]);
+ c->writeEntry("LIRC_DIGIT_1", m_Actions[LIRC_DIGIT_1]);
+ c->writeEntry("LIRC_DIGIT_2", m_Actions[LIRC_DIGIT_2]);
+ c->writeEntry("LIRC_DIGIT_3", m_Actions[LIRC_DIGIT_3]);
+ c->writeEntry("LIRC_DIGIT_4", m_Actions[LIRC_DIGIT_4]);
+ c->writeEntry("LIRC_DIGIT_5", m_Actions[LIRC_DIGIT_5]);
+ c->writeEntry("LIRC_DIGIT_6", m_Actions[LIRC_DIGIT_6]);
+ c->writeEntry("LIRC_DIGIT_7", m_Actions[LIRC_DIGIT_7]);
+ c->writeEntry("LIRC_DIGIT_8", m_Actions[LIRC_DIGIT_8]);
+ c->writeEntry("LIRC_DIGIT_9", m_Actions[LIRC_DIGIT_9]);
+ c->writeEntry("LIRC_POWER_ON", m_Actions[LIRC_POWER_ON]);
+ c->writeEntry("LIRC_POWER_OFF", m_Actions[LIRC_POWER_OFF]);
+ c->writeEntry("LIRC_PAUSE", m_Actions[LIRC_PAUSE]);
+ c->writeEntry("LIRC_RECORD_START", m_Actions[LIRC_RECORD_START]);
+ c->writeEntry("LIRC_RECORD_STOP", m_Actions[LIRC_RECORD_STOP]);
+ c->writeEntry("LIRC_VOLUME_INC", m_Actions[LIRC_VOLUME_INC]);
+ c->writeEntry("LIRC_VOLUME_DEC", m_Actions[LIRC_VOLUME_DEC]);
+ c->writeEntry("LIRC_CHANNEL_NEXT", m_Actions[LIRC_CHANNEL_NEXT]);
+ c->writeEntry("LIRC_CHANNEL_PREV", m_Actions[LIRC_CHANNEL_PREV]);
+ c->writeEntry("LIRC_SEARCH_NEXT", m_Actions[LIRC_SEARCH_NEXT]);
+ c->writeEntry("LIRC_SEARCH_PREV", m_Actions[LIRC_SEARCH_PREV]);
+ c->writeEntry("LIRC_SLEEP", m_Actions[LIRC_SLEEP]);
+ c->writeEntry("LIRC_APPLICATION_QUIT", m_Actions[LIRC_APPLICATION_QUIT]);
+
+
+ c->writeEntry("ALT_LIRC_DIGIT_0", m_AlternativeActions[LIRC_DIGIT_0]);
+ c->writeEntry("ALT_LIRC_DIGIT_1", m_AlternativeActions[LIRC_DIGIT_1]);
+ c->writeEntry("ALT_LIRC_DIGIT_2", m_AlternativeActions[LIRC_DIGIT_2]);
+ c->writeEntry("ALT_LIRC_DIGIT_3", m_AlternativeActions[LIRC_DIGIT_3]);
+ c->writeEntry("ALT_LIRC_DIGIT_4", m_AlternativeActions[LIRC_DIGIT_4]);
+ c->writeEntry("ALT_LIRC_DIGIT_5", m_AlternativeActions[LIRC_DIGIT_5]);
+ c->writeEntry("ALT_LIRC_DIGIT_6", m_AlternativeActions[LIRC_DIGIT_6]);
+ c->writeEntry("ALT_LIRC_DIGIT_7", m_AlternativeActions[LIRC_DIGIT_7]);
+ c->writeEntry("ALT_LIRC_DIGIT_8", m_AlternativeActions[LIRC_DIGIT_8]);
+ c->writeEntry("ALT_LIRC_DIGIT_9", m_AlternativeActions[LIRC_DIGIT_9]);
+ c->writeEntry("ALT_LIRC_POWER_ON", m_AlternativeActions[LIRC_POWER_ON]);
+ c->writeEntry("ALT_LIRC_POWER_OFF", m_AlternativeActions[LIRC_POWER_OFF]);
+ c->writeEntry("ALT_LIRC_PAUSE", m_AlternativeActions[LIRC_PAUSE]);
+ c->writeEntry("ALT_LIRC_RECORD_START", m_AlternativeActions[LIRC_RECORD_START]);
+ c->writeEntry("ALT_LIRC_RECORD_STOP", m_AlternativeActions[LIRC_RECORD_STOP]);
+ c->writeEntry("ALT_LIRC_VOLUME_INC", m_AlternativeActions[LIRC_VOLUME_INC]);
+ c->writeEntry("ALT_LIRC_VOLUME_DEC", m_AlternativeActions[LIRC_VOLUME_DEC]);
+ c->writeEntry("ALT_LIRC_CHANNEL_NEXT", m_AlternativeActions[LIRC_CHANNEL_NEXT]);
+ c->writeEntry("ALT_LIRC_CHANNEL_PREV", m_AlternativeActions[LIRC_CHANNEL_PREV]);
+ c->writeEntry("ALT_LIRC_SEARCH_NEXT", m_AlternativeActions[LIRC_SEARCH_NEXT]);
+ c->writeEntry("ALT_LIRC_SEARCH_PREV", m_AlternativeActions[LIRC_SEARCH_PREV]);
+ c->writeEntry("ALT_LIRC_SLEEP", m_AlternativeActions[LIRC_SLEEP]);
+ c->writeEntry("ALT_LIRC_APPLICATION_QUIT", m_AlternativeActions[LIRC_APPLICATION_QUIT]);
+}
+
+void LircSupport::restoreState (TDEConfig *c)
+{
+ m_Actions[LIRC_DIGIT_0] = c->readEntry("LIRC_DIGIT_0", "0");
+ m_Actions[LIRC_DIGIT_1] = c->readEntry("LIRC_DIGIT_1", "1");
+ m_Actions[LIRC_DIGIT_2] = c->readEntry("LIRC_DIGIT_2", "2");
+ m_Actions[LIRC_DIGIT_3] = c->readEntry("LIRC_DIGIT_3", "3");
+ m_Actions[LIRC_DIGIT_4] = c->readEntry("LIRC_DIGIT_4", "4");
+ m_Actions[LIRC_DIGIT_5] = c->readEntry("LIRC_DIGIT_5", "5");
+ m_Actions[LIRC_DIGIT_6] = c->readEntry("LIRC_DIGIT_6", "6");
+ m_Actions[LIRC_DIGIT_7] = c->readEntry("LIRC_DIGIT_7", "7");
+ m_Actions[LIRC_DIGIT_8] = c->readEntry("LIRC_DIGIT_8", "8");
+ m_Actions[LIRC_DIGIT_9] = c->readEntry("LIRC_DIGIT_9", "9");
+ m_Actions[LIRC_POWER_ON] = c->readEntry("LIRC_POWER_ON", "RADIO");
+ m_Actions[LIRC_POWER_OFF] = c->readEntry("LIRC_POWER_OFF", "RADIO");
+ m_Actions[LIRC_PAUSE] = c->readEntry("LIRC_PAUSE", "FULL_SCREEN");
+ m_Actions[LIRC_RECORD_START] = c->readEntry("LIRC_RECORD_START", "");
+ m_Actions[LIRC_RECORD_STOP] = c->readEntry("LIRC_RECORD_STOP", "");
+ m_Actions[LIRC_VOLUME_INC] = c->readEntry("LIRC_VOLUME_INC", "VOL+");
+ m_Actions[LIRC_VOLUME_DEC] = c->readEntry("LIRC_VOLUME_DEC", "VOL-");
+ m_Actions[LIRC_CHANNEL_NEXT] = c->readEntry("LIRC_CHANNEL_NEXT", "CH+");
+ m_Actions[LIRC_CHANNEL_PREV] = c->readEntry("LIRC_CHANNEL_PREV", "CH-");
+ m_Actions[LIRC_SEARCH_NEXT] = c->readEntry("LIRC_SEARCH_NEXT", "SOURCE");
+ m_Actions[LIRC_SEARCH_PREV] = c->readEntry("LIRC_SEARCH_PREV", "MUTE");
+ m_Actions[LIRC_SLEEP] = c->readEntry("LIRC_SLEEP", "MINIMIZE");
+ m_Actions[LIRC_APPLICATION_QUIT] = c->readEntry("LIRC_APPLICATION_QUIT", "");
+
+
+ m_AlternativeActions[LIRC_DIGIT_0] = c->readEntry("ALT_LIRC_DIGIT_0", "");
+ m_AlternativeActions[LIRC_DIGIT_1] = c->readEntry("ALT_LIRC_DIGIT_1", "");
+ m_AlternativeActions[LIRC_DIGIT_2] = c->readEntry("ALT_LIRC_DIGIT_2", "");
+ m_AlternativeActions[LIRC_DIGIT_3] = c->readEntry("ALT_LIRC_DIGIT_3", "");
+ m_AlternativeActions[LIRC_DIGIT_4] = c->readEntry("ALT_LIRC_DIGIT_4", "");
+ m_AlternativeActions[LIRC_DIGIT_5] = c->readEntry("ALT_LIRC_DIGIT_5", "");
+ m_AlternativeActions[LIRC_DIGIT_6] = c->readEntry("ALT_LIRC_DIGIT_6", "");
+ m_AlternativeActions[LIRC_DIGIT_7] = c->readEntry("ALT_LIRC_DIGIT_7", "");
+ m_AlternativeActions[LIRC_DIGIT_8] = c->readEntry("ALT_LIRC_DIGIT_8", "");
+ m_AlternativeActions[LIRC_DIGIT_9] = c->readEntry("ALT_LIRC_DIGIT_9", "");
+ m_AlternativeActions[LIRC_POWER_ON] = c->readEntry("ALT_LIRC_POWER_ON", "");
+ m_AlternativeActions[LIRC_POWER_OFF] = c->readEntry("ALT_LIRC_POWER_OFF", "TV");
+ m_AlternativeActions[LIRC_PAUSE] = c->readEntry("ALT_LIRC_PAUSE", "");
+ m_AlternativeActions[LIRC_RECORD_START] = c->readEntry("ALT_LIRC_RECORD_START", "");
+ m_AlternativeActions[LIRC_RECORD_STOP] = c->readEntry("ALT_LIRC_RECORD_STOP", "");
+ m_AlternativeActions[LIRC_VOLUME_INC] = c->readEntry("ALT_LIRC_VOLUME_INC", "");
+ m_AlternativeActions[LIRC_VOLUME_DEC] = c->readEntry("ALT_LIRC_VOLUME_DEC", "");
+ m_AlternativeActions[LIRC_CHANNEL_NEXT] = c->readEntry("ALT_LIRC_CHANNEL_NEXT", "");
+ m_AlternativeActions[LIRC_CHANNEL_PREV] = c->readEntry("ALT_LIRC_CHANNEL_PREV", "");
+ m_AlternativeActions[LIRC_SEARCH_NEXT] = c->readEntry("ALT_LIRC_SEARCH_NEXT", "");
+ m_AlternativeActions[LIRC_SEARCH_PREV] = c->readEntry("ALT_LIRC_SEARCH_PREV", "");
+ m_AlternativeActions[LIRC_SLEEP] = c->readEntry("ALT_LIRC_SLEEP", "");
+ m_AlternativeActions[LIRC_APPLICATION_QUIT] = c->readEntry("ALT_LIRC_APPLICATION_QUIT", "");
+
+ emit sigUpdateConfig();
+}
+
+
+ConfigPageInfo LircSupport::createConfigurationPage()
+{
+ LIRCConfiguration *conf = new LIRCConfiguration(NULL, this);
+ TQObject::connect(this, TQT_SIGNAL(sigUpdateConfig()), conf, TQT_SLOT(slotUpdateConfig()));
+ TQObject::connect(this, TQT_SIGNAL(sigRawLIRCSignal(const TQString &, int, bool &)),
+ conf, TQT_SLOT (slotRawLIRCSignal(const TQString &, int, bool &)));
+ return ConfigPageInfo (conf,
+ i18n("LIRC Support"),
+ i18n("LIRC Plugin"),
+ "connect_creating");
+}
+
+
+AboutPageInfo LircSupport::createAboutPage()
+{
+/* TDEAboutData aboutData("tderadio",
+ NULL,
+ NULL,
+ I18N_NOOP("Linux Infrared Remote Control Support for TDERadio"),
+ TDEAboutData::License_GPL,
+ "(c) 2002-2005 Martin Witte",
+ 0,
+ "http://sourceforge.net/projects/tderadio",
+ 0);
+ aboutData.addAuthor("Martin Witte", "", "witte@kawo1.rwth-aachen.de");
+
+ return AboutPageInfo(
+ new TDERadioAboutWidget(aboutData, TDERadioAboutWidget::AbtTabbed),
+ i18n("LIRC Support"),
+ i18n("LIRC Plugin"),
+ "connect_creating"
+ );*/
+ return AboutPageInfo();
+}
+
+
+bool LircSupport::checkActions(const TQString &lirc_string, int repeat_counter, const TQMap<LIRC_Actions, TQString> &map)
+{
+ SoundStreamID streamID = queryCurrentSoundStreamID();
+
+ bool retval = false;
+ bool q = false;
+ SoundFormat sf;
+ ISeekRadio *seeker = NULL;
+
+ TQMapConstIterator<LIRC_Actions, TQString> it = map.begin();
+ TQMapConstIterator<LIRC_Actions, TQString> end = map.end();
+ for (; !retval && it != end; ++it) {
+ if ((*it).length() && lirc_string == *it) {
+ LIRC_Actions action = it.key();
+ int digit = -1;
+ switch (action) {
+ case LIRC_DIGIT_0 :
+ if (repeat_counter == 0) {
+ digit = 0;
+ retval = true;
+ }
+ break;
+ case LIRC_DIGIT_1 :
+ if (repeat_counter == 0) {
+ digit = 1;
+ retval = true;
+ }
+ break;
+ case LIRC_DIGIT_2 :
+ if (repeat_counter == 0) {
+ digit = 2;
+ retval = true;
+ }
+ break;
+ case LIRC_DIGIT_3 :
+ if (repeat_counter == 0) {
+ digit = 3;
+ retval = true;
+ }
+ break;
+ case LIRC_DIGIT_4 :
+ if (repeat_counter == 0) {
+ digit = 4;
+ retval = true;
+ }
+ break;
+ case LIRC_DIGIT_5 :
+ if (repeat_counter == 0) {
+ digit = 5;
+ retval = true;
+ }
+ break;
+ case LIRC_DIGIT_6 :
+ if (repeat_counter == 0) {
+ digit = 6;
+ retval = true;
+ }
+ break;
+ case LIRC_DIGIT_7 :
+ if (repeat_counter == 0) {
+ digit = 7;
+ retval = true;
+ }
+ break;
+ case LIRC_DIGIT_8 :
+ if (repeat_counter == 0) {
+ digit = 8;
+ retval = true;
+ }
+ break;
+ case LIRC_DIGIT_9 :
+ if (repeat_counter == 0) {
+ digit = 9;
+ retval = true;
+ }
+ break;
+ case LIRC_POWER_ON :
+ if (repeat_counter == 0 && !queryIsPowerOn()) {
+ retval = true;
+ sendPowerOn();
+ }
+ break;
+ case LIRC_POWER_OFF :
+ if (repeat_counter == 0 && queryIsPowerOn()) {
+ retval = true;
+ sendPowerOff();
+ }
+ break;
+ case LIRC_PAUSE :
+ if (repeat_counter == 0 && queryIsPowerOn()) {
+ retval = true;
+ sendPausePlayback(streamID);
+ }
+ break;
+ case LIRC_RECORD_START :
+ queryIsRecordingRunning(streamID, q = false, sf);
+ if (repeat_counter == 0 && !q) {
+ retval = true;
+ sendStartRecording(streamID);
+ }
+ break;
+ case LIRC_RECORD_STOP :
+ queryIsRecordingRunning(streamID, q = false, sf);
+ if (repeat_counter == 0 && q) {
+ retval = true;
+ sendStopRecording(streamID);
+ }
+ break;
+ case LIRC_VOLUME_INC :
+ if (queryIsPowerOn()) {
+ retval = true;
+ float oldVolume = 0;
+ queryPlaybackVolume(streamID, oldVolume);
+ sendPlaybackVolume (streamID, oldVolume + 1.0/32.0);
+ }
+ break;
+ case LIRC_VOLUME_DEC :
+ if (queryIsPowerOn()) {
+ retval = true;
+ float oldVolume = 0;
+ queryPlaybackVolume(streamID, oldVolume);
+ sendPlaybackVolume (streamID, oldVolume - 1.0/32.0);
+ }
+ break;
+ case LIRC_CHANNEL_NEXT :
+ if (repeat_counter == 0 && queryIsPowerOn()) {
+ retval = true;
+ int k = queryCurrentStationIdx() + 1;
+ if (k >= queryStations().count())
+ k = 0;
+ sendActivateStation(k);
+ }
+ break;
+ case LIRC_CHANNEL_PREV :
+ if (repeat_counter == 0 && queryIsPowerOn()) {
+ retval = true;
+ int k = queryCurrentStationIdx() - 1;
+ if (k < 0)
+ k = queryStations().count() - 1;
+ sendActivateStation(k);
+ }
+ break;
+ case LIRC_SEARCH_NEXT :
+ if (repeat_counter == 0 && queryIsPowerOn()) {
+ retval = true;
+ seeker = dynamic_cast<ISeekRadio*> (queryActiveDevice());
+ seeker->startSeekUp();
+ }
+ break;
+ case LIRC_SEARCH_PREV :
+ if (repeat_counter == 0 && queryIsPowerOn()) {
+ retval = true;
+ seeker = dynamic_cast<ISeekRadio*> (queryActiveDevice());
+ seeker->startSeekDown();
+ }
+ break;
+ case LIRC_SLEEP :
+ if (repeat_counter == 0 && queryIsPowerOn()) {
+ retval = true;
+ sendStartCountdown();
+ }
+ break;
+ case LIRC_APPLICATION_QUIT :
+ retval = true;
+ kapp->quit();
+ break;
+ default:
+ break;
+ }
+
+ if (digit >= 0) {
+ if (m_addIndex || digit == 0) {
+ activateStation(m_addIndex * 10 + digit);
+ m_kbdTimer->stop();
+ m_addIndex = 0;
+ } else {
+ m_addIndex = digit;
+ m_kbdTimer->start(500, true);
+ }
+ }
+ }
+ }
+ return retval;
+}
+
+
+void LircSupport::setActions(const TQMap<LIRC_Actions, TQString> &actions, const TQMap<LIRC_Actions, TQString> &alt_actions)
+{
+ m_Actions = actions;
+ m_AlternativeActions = alt_actions;
+}
+
+
+#include "lircsupport.moc"
diff --git a/plugins/lirc/lircsupport.h b/plugins/lirc/lircsupport.h
new file mode 100644
index 0000000..bd1ad8a
--- /dev/null
+++ b/plugins/lirc/lircsupport.h
@@ -0,0 +1,160 @@
+/***************************************************************************
+ lircsupport.h - description
+ -------------------
+ begin : Mon Feb 4 2002
+ copyright : (C) 2002 by Martin Witte / Frank Schwanz
+ email : witte@kawo1.rwth-aachen.de / schwanz@fh-brandenburg.de
+ ***************************************************************************/
+
+/***************************************************************************
+ * *
+ * This program is free software; you can redistribute it and/or modify *
+ * it under the terms of the GNU General Public License as published by *
+ * the Free Software Foundation; either version 2 of the License, or *
+ * (at your option) any later version. *
+ * *
+ ***************************************************************************/
+
+#ifndef LIRCSUPPORT_H
+#define LIRCSUPPORT_H
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <tqobject.h>
+#include "../../src/include/timecontrol_interfaces.h"
+#include "../../src/include/radio_interfaces.h"
+#include "../../src/include/radiodevicepool_interfaces.h"
+#include "../../src/include/soundstreamclient_interfaces.h"
+#include "../../src/include/plugins.h"
+
+
+enum LIRC_Actions {
+ LIRC_DIGIT_0,
+ LIRC_DIGIT_1,
+ LIRC_DIGIT_2,
+ LIRC_DIGIT_3,
+ LIRC_DIGIT_4,
+ LIRC_DIGIT_5,
+ LIRC_DIGIT_6,
+ LIRC_DIGIT_7,
+ LIRC_DIGIT_8,
+ LIRC_DIGIT_9,
+ LIRC_POWER_ON,
+ LIRC_POWER_OFF,
+ LIRC_PAUSE,
+ LIRC_RECORD_START,
+ LIRC_RECORD_STOP,
+ LIRC_VOLUME_INC,
+ LIRC_VOLUME_DEC,
+ LIRC_CHANNEL_NEXT,
+ LIRC_CHANNEL_PREV,
+ LIRC_SEARCH_NEXT,
+ LIRC_SEARCH_PREV,
+ LIRC_SLEEP,
+ LIRC_APPLICATION_QUIT
+};
+
+
+struct lirc_config;
+class TQSocketNotifier;
+class TQTimer;
+
+class LircSupport : public TQObject,
+ public PluginBase,
+ public IRadioClient,
+ public ITimeControlClient,
+ public ISoundStreamClient,
+ public IRadioDevicePoolClient
+{
+Q_OBJECT
+
+public:
+ LircSupport(const TQString &name);
+ ~LircSupport();
+
+ virtual bool connectI (Interface *);
+ virtual bool disconnectI (Interface *);
+
+ virtual TQString pluginClassName() const { return "LircSupport"; }
+
+ virtual const TQString &name() const { return PluginBase::name(); }
+ virtual TQString &name() { return PluginBase::name(); }
+
+
+ virtual void setActions(const TQMap<LIRC_Actions, TQString> &actions, const TQMap<LIRC_Actions, TQString> &alt_actions);
+ virtual const TQMap<LIRC_Actions, TQString> &getActions() const { return m_Actions; }
+ virtual const TQMap<LIRC_Actions, TQString> &getAlternativeActions() const { return m_AlternativeActions; }
+
+ // PluginBase
+
+public:
+ virtual void saveState (TDEConfig *) const;
+ virtual void restoreState (TDEConfig *);
+
+ virtual ConfigPageInfo createConfigurationPage();
+ virtual AboutPageInfo createAboutPage();
+
+ // IRadioClient methods
+
+RECEIVERS:
+ bool noticePowerChanged(bool /*on*/) { return false; }
+ bool noticeStationChanged (const RadioStation &, int /*idx*/) { return false; }
+ bool noticeStationsChanged(const StationList &/*sl*/) { return false; }
+ bool noticePresetFileChanged(const TQString &/*f*/) { return false; }
+
+ bool noticeCurrentSoundStreamIDChanged(SoundStreamID /*id*/) { return false; }
+
+ // ITimeControlClient
+
+RECEIVERS:
+ bool noticeAlarmsChanged(const AlarmVector &) { return false; }
+ bool noticeAlarm(const Alarm &) { return false; }
+ bool noticeNextAlarmChanged(const Alarm *) { return false; }
+ bool noticeCountdownStarted(const TQDateTime &/*end*/) { return false; }
+ bool noticeCountdownStopped() { return false; }
+ bool noticeCountdownZero() { return false; }
+ bool noticeCountdownSecondsChanged(int /*n*/) { return false; }
+
+ // IRadioDevicePoolClient
+
+RECEIVERS:
+ bool noticeActiveDeviceChanged(IRadioDevice *) { return false; }
+ bool noticeDevicesChanged(const TQPtrList<IRadioDevice> &) { return false; }
+ bool noticeDeviceDescriptionChanged(const TQString &) { return false; }
+
+
+protected:
+ void activateStation(int i);
+ bool checkActions(const TQString &string, int repeat_counter, const TQMap<LIRC_Actions, TQString> &map);
+
+protected slots:
+ void slotLIRC(int socket);
+ void slotKbdTimedOut();
+
+signals:
+
+ void sigUpdateConfig();
+
+ void sigRawLIRCSignal(const TQString &what, int repeat_counter, bool &consumed);
+
+protected:
+
+#ifdef HAVE_LIRC
+ TQSocketNotifier *m_lirc_notify;
+ int m_fd_lirc;
+ struct lirc_config *m_lircConfig;
+#endif
+
+ TQTimer *m_kbdTimer;
+ int m_addIndex;
+ bool m_TakeRawLIRC;
+
+ TQMap<LIRC_Actions, TQString> m_Actions;
+ TQMap<LIRC_Actions, TQString> m_AlternativeActions;
+};
+
+
+
+#endif
diff --git a/plugins/lirc/listviewitem_lirc.cpp b/plugins/lirc/listviewitem_lirc.cpp
new file mode 100644
index 0000000..20976c5
--- /dev/null
+++ b/plugins/lirc/listviewitem_lirc.cpp
@@ -0,0 +1,51 @@
+/***************************************************************************
+ listviewitem_lirc.cpp - description
+ -------------------
+ begin : Sun Aug 14 2005
+ copyright : (C) 2005 by Martin Witte
+ email : witte@kawo1.rwth-aachen.de
+ ***************************************************************************/
+
+/***************************************************************************
+ * *
+ * This program is free software; you can redistribute it and/or modify *
+ * it under the terms of the GNU General Public License as published by *
+ * the Free Software Foundation; either version 2 of the License, or *
+ * (at your option) any later version. *
+ * *
+ ***************************************************************************/
+
+#include "listviewitem_lirc.h"
+
+ListViewItemLirc::ListViewItemLirc(TQListView *parent, TQListViewItem *after)
+ : TDEListViewItem(parent, after),
+ m_renamingInProcess(-1)
+{
+}
+
+ListViewItemLirc::~ListViewItemLirc()
+{
+}
+
+void ListViewItemLirc::startRename(int col)
+{
+ TDEListViewItem::startRename(col);
+ m_renamingInProcess = col;
+ emit sigRenamingStarted(this, col);
+}
+
+void ListViewItemLirc::okRename(int col)
+{
+ TDEListViewItem::okRename(col);
+ m_renamingInProcess = -1;
+ emit sigRenamingStopped(this, col);
+}
+
+void ListViewItemLirc::cancelRename(int col)
+{
+ TDEListViewItem::cancelRename(col);
+ m_renamingInProcess = -1;
+ emit sigRenamingStopped(this, col);
+}
+
+#include "listviewitem_lirc.moc"
diff --git a/plugins/lirc/listviewitem_lirc.h b/plugins/lirc/listviewitem_lirc.h
new file mode 100644
index 0000000..d0d7444
--- /dev/null
+++ b/plugins/lirc/listviewitem_lirc.h
@@ -0,0 +1,52 @@
+/***************************************************************************
+ listviewitem_lirc.cpp - description
+ -------------------
+ begin : Sun Aug 14 2005
+ copyright : (C) 2005 by Martin Witte
+ email : witte@kawo1.rwth-aachen.de
+ ***************************************************************************/
+
+/***************************************************************************
+ * *
+ * This program is free software; you can redistribute it and/or modify *
+ * it under the terms of the GNU General Public License as published by *
+ * the Free Software Foundation; either version 2 of the License, or *
+ * (at your option) any later version. *
+ * *
+ ***************************************************************************/
+
+#ifndef LISTVIEWITEM_LIRC_H
+#define LISTVIEWITEM_LIRC_H
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <tdelistview.h>
+
+class ListViewItemLirc : public TQObject, public TDEListViewItem
+{
+Q_OBJECT
+
+public:
+ ListViewItemLirc(TQListView *parent, TQListViewItem *after);
+ ~ListViewItemLirc();
+
+ bool isRenamingInProcess() const { return m_renamingInProcess >= 0; }
+ int getRenamingColumn() const { return m_renamingInProcess; }
+
+ virtual void startRename(int col);
+ virtual void okRename(int col);
+ virtual void cancelRename(int col);
+
+signals:
+
+ void sigRenamingStarted(ListViewItemLirc *sender, int column);
+ void sigRenamingStopped(ListViewItemLirc *sender, int column);
+
+protected:
+
+ int m_renamingInProcess;
+};
+
+#endif
diff --git a/plugins/lirc/po/Makefile.am b/plugins/lirc/po/Makefile.am
new file mode 100644
index 0000000..eada139
--- /dev/null
+++ b/plugins/lirc/po/Makefile.am
@@ -0,0 +1,2 @@
+PACKAGE = tderadio-lirc
+POFILES = AUTO
diff --git a/plugins/lirc/po/de.po b/plugins/lirc/po/de.po
new file mode 100644
index 0000000..e07a6d2
--- /dev/null
+++ b/plugins/lirc/po/de.po
@@ -0,0 +1,208 @@
+# translation of de.po to
+# translation of tderadio-lirc.po to
+# This file is put in the public domain.
+#
+# Ernst Martin Witte <emw@nocabal.de>, 2006.
+msgid ""
+msgstr ""
+"Project-Id-Version: de\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2020-05-11 04:30+0200\n"
+"PO-Revision-Date: 2019-12-23 23:40+0000\n"
+"Last-Translator: Chris <xchrisx@uber.space>\n"
+"Language-Team: German <https://mirror.git.trinitydesktop.org/weblate/"
+"projects/applications/tderadio-lirc/de/>\n"
+"Language: de\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"Plural-Forms: nplurals=2; plural=n != 1;\n"
+"X-Generator: Weblate 3.9.1\n"
+
+#. Instead of a literal translation, add your name to the end of the list (separated by a comma).
+msgid ""
+"_: NAME OF TRANSLATORS\n"
+"Your names"
+msgstr "Ernst Martin Witte, Chris (TDE)"
+
+#. Instead of a literal translation, add your email to the end of the list (separated by a comma).
+msgid ""
+"_: EMAIL OF TRANSLATORS\n"
+"Your emails"
+msgstr "emw@nocabal.de, (Keine Email)"
+
+#: lirc-configuration.cpp:34
+msgid "digit 0"
+msgstr "Ziffer 0"
+
+#: lirc-configuration.cpp:35
+msgid "digit 1"
+msgstr "Ziffer 1"
+
+#: lirc-configuration.cpp:36
+msgid "digit 2"
+msgstr "Ziffer 2"
+
+#: lirc-configuration.cpp:37
+msgid "digit 3"
+msgstr "Ziffer 3"
+
+#: lirc-configuration.cpp:38
+msgid "digit 4"
+msgstr "Ziffer 4"
+
+#: lirc-configuration.cpp:39
+msgid "digit 5"
+msgstr "Ziffer 5"
+
+#: lirc-configuration.cpp:40
+msgid "digit 6"
+msgstr "Ziffer 6"
+
+#: lirc-configuration.cpp:41
+msgid "digit 7"
+msgstr "Ziffer 7"
+
+#: lirc-configuration.cpp:42
+msgid "digit 8"
+msgstr "Ziffer 8"
+
+#: lirc-configuration.cpp:43
+msgid "digit 9"
+msgstr "Ziffer 9"
+
+#: lirc-configuration.cpp:44
+msgid "Power On"
+msgstr "Einschalten"
+
+#: lirc-configuration.cpp:45
+msgid "Power Off"
+msgstr "Ausschalten"
+
+#: lirc-configuration.cpp:46
+msgid "Pause"
+msgstr "Pause"
+
+#: lirc-configuration.cpp:47
+msgid "Start Recording"
+msgstr "Aufnahme starten"
+
+#: lirc-configuration.cpp:48
+msgid "Stop Recording"
+msgstr "Aufnahme beenden"
+
+#: lirc-configuration.cpp:49
+msgid "Increase Volume"
+msgstr "Lautstärke erhöhen"
+
+#: lirc-configuration.cpp:50
+msgid "Decrease Volume"
+msgstr "Lautstärke senken"
+
+#: lirc-configuration.cpp:51
+msgid "Next Channel"
+msgstr "Nächster Sender"
+
+#: lirc-configuration.cpp:52
+msgid "Previous Channel"
+msgstr "Vorheriger Sender"
+
+#: lirc-configuration.cpp:53
+msgid "Search Next Channel"
+msgstr "Suche nächsten Sender"
+
+#: lirc-configuration.cpp:54
+msgid "Search Previous Channel"
+msgstr "Suche vorherigen Sender"
+
+#: lirc-configuration.cpp:55
+msgid "Enable Sleep Countdown"
+msgstr "Schlummer-Countdown aktivieren"
+
+#: lirc-configuration.cpp:56
+msgid "Quit TDERadio"
+msgstr "TDERadio Beenden"
+
+#: lirc-configuration.cpp:176
+msgid ""
+"Enter the key string of your remote or just press the button on your remote "
+"control"
+msgstr ""
+"Geben Sie die Zeichenkette Ihrer Fernsteuerung ein oder drücken Sie die "
+"Taste auf Ihrer Fernsteuerung"
+
+#: lirc-configuration.cpp:182
+msgid "Double Click on the entries to change the assignments"
+msgstr "Doppelklicken Sie auf die Einträge um die Zuordnung zu ändern"
+
+#: lircsupport.cpp:47
+msgid "Linux Infrared Control (LIRC) Support"
+msgstr "Unterstützung für die Fernsteuerung (LIRC)"
+
+#: lircsupport.cpp:53 lircsupport.cpp:332
+msgid "LIRC Plugin"
+msgstr "Plugin für die Fernsteuerung (LIRC)"
+
+#: lircsupport.cpp:58 lircsupport.cpp:59
+msgid "initializing tderadio lirc plugin"
+msgstr "initialisiere das Plugin für die Fernsteuerung (LIRC)"
+
+#: lircsupport.cpp:67
+msgid ""
+"%1 does not exist. File was created with TDERadio's default .lircrc proposal"
+msgstr ""
+"Die Datei %1 existiert nicht. Die Datei wurde mit den Voreinstellungen für "
+"TDERadio erzeugt."
+
+#: lircsupport.cpp:96
+msgid "There is no entry for tderadio in any of your .lircrc files."
+msgstr "Es gibt keinen Eintrag für TDERadio in jeglichen .lirc-Dateien."
+
+#: lircsupport.cpp:97
+msgid "Please setup your .lircrc files correctly."
+msgstr "Bitte richten Sie Ihre .lirc-Dateien richtig ein."
+
+#: lircsupport.cpp:108 lircsupport.cpp:109
+msgid "Initializing tderadio lirc plugin failed"
+msgstr "Die Initialisierung des TDERadio LIRC Plugins schlug fehl"
+
+#: lircsupport.cpp:111 lircsupport.cpp:112
+msgid "Initializing tderadio lirc plugin successful"
+msgstr "Die Initialisierung des LIRC Plugins war erfolgreich"
+
+#: lircsupport.cpp:169
+msgid ""
+"Reading from LIRC socket failed. Disabling LIRC Functions till next start of "
+"tderadio"
+msgstr ""
+"Das Lesen vom LIRC-Socket ist fehlgeschlagen. Die LIRC-Funktion wird bis zum "
+"nächsten Start von TDERadio temporär abgeschaltet."
+
+#: lircsupport.cpp:331
+msgid "LIRC Support"
+msgstr "Fernsteuerung"
+
+#: lirc-configuration-ui.ui:17
+#, no-c-format
+msgid "LIRCConfigurationUI"
+msgstr "LIRCConfigurationUI"
+
+#: lirc-configuration-ui.ui:26
+#, no-c-format
+msgid "Action"
+msgstr "Aktion"
+
+#: lirc-configuration-ui.ui:37
+#, no-c-format
+msgid "LIRC String"
+msgstr "LIRC-Zeichenkette"
+
+#: lirc-configuration-ui.ui:48
+#, no-c-format
+msgid "Alternative LIRC String"
+msgstr "Alternative LIRC-Zeichenkette"
+
+#: lirc-configuration-ui.ui:98
+#, no-c-format
+msgid "textLabel1"
+msgstr "textLabel1"
diff --git a/plugins/lirc/po/pt.po b/plugins/lirc/po/pt.po
new file mode 100644
index 0000000..1a43cee
--- /dev/null
+++ b/plugins/lirc/po/pt.po
@@ -0,0 +1,195 @@
+# SOME DESCRIPTIVE TITLE.
+# Hugo Carvalho <hugokarvalho@hotmail.com>, 2020.
+msgid ""
+msgstr ""
+"Project-Id-Version: PACKAGE VERSION\n"
+"POT-Creation-Date: 2020-05-11 04:30+0200\n"
+"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
+"Last-Translator: Automatically generated\n"
+"Language-Team: none\n"
+"Language: pt\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+
+#. Instead of a literal translation, add your name to the end of the list (separated by a comma).
+msgid ""
+"_: NAME OF TRANSLATORS\n"
+"Your names"
+msgstr ""
+
+#. Instead of a literal translation, add your email to the end of the list (separated by a comma).
+msgid ""
+"_: EMAIL OF TRANSLATORS\n"
+"Your emails"
+msgstr ""
+
+#: lirc-configuration.cpp:34
+msgid "digit 0"
+msgstr ""
+
+#: lirc-configuration.cpp:35
+msgid "digit 1"
+msgstr ""
+
+#: lirc-configuration.cpp:36
+msgid "digit 2"
+msgstr ""
+
+#: lirc-configuration.cpp:37
+msgid "digit 3"
+msgstr ""
+
+#: lirc-configuration.cpp:38
+msgid "digit 4"
+msgstr ""
+
+#: lirc-configuration.cpp:39
+msgid "digit 5"
+msgstr ""
+
+#: lirc-configuration.cpp:40
+msgid "digit 6"
+msgstr ""
+
+#: lirc-configuration.cpp:41
+msgid "digit 7"
+msgstr ""
+
+#: lirc-configuration.cpp:42
+msgid "digit 8"
+msgstr ""
+
+#: lirc-configuration.cpp:43
+msgid "digit 9"
+msgstr ""
+
+#: lirc-configuration.cpp:44
+msgid "Power On"
+msgstr ""
+
+#: lirc-configuration.cpp:45
+msgid "Power Off"
+msgstr ""
+
+#: lirc-configuration.cpp:46
+msgid "Pause"
+msgstr ""
+
+#: lirc-configuration.cpp:47
+msgid "Start Recording"
+msgstr ""
+
+#: lirc-configuration.cpp:48
+msgid "Stop Recording"
+msgstr ""
+
+#: lirc-configuration.cpp:49
+msgid "Increase Volume"
+msgstr ""
+
+#: lirc-configuration.cpp:50
+msgid "Decrease Volume"
+msgstr ""
+
+#: lirc-configuration.cpp:51
+msgid "Next Channel"
+msgstr ""
+
+#: lirc-configuration.cpp:52
+msgid "Previous Channel"
+msgstr ""
+
+#: lirc-configuration.cpp:53
+msgid "Search Next Channel"
+msgstr ""
+
+#: lirc-configuration.cpp:54
+msgid "Search Previous Channel"
+msgstr ""
+
+#: lirc-configuration.cpp:55
+msgid "Enable Sleep Countdown"
+msgstr ""
+
+#: lirc-configuration.cpp:56
+msgid "Quit TDERadio"
+msgstr ""
+
+#: lirc-configuration.cpp:176
+msgid ""
+"Enter the key string of your remote or just press the button on your remote "
+"control"
+msgstr ""
+
+#: lirc-configuration.cpp:182
+msgid "Double Click on the entries to change the assignments"
+msgstr ""
+
+#: lircsupport.cpp:47
+msgid "Linux Infrared Control (LIRC) Support"
+msgstr ""
+
+#: lircsupport.cpp:53 lircsupport.cpp:332
+msgid "LIRC Plugin"
+msgstr ""
+
+#: lircsupport.cpp:58 lircsupport.cpp:59
+msgid "initializing tderadio lirc plugin"
+msgstr ""
+
+#: lircsupport.cpp:67
+msgid ""
+"%1 does not exist. File was created with TDERadio's default .lircrc proposal"
+msgstr ""
+
+#: lircsupport.cpp:96
+msgid "There is no entry for tderadio in any of your .lircrc files."
+msgstr ""
+
+#: lircsupport.cpp:97
+msgid "Please setup your .lircrc files correctly."
+msgstr ""
+
+#: lircsupport.cpp:108 lircsupport.cpp:109
+msgid "Initializing tderadio lirc plugin failed"
+msgstr ""
+
+#: lircsupport.cpp:111 lircsupport.cpp:112
+msgid "Initializing tderadio lirc plugin successful"
+msgstr ""
+
+#: lircsupport.cpp:169
+msgid ""
+"Reading from LIRC socket failed. Disabling LIRC Functions till next start of "
+"tderadio"
+msgstr ""
+
+#: lircsupport.cpp:331
+msgid "LIRC Support"
+msgstr ""
+
+#: lirc-configuration-ui.ui:17
+#, no-c-format
+msgid "LIRCConfigurationUI"
+msgstr ""
+
+#: lirc-configuration-ui.ui:26
+#, no-c-format
+msgid "Action"
+msgstr ""
+
+#: lirc-configuration-ui.ui:37
+#, no-c-format
+msgid "LIRC String"
+msgstr ""
+
+#: lirc-configuration-ui.ui:48
+#, no-c-format
+msgid "Alternative LIRC String"
+msgstr ""
+
+#: lirc-configuration-ui.ui:98
+#, no-c-format
+msgid "textLabel1"
+msgstr ""
diff --git a/plugins/lirc/po/ru.po b/plugins/lirc/po/ru.po
new file mode 100644
index 0000000..0793f4e
--- /dev/null
+++ b/plugins/lirc/po/ru.po
@@ -0,0 +1,202 @@
+# translation of ru.po to
+# translation of tderadio-lirc.po to
+# This file is put in the public domain.
+# Алексей Кузнецов <Alexey.Kouznetsov@GMail.com>, 2006.
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: ru\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2020-05-11 04:30+0200\n"
+"PO-Revision-Date: 2006-11-08 12:54+0300\n"
+"Last-Translator: Алексей Кузнецов <Alexey.Kouznetsov@GMail.com>\n"
+"Language-Team: <ru@li.org>\n"
+"Language: \n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"X-Generator: KBabel 1.10\n"
+
+#. Instead of a literal translation, add your name to the end of the list (separated by a comma).
+msgid ""
+"_: NAME OF TRANSLATORS\n"
+"Your names"
+msgstr "Алексей Кузнецов"
+
+#. Instead of a literal translation, add your email to the end of the list (separated by a comma).
+msgid ""
+"_: EMAIL OF TRANSLATORS\n"
+"Your emails"
+msgstr "Alexey.Kouznetsov@GMail.com"
+
+#: lirc-configuration.cpp:34
+msgid "digit 0"
+msgstr "ноль"
+
+#: lirc-configuration.cpp:35
+msgid "digit 1"
+msgstr "один"
+
+#: lirc-configuration.cpp:36
+msgid "digit 2"
+msgstr "два"
+
+#: lirc-configuration.cpp:37
+msgid "digit 3"
+msgstr "три"
+
+#: lirc-configuration.cpp:38
+msgid "digit 4"
+msgstr "четыре"
+
+#: lirc-configuration.cpp:39
+msgid "digit 5"
+msgstr "пять"
+
+#: lirc-configuration.cpp:40
+msgid "digit 6"
+msgstr "шесть"
+
+#: lirc-configuration.cpp:41
+msgid "digit 7"
+msgstr "семь"
+
+#: lirc-configuration.cpp:42
+msgid "digit 8"
+msgstr "восемь"
+
+#: lirc-configuration.cpp:43
+msgid "digit 9"
+msgstr "девять"
+
+#: lirc-configuration.cpp:44
+msgid "Power On"
+msgstr "Включить"
+
+#: lirc-configuration.cpp:45
+msgid "Power Off"
+msgstr "Выключить"
+
+#: lirc-configuration.cpp:46
+msgid "Pause"
+msgstr "Приостановить"
+
+#: lirc-configuration.cpp:47
+msgid "Start Recording"
+msgstr "Начать запись"
+
+#: lirc-configuration.cpp:48
+msgid "Stop Recording"
+msgstr "Остановить запись"
+
+#: lirc-configuration.cpp:49
+msgid "Increase Volume"
+msgstr "Увеличить громкость"
+
+#: lirc-configuration.cpp:50
+msgid "Decrease Volume"
+msgstr "Уменьшить громкость"
+
+#: lirc-configuration.cpp:51
+msgid "Next Channel"
+msgstr "Следующий канал"
+
+#: lirc-configuration.cpp:52
+msgid "Previous Channel"
+msgstr "Предыдущий канал"
+
+#: lirc-configuration.cpp:53
+msgid "Search Next Channel"
+msgstr "Поиск следующего канала"
+
+#: lirc-configuration.cpp:54
+msgid "Search Previous Channel"
+msgstr "Поиск предыдущего канала"
+
+#: lirc-configuration.cpp:55
+msgid "Enable Sleep Countdown"
+msgstr "Включить таймер отключения"
+
+#: lirc-configuration.cpp:56
+msgid "Quit TDERadio"
+msgstr "Закрыть TDERadio"
+
+#: lirc-configuration.cpp:176
+msgid ""
+"Enter the key string of your remote or just press the button on your remote "
+"control"
+msgstr "Введите ключевую строку вашего ПДУ либо просто нажмите кнопку на нём"
+
+#: lirc-configuration.cpp:182
+msgid "Double Click on the entries to change the assignments"
+msgstr "Для изменения привязки дважды щёлкните по ней мышью"
+
+#: lircsupport.cpp:47
+msgid "Linux Infrared Control (LIRC) Support"
+msgstr "Поддержка ПДУ в Linux (LIRC)"
+
+#: lircsupport.cpp:53 lircsupport.cpp:332
+msgid "LIRC Plugin"
+msgstr "Модуль ДУ (LIRC)"
+
+#: lircsupport.cpp:58 lircsupport.cpp:59
+msgid "initializing tderadio lirc plugin"
+msgstr "Инициализация модуля LIRC"
+
+#: lircsupport.cpp:67
+msgid ""
+"%1 does not exist. File was created with TDERadio's default .lircrc proposal"
+msgstr "%1 не существует. Был создан файл .lircrc для TDERadio по умолчанию"
+
+#: lircsupport.cpp:96
+msgid "There is no entry for tderadio in any of your .lircrc files."
+msgstr "Ни в одном из ваших файлов .lircrc нет упоминания о TDERadio."
+
+#: lircsupport.cpp:97
+msgid "Please setup your .lircrc files correctly."
+msgstr "Настройте файлы .lircrc"
+
+#: lircsupport.cpp:108 lircsupport.cpp:109
+msgid "Initializing tderadio lirc plugin failed"
+msgstr "Инициализация модуля LIRC не удалась"
+
+#: lircsupport.cpp:111 lircsupport.cpp:112
+msgid "Initializing tderadio lirc plugin successful"
+msgstr "Модуль LIRC инициализирован"
+
+#: lircsupport.cpp:169
+msgid ""
+"Reading from LIRC socket failed. Disabling LIRC Functions till next start of "
+"tderadio"
+msgstr ""
+"Чтение из сокета LIRC не удалось. Отключаю функции LIRC до следующего "
+"запуска TDERadio."
+
+#: lircsupport.cpp:331
+msgid "LIRC Support"
+msgstr "Поддержка LIRC"
+
+#: lirc-configuration-ui.ui:17
+#, no-c-format
+msgid "LIRCConfigurationUI"
+msgstr "LIRCConfigurationUI"
+
+#: lirc-configuration-ui.ui:26
+#, no-c-format
+msgid "Action"
+msgstr "Действие"
+
+#: lirc-configuration-ui.ui:37
+#, no-c-format
+msgid "LIRC String"
+msgstr "Строка LIRC"
+
+#: lirc-configuration-ui.ui:48
+#, no-c-format
+msgid "Alternative LIRC String"
+msgstr "Альтернативная строка LIRC"
+
+#: lirc-configuration-ui.ui:98
+#, no-c-format
+msgid "textLabel1"
+msgstr "textLabel1"
diff --git a/plugins/lirc/po/tderadio-lirc.pot b/plugins/lirc/po/tderadio-lirc.pot
new file mode 100644
index 0000000..9dfef8f
--- /dev/null
+++ b/plugins/lirc/po/tderadio-lirc.pot
@@ -0,0 +1,198 @@
+# SOME DESCRIPTIVE TITLE.
+# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
+#
+#, fuzzy
+msgid ""
+msgstr ""
+"Project-Id-Version: PACKAGE VERSION\n"
+"POT-Creation-Date: 2020-05-11 04:30+0200\n"
+"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
+"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
+"Language-Team: LANGUAGE <LL@li.org>\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+
+#. Instead of a literal translation, add your name to the end of the list (separated by a comma).
+#, ignore-inconsistent
+msgid ""
+"_: NAME OF TRANSLATORS\n"
+"Your names"
+msgstr ""
+
+#. Instead of a literal translation, add your email to the end of the list (separated by a comma).
+#, ignore-inconsistent
+msgid ""
+"_: EMAIL OF TRANSLATORS\n"
+"Your emails"
+msgstr ""
+
+#: lirc-configuration.cpp:34
+msgid "digit 0"
+msgstr ""
+
+#: lirc-configuration.cpp:35
+msgid "digit 1"
+msgstr ""
+
+#: lirc-configuration.cpp:36
+msgid "digit 2"
+msgstr ""
+
+#: lirc-configuration.cpp:37
+msgid "digit 3"
+msgstr ""
+
+#: lirc-configuration.cpp:38
+msgid "digit 4"
+msgstr ""
+
+#: lirc-configuration.cpp:39
+msgid "digit 5"
+msgstr ""
+
+#: lirc-configuration.cpp:40
+msgid "digit 6"
+msgstr ""
+
+#: lirc-configuration.cpp:41
+msgid "digit 7"
+msgstr ""
+
+#: lirc-configuration.cpp:42
+msgid "digit 8"
+msgstr ""
+
+#: lirc-configuration.cpp:43
+msgid "digit 9"
+msgstr ""
+
+#: lirc-configuration.cpp:44
+msgid "Power On"
+msgstr ""
+
+#: lirc-configuration.cpp:45
+msgid "Power Off"
+msgstr ""
+
+#: lirc-configuration.cpp:46
+msgid "Pause"
+msgstr ""
+
+#: lirc-configuration.cpp:47
+msgid "Start Recording"
+msgstr ""
+
+#: lirc-configuration.cpp:48
+msgid "Stop Recording"
+msgstr ""
+
+#: lirc-configuration.cpp:49
+msgid "Increase Volume"
+msgstr ""
+
+#: lirc-configuration.cpp:50
+msgid "Decrease Volume"
+msgstr ""
+
+#: lirc-configuration.cpp:51
+msgid "Next Channel"
+msgstr ""
+
+#: lirc-configuration.cpp:52
+msgid "Previous Channel"
+msgstr ""
+
+#: lirc-configuration.cpp:53
+msgid "Search Next Channel"
+msgstr ""
+
+#: lirc-configuration.cpp:54
+msgid "Search Previous Channel"
+msgstr ""
+
+#: lirc-configuration.cpp:55
+msgid "Enable Sleep Countdown"
+msgstr ""
+
+#: lirc-configuration.cpp:56
+msgid "Quit TDERadio"
+msgstr ""
+
+#: lirc-configuration.cpp:176
+msgid ""
+"Enter the key string of your remote or just press the button on your remote "
+"control"
+msgstr ""
+
+#: lirc-configuration.cpp:182
+msgid "Double Click on the entries to change the assignments"
+msgstr ""
+
+#: lircsupport.cpp:47
+msgid "Linux Infrared Control (LIRC) Support"
+msgstr ""
+
+#: lircsupport.cpp:53 lircsupport.cpp:332
+msgid "LIRC Plugin"
+msgstr ""
+
+#: lircsupport.cpp:58 lircsupport.cpp:59
+msgid "initializing tderadio lirc plugin"
+msgstr ""
+
+#: lircsupport.cpp:67
+msgid ""
+"%1 does not exist. File was created with TDERadio's default .lircrc proposal"
+msgstr ""
+
+#: lircsupport.cpp:96
+msgid "There is no entry for tderadio in any of your .lircrc files."
+msgstr ""
+
+#: lircsupport.cpp:97
+msgid "Please setup your .lircrc files correctly."
+msgstr ""
+
+#: lircsupport.cpp:108 lircsupport.cpp:109
+msgid "Initializing tderadio lirc plugin failed"
+msgstr ""
+
+#: lircsupport.cpp:111 lircsupport.cpp:112
+msgid "Initializing tderadio lirc plugin successful"
+msgstr ""
+
+#: lircsupport.cpp:169
+msgid ""
+"Reading from LIRC socket failed. Disabling LIRC Functions till next start of "
+"tderadio"
+msgstr ""
+
+#: lircsupport.cpp:331
+msgid "LIRC Support"
+msgstr ""
+
+#: lirc-configuration-ui.ui:17
+#, no-c-format
+msgid "LIRCConfigurationUI"
+msgstr ""
+
+#: lirc-configuration-ui.ui:26
+#, no-c-format
+msgid "Action"
+msgstr ""
+
+#: lirc-configuration-ui.ui:37
+#, no-c-format
+msgid "LIRC String"
+msgstr ""
+
+#: lirc-configuration-ui.ui:48
+#, no-c-format
+msgid "Alternative LIRC String"
+msgstr ""
+
+#: lirc-configuration-ui.ui:98
+#, no-c-format
+msgid "textLabel1"
+msgstr ""