From 32b055f56287e97d84a4431a36909027991ef1fc Mon Sep 17 00:00:00 2001 From: Kitsune Ral Date: Tue, 12 Apr 2016 16:03:29 +0900 Subject: Change the way room members are stored to the one recommended by the CS spec. According to section 11.2.2.3 of the CS spec, clients SHOULD follow a certain algorithm of making a non-ambiguous display name of a user in the room context. This algorithm implies checking whether other room members have the same display name. This commit prepares for implementation of the algorithm: 1. Use a hash map instead of a list to store room members. The external Room::users() API is kept intact. 2. Convenience CRUD methods are implemented to deal with the hash map. 3. An additional slot for user renaming is introduced (because renaming affects the hash map). Binding of actual signals is left for the next commit. 4. nullptr is the recommended representation of a null pointer since C++11. Use that and mandate compiler support of that. --- CMakeLists.txt | 1 + 1 file changed, 1 insertion(+) (limited to 'CMakeLists.txt') diff --git a/CMakeLists.txt b/CMakeLists.txt index 32792435..0203f2dc 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -104,6 +104,7 @@ else ( CMAKE_VERSION VERSION_LESS "3.1" ) target_compile_features(qmatrixclient PRIVATE cxx_lambdas) target_compile_features(qmatrixclient PRIVATE cxx_auto_type) target_compile_features(qmatrixclient PRIVATE cxx_generalized_initializers) + target_compile_features(qmatrixclient PRIVATE cxx_nullptr) endif ( CMAKE_VERSION VERSION_LESS "3.1" ) target_link_libraries(qmatrixclient Qt5::Core Qt5::Network Qt5::Gui) -- cgit v1.2.3