dbus/qt qdbusconnection.cpp,1.2,1.3 qdbusconnection.h,1.2,1.3
John Palmieri
johnp at freedesktop.org
Wed Nov 30 16:07:22 PST 2005
Update of /cvs/dbus/dbus/qt
In directory gabe:/tmp/cvs-serv24390/qt
Modified Files:
qdbusconnection.cpp qdbusconnection.h
Log Message:
* test/qt/Makefile.am: build from srcdir
* qt/qtconnection.cpp (requestName): Changed PROHIBIT_REPLACE to ALLOW_REPLACE
Note - this code is wrong and needs to be fixed by the Qt binding
developers. The flags should be treated as bitfields and not enums.
* qt/qtconnection.h: Change ProhibitReplace to AllowReplace
* dbus/dbus-list.c (link_after): remove #ifdef DBUS_BUILD_TESTS
Index: qdbusconnection.cpp
===================================================================
RCS file: /cvs/dbus/dbus/qt/qdbusconnection.cpp,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -d -r1.2 -r1.3
--- qdbusconnection.cpp 23 Sep 2005 16:24:36 -0000 1.2
+++ qdbusconnection.cpp 1 Dec 2005 00:07:20 -0000 1.3
@@ -307,10 +307,11 @@
bool QDBusConnection::requestName(const QString &name, NameRequestMode mode)
{
- static const int DBusModes[] = { 0, DBUS_NAME_FLAG_PROHIBIT_REPLACEMENT,
+ //FIXME: DBUS_NAME_FLAGS_* are bit fields not enumeration
+ static const int DBusModes[] = { 0, DBUS_NAME_FLAG_ALLOW_REPLACEMENT,
DBUS_NAME_FLAG_REPLACE_EXISTING };
- Q_ASSERT(mode == 0 || mode == DBUS_NAME_FLAG_PROHIBIT_REPLACEMENT ||
- mode == DBUS_NAME_FLAG_REPLACE_EXISTING);
+ Q_ASSERT(mode == 0 || mode == AllowReplace ||
+ mode == ReplaceExisting );
DBusError error;
dbus_error_init (&error);
Index: qdbusconnection.h
===================================================================
RCS file: /cvs/dbus/dbus/qt/qdbusconnection.h,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -d -r1.2 -r1.3
--- qdbusconnection.h 23 Sep 2005 16:24:36 -0000 1.2
+++ qdbusconnection.h 1 Dec 2005 00:07:20 -0000 1.3
@@ -46,7 +46,7 @@
bool isConnected() const;
QDBusError lastError() const;
- enum NameRequestMode { NoReplace = 0, ProhibitReplace = 1, ReplaceExisting = 2 };
+ enum NameRequestMode { NoReplace = 0, AllowReplace = 1, ReplaceExisting = 2 };
bool requestName(const QString &name, NameRequestMode mode = NoReplace);
QString baseService() const;
More information about the dbus-commit
mailing list