~ubuntu-branches/ubuntu/wily/sflphone/wily

« back to all changes in this revision

Viewing changes to daemon/src/sip/sippresence.cpp

  • Committer: Package Import Robot
  • Author(s): Jonathan Riddell
  • Date: 2015-01-07 14:51:16 UTC
  • mfrom: (4.3.5 sid)
  • Revision ID: package-import@ubuntu.com-20150107145116-yxnafinf4lrdvrmx
Tags: 1.4.1-0.1ubuntu1
* Merge with Debian, remaining changes:
 - Drop soprano, nepomuk build-dep
* Drop ubuntu patches, now upstream

Show diffs side-by-side

added added

removed removed

Lines of Context:
126
126
 
127
127
void SIPPresence::support(int function, bool supported)
128
128
{
129
 
    if(function == PRESENCE_FUNCTION_PUBLISH)
 
129
    if (function == PRESENCE_FUNCTION_PUBLISH)
130
130
        publish_supported_ = supported;
131
 
    else if(function == PRESENCE_FUNCTION_SUBSCRIBE)
 
131
    else if (function == PRESENCE_FUNCTION_SUBSCRIBE)
132
132
        subscribe_supported_ = supported;
133
133
}
134
134
 
135
135
bool SIPPresence::isSupported(int function)
136
136
{
137
 
    if(function == PRESENCE_FUNCTION_PUBLISH)
 
137
    if (function == PRESENCE_FUNCTION_PUBLISH)
138
138
        return publish_supported_;
139
 
    else if(function == PRESENCE_FUNCTION_SUBSCRIBE)
 
139
    else if (function == PRESENCE_FUNCTION_SUBSCRIBE)
140
140
        return subscribe_supported_;
141
141
 
142
142
    return false;
198
198
    const std::string note(status->info[0].rpid.note.ptr, status->info[0].rpid.note.slen);
199
199
    DEBUG(" Received status of PresSubClient  %s(acc:%s): status=%s note=%s", uri.c_str(), acc_ID.c_str(), basic.c_str(), note.c_str());
200
200
 
201
 
    if(uri == acc_->getFromUri())
202
 
    {
 
201
    if (uri == acc_->getFromUri()) {
203
202
        // save the status of our own account
204
203
        status_ = status->info[0].basic_open;
205
204
        note_ = note;
224
223
    for (const auto & c : sub_client_list_) {
225
224
        if (c->getURI() == uri) {
226
225
            //DEBUG("-PresSubClient:%s exists in the list. Replace it.", uri.c_str());
227
 
            if(flag)
 
226
            if (flag)
228
227
                c->subscribe();
229
228
            else
230
229
                c->unsubscribe();