KMediaPlayer
kmediaplayeradaptor.cpp
Go to the documentation of this file.
00001 /* 00002 * This file was generated by dbusidl2cpp version 0.4 00003 * when processing input file org.kde.KMediaPlayer.xml 00004 * 00005 * dbusidl2cpp is Copyright (C) 2006 Trolltech AS. All rights reserved. 00006 * 00007 * This is an auto-generated file. 00008 */ 00009 00010 #include "kmediaplayeradaptor_p.h" 00011 #include <QtCore/QArgument> 00012 #include <QtCore/QByteRef> 00013 #include <QtCore/QList> 00014 #include <QtCore/QMap> 00015 #include <QtCore/QString> 00016 #include <QtCore/QStringList> 00017 #include <QtCore/QVariant> 00018 00019 /* 00020 * Implementation of adaptor class KMediaPlayerAdaptor 00021 */ 00022 00023 KMediaPlayerAdaptor::KMediaPlayerAdaptor(QObject *parent) 00024 : QDBusAbstractAdaptor(parent) 00025 { 00026 // constructor 00027 setAutoRelaySignals(true); 00028 } 00029 00030 KMediaPlayerAdaptor::~KMediaPlayerAdaptor() 00031 { 00032 // destructor 00033 } 00034 00035 bool KMediaPlayerAdaptor::hasLength() const 00036 { 00037 // get the value of property hasLength 00038 return qvariant_cast< bool >(parent()->property("hasLength")); 00039 } 00040 00041 qlonglong KMediaPlayerAdaptor::length() const 00042 { 00043 // get the value of property length 00044 return qvariant_cast< qlonglong >(parent()->property("length")); 00045 } 00046 00047 bool KMediaPlayerAdaptor::isLooping() const 00048 { 00049 // get the value of property looping 00050 return qvariant_cast< bool >(parent()->property("looping")); 00051 } 00052 00053 void KMediaPlayerAdaptor::setLooping(bool value) 00054 { 00055 // set the value of property looping 00056 parent()->setProperty("looping", value); 00057 } 00058 00059 qlonglong KMediaPlayerAdaptor::position() const 00060 { 00061 // get the value of property position 00062 return qvariant_cast< qlonglong >(parent()->property("position")); 00063 } 00064 00065 bool KMediaPlayerAdaptor::isSeekable() const 00066 { 00067 // get the value of property seekable 00068 return qvariant_cast< bool >(parent()->property("seekable")); 00069 } 00070 00071 int KMediaPlayerAdaptor::state() const 00072 { 00073 // get the value of property state 00074 return qvariant_cast< int >(parent()->property("state")); 00075 } 00076 00077 void KMediaPlayerAdaptor::setState(int value) 00078 { 00079 // set the value of property state 00080 parent()->setProperty("state", value); 00081 } 00082 00083 bool KMediaPlayerAdaptor::openUrl(const QString &file) 00084 { 00085 // handle method call org.kde.KMediaPlayer.openUrl 00086 bool out0; 00087 QMetaObject::invokeMethod(parent(), "openUrl", Q_RETURN_ARG(bool, out0), Q_ARG(QString, file)); 00088 00089 // Alternative: 00090 //out0 = static_cast<YourObjectType *>(parent())->openUrl(file); 00091 return out0; 00092 } 00093 00094 void KMediaPlayerAdaptor::pause() 00095 { 00096 // handle method call org.kde.KMediaPlayer.pause 00097 QMetaObject::invokeMethod(parent(), "pause"); 00098 00099 // Alternative: 00100 //static_cast<YourObjectType *>(parent())->pause(); 00101 } 00102 00103 void KMediaPlayerAdaptor::play() 00104 { 00105 // handle method call org.kde.KMediaPlayer.play 00106 QMetaObject::invokeMethod(parent(), "play"); 00107 00108 // Alternative: 00109 //static_cast<YourObjectType *>(parent())->play(); 00110 } 00111 00112 void KMediaPlayerAdaptor::seek(qlonglong msec) 00113 { 00114 // handle method call org.kde.KMediaPlayer.seek 00115 QMetaObject::invokeMethod(parent(), "seek", Q_ARG(qlonglong, msec)); 00116 00117 // Alternative: 00118 //static_cast<YourObjectType *>(parent())->seek(msec); 00119 } 00120 00121 void KMediaPlayerAdaptor::stop() 00122 { 00123 // handle method call org.kde.KMediaPlayer.stop 00124 QMetaObject::invokeMethod(parent(), "stop"); 00125 00126 // Alternative: 00127 //static_cast<YourObjectType *>(parent())->stop(); 00128 } 00129 00130 00131 #include "kmediaplayeradaptor_p.moc"
KDE 4.6 API Reference