2 * vdr-tv-client: TV frontend for watching tv streams from the vdr server.
4 * Copyright (c) 2011, Mika Laitio. <lamikr@pilppa.org>
6 * This program is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU General Public License
8 * as published by the Free Software Foundation; either version 2
9 * of the License, or (at your option) any later version.
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
16 * You should have received a copy of the GNU General Public License
17 * along with this program; if not, write to the Free Software
18 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
19 * Or, point your browser to http://www.gnu.org/copyleft/gpl.html
23 #include "QMLVDRClient.h"
24 #include <QtDeclarative>
26 class QMLVDRClientPrivate {
28 QMLVDRClientPrivate(){}
31 QMLVDRClient::QMLVDRClient(QObject *parent) : QObject(parent), priva(new QMLVDRClientPrivate) {
34 QMLVDRClient::~QMLVDRClient() {
38 void QMLVDRClient::launch_viewer(const QString &server_address) {
39 QTextStream out(stdout);
41 out << "vdr server address for client launch: " << server_address << endl;
42 QString program = "/usr/bin/vdr-sxfe";
43 QStringList arguments;
44 //arguments << "-style" << "motif";
45 arguments << server_address;
46 QProcess *myProcess = new QProcess(this);
47 out << "calling start" << endl;
48 myProcess->start(program, arguments);
49 out << "wait for finished" << endl;
50 myProcess->waitForFinished();
51 out << "wait for finished done" << endl;