aboutsummaryrefslogtreecommitdiff
path: root/lib/qmmp/Output/oss/outputossfactory.cpp
diff options
context:
space:
mode:
authorstalkerg <stalkerg@90c681e8-e032-0410-971d-27865f9a5e38>2007-08-08 22:11:13 +0000
committerstalkerg <stalkerg@90c681e8-e032-0410-971d-27865f9a5e38>2007-08-08 22:11:13 +0000
commit3ee3fee6bc965308885f80237ed65b73db8dbfec (patch)
treeda66afe614ff0293a5d9e60212299cd19de71d92 /lib/qmmp/Output/oss/outputossfactory.cpp
parent928f98c35133381cadb3e263b7de3e636277c21e (diff)
downloadqmmp-3ee3fee6bc965308885f80237ed65b73db8dbfec.tar.gz
qmmp-3ee3fee6bc965308885f80237ed65b73db8dbfec.tar.bz2
qmmp-3ee3fee6bc965308885f80237ed65b73db8dbfec.zip
Add OSS output plugin and fix cmake script.
git-svn-id: http://svn.code.sf.net/p/qmmp-dev/code/trunk/qmmp@70 90c681e8-e032-0410-971d-27865f9a5e38
Diffstat (limited to 'lib/qmmp/Output/oss/outputossfactory.cpp')
-rw-r--r--lib/qmmp/Output/oss/outputossfactory.cpp58
1 files changed, 58 insertions, 0 deletions
diff --git a/lib/qmmp/Output/oss/outputossfactory.cpp b/lib/qmmp/Output/oss/outputossfactory.cpp
new file mode 100644
index 000000000..11454b173
--- /dev/null
+++ b/lib/qmmp/Output/oss/outputossfactory.cpp
@@ -0,0 +1,58 @@
+/***************************************************************************
+ * Copyright (C) 2007 by Zhuravlev Uriy *
+ * stalkerg@gmail.com *
+ * *
+ * 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. *
+ * *
+ * This program is distributed in the hope that it will be useful, *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
+ * GNU General Public License for more details. *
+ * *
+ * You should have received a copy of the GNU General Public License *
+ * along with this program; if not, write to the *
+ * Free Software Foundation, Inc., *
+ * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
+ ***************************************************************************/
+
+#include <QtGui>
+
+#include "outputoss.h"
+#include "outputossfactory.h"
+
+
+const QString& OutputOSSFactory::name() const
+{
+ static QString name(tr("OSS Plugin"));
+ return name;
+}
+
+Output* OutputOSSFactory::create(QObject* parent)
+{
+ return new OutputOSS(parent);
+}
+
+void OutputOSSFactory::showSettings(QWidget*)
+{
+}
+
+void OutputOSSFactory::showAbout(QWidget *parent)
+{
+QMessageBox::about (parent, tr("About OSS Output Plugin"),
+ tr("Qmmp OSS Output Plugin")+"\n"+
+ tr("Writen by: Yuriy Zhuravlev <slalkerg@gmail.com>")+"\n"+
+ tr("Based on code by:Brad Hughes <bhughes@trolltech.com>"));
+}
+
+QTranslator *OutputOSSFactory::createTranslator(QObject *parent)
+{
+ QTranslator *translator = new QTranslator(parent);
+ QString locale = QLocale::system().name();
+ translator->load(QString(":/oss_plugin_") + locale);
+ return translator;
+}
+
+Q_EXPORT_PLUGIN(OutputOSSFactory)