Fix wrong channel texting after channel join.

This commit is contained in:
Michał Słomkowski 2015-12-14 02:36:25 +01:00
parent 4b8fad8263
commit 7a45a4c40d
3 changed files with 5 additions and 4 deletions

View File

@ -41,7 +41,7 @@ namespace mumlib {
void sendTextMessage(std::string message); void sendTextMessage(std::string message);
void joinChannel(int channel_id); void joinChannel(int channelId);
private: private:
_Mumlib_Private *impl; _Mumlib_Private *impl;

View File

@ -179,7 +179,7 @@ namespace mumlib {
string welcome_text, string welcome_text,
int32_t session, int32_t session,
int32_t max_bandwidth, int32_t max_bandwidth,
int64_t permissions); int64_t permissions) override;
virtual void channelRemove(uint32_t channel_id) override; virtual void channelRemove(uint32_t channel_id) override;

View File

@ -379,9 +379,10 @@ namespace mumlib {
impl->transport.sendControlMessage(MessageType::TEXTMESSAGE, textMessage); impl->transport.sendControlMessage(MessageType::TEXTMESSAGE, textMessage);
} }
void Mumlib::joinChannel(int channel_id) { void Mumlib::joinChannel(int channelId) {
MumbleProto::UserState userState; MumbleProto::UserState userState;
userState.set_channel_id(channel_id); userState.set_channel_id(channelId);
impl->transport.sendControlMessage(MessageType::USERSTATE, userState); impl->transport.sendControlMessage(MessageType::USERSTATE, userState);
impl->channelId = channelId;
} }
} }