On 05/27/2010 03:35 PM, krishna k wrote:
Hi,
I am trying to implement application using qt dbus module, Which will call SetProperty
with parameters QString, QVariant.
...
I am trying the same thing using qt program...
QDBusConnection bus = QDBusConnection::systemBus();
QDBusInterface dbus_iface("org.ofono",
"/phonesim0/operator/23402",
"org.ofono.Modem", bus);
bool value = true;
dbus_iface.call("SetProperty", QString("Powered"),
QVariant(QVariant::Bool,&value));
I believe "v" maps to QDBusVariant, not QVariant. Maybe something like
this works:
bool value = true;
var = QDBusVariant (QVariant(QVariant::Bool,&value));
dbus_iface.call("SetProperty", QString("Powered"), var);
Jussi