From ce3b7142fd8cc65d155ef850cbd31f7dc3ad824f Mon Sep 17 00:00:00 2001 From: Michael Ziegler Date: Sat, 22 Aug 2009 19:40:16 +0200 Subject: [PATCH] updating slice and ctl to work with the Murmur snapshot from 21-Aug-2009 --- pyweb/mumble/MumbleCtlIce.py | 6 +++--- pyweb/mumble/Murmur_1-2-0.ice | 21 +++++++++++++-------- 2 files changed, 16 insertions(+), 11 deletions(-) diff --git a/pyweb/mumble/MumbleCtlIce.py b/pyweb/mumble/MumbleCtlIce.py index 1a5b19a..2e4cbd0 100644 --- a/pyweb/mumble/MumbleCtlIce.py +++ b/pyweb/mumble/MumbleCtlIce.py @@ -270,8 +270,8 @@ class MumbleCtlIce_120(MumbleCtlIce_118): users = self._getIceServerObject( srvid ).getRegisteredUsers( filter.encode( "UTF-8" ) ) ret = [] - for user in users: - ret.append([user.playerid, self.setUnicodeFlag(user.name), self.setUnicodeFlag(user.email), self.setUnicodeFlag(user.pw)]) + for id in users: + ret.append( [ id, self.setUnicodeFlag( users[id] ) ] ); return ret @@ -292,7 +292,7 @@ class MumbleCtlIce_120(MumbleCtlIce_118): for x in users: user = users[x] - ret.append([user.session, user.mute, user.deaf, user.suppressed, user.selfMute, user.selfDeaf, user.channel, user.userid, self.setUnicodeFlag(user.name), user.onlinesecs, user.bytespersec]) + ret.append([user.session, user.mute, user.deaf, user.suppress, user.selfMute, user.selfDeaf, user.channel, user.userid, self.setUnicodeFlag(user.name), user.onlinesecs, user.bytespersec]) return ret diff --git a/pyweb/mumble/Murmur_1-2-0.ice b/pyweb/mumble/Murmur_1-2-0.ice index 29a9a08..393d01f 100644 --- a/pyweb/mumble/Murmur_1-2-0.ice +++ b/pyweb/mumble/Murmur_1-2-0.ice @@ -55,7 +55,7 @@ module Murmur /** Is user deafened by the server? If true, this implies mute. */ bool deaf; /** Is the user suppressed by the server? This means the user is not muted, but does not have speech privileges in the current channel. */ - bool suppressed; + bool suppress; /** Is the user self-muted? */ bool selfMute; /** Is the user self-deafened? If true, this implies mute. */ @@ -107,6 +107,8 @@ module Murmur string description; /** Channel is temporary, and will be removed when the last user leaves it. */ bool temporary; + /** Position of the channel which is used in Client for sorting. */ + int position; }; /** A group. Groups are defined per channel, and can inherit members from parent channels. @@ -208,6 +210,9 @@ module Murmur class Tree; sequence TreeList; + enum ChannelInfo { ChannelDescription, ChannelPosition }; + enum UserInfo { UserName, UserEmail, UserComment, UserHash, UserPassword }; + dictionary UserMap; dictionary ChannelMap; sequence ChannelList; @@ -220,7 +225,7 @@ module Murmur sequence NameList; dictionary NameMap; dictionary IdMap; - dictionary InfoMap; + dictionary UserInfoMap; sequence Texture; dictionary ConfigMap; sequence GroupNameList; @@ -342,7 +347,7 @@ module Murmur * @param info Information about user. This needs to include at least "name". * @return true if information is present, false to fall through. */ - idempotent bool getInfo(int id, out InfoMap info); + idempotent bool getInfo(int id, out UserInfoMap info); /** Map a name to a user id. * @param name Username to map. @@ -375,7 +380,7 @@ module Murmur * @param info Information about user to register. * @return User id of new user, -1 for registration failure, or -2 to fall through. */ - int registerUser(InfoMap info); + int registerUser(UserInfoMap info); /** Unregister a user. * @param id Userid to unregister. @@ -394,7 +399,7 @@ module Murmur * @param info Information to set about user. This should be merged with existing information. * @return 1 for successfull update, 0 for unsuccessfull update, -1 to fall through. */ - idempotent int setInfo(int id, InfoMap info); + idempotent int setInfo(int id, UserInfoMap info); /** Set texture of user registration. * @param id Userid of registered user. @@ -628,7 +633,7 @@ module Murmur * @param info Information about new user. Must include at least "name". * @return The ID of the user. See [RegisteredUser::userid]. */ - int registerUser(InfoMap info) throws ServerBootedException, InvalidUserException; + int registerUser(UserInfoMap info) throws ServerBootedException, InvalidUserException; /** Remove a user registration. * @param userid ID of registered user. See [RegisteredUser::userid]. @@ -639,13 +644,13 @@ module Murmur * and can also use it to change the user's name. * @param registration Updated registration record. */ - idempotent void updateRegistration(int userid, InfoMap info) throws ServerBootedException, InvalidUserException; + idempotent void updateRegistration(int userid, UserInfoMap info) throws ServerBootedException, InvalidUserException; /** Fetch registration for a single user. * @param userid ID of registered user. See [RegisteredUser::userid]. * @return Registration record. */ - idempotent InfoMap getRegistration(int userid) throws ServerBootedException, InvalidUserException; + idempotent UserInfoMap getRegistration(int userid) throws ServerBootedException, InvalidUserException; /** Fetch a group of registered users. * @param filter Substring of user name. If blank, will retrieve all registered users.