zengtao
15th December 2010, 02:41
Recently, I was testing something related to QDBus. First,I successfully register a service and object on dbus. But then when I use QDBusInterface, the problem appears. detail is as below:
QDBusInterface *indicatorIface;
QDebug()<<...time info
indicatorIface = new QDBusInterface ("seivice name","path","interface name","connection")
QDebug()<<...time info
when I test the program,I find that the time costed by this sentence is not stable at all. sometimes, it is 3s, and other times it takes 25s(the default timeout time), and after reading the DBUS debug info, I find that the QDBusInterface uses blocking call (calls introspect) in its constructor.
But for my application, I hope to reduce the time wasted here as much as possiblem, so I hope someone can help me find a way out, thanks
QDBusInterface *indicatorIface;
QDebug()<<...time info
indicatorIface = new QDBusInterface ("seivice name","path","interface name","connection")
QDebug()<<...time info
when I test the program,I find that the time costed by this sentence is not stable at all. sometimes, it is 3s, and other times it takes 25s(the default timeout time), and after reading the DBUS debug info, I find that the QDBusInterface uses blocking call (calls introspect) in its constructor.
But for my application, I hope to reduce the time wasted here as much as possiblem, so I hope someone can help me find a way out, thanks