6 * Copyright (C) 2010-11 SIPE Project <http://sipe.sourceforge.net/>
8 * This program is free software; you can redistribute it and/or modify
9 * it under the terms of the GNU General Public License as published by
10 * the Free Software Foundation; either version 2 of the License, or
11 * (at your option) any later version.
13 * This program is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 * GNU General Public License for more details.
18 * You should have received a copy of the GNU General Public License
19 * along with this program; if not, write to the Free Software
20 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
27 #include "newpluginapi.h"
28 #include "m_protosvc.h"
29 #include "m_protoint.h"
31 #include "sipe-backend.h"
32 #include "sipe-core.h"
33 #include "sipe-core-private.h"
34 #include "miranda-private.h"
36 void sipe_backend_user_feedback_typing(struct sipe_core_public
*sipe_public
,
39 HANDLE hContact
= sipe_backend_buddy_find( sipe_public
, from
, NULL
);
44 CallService(MS_PROTO_CONTACTISTYPING
, (WPARAM
)hContact
, (LPARAM
)6);
47 void sipe_backend_user_feedback_typing_stop(struct sipe_core_public
*sipe_public
,
50 HANDLE hContact
= sipe_backend_buddy_find( sipe_public
, from
, NULL
);
55 CallService(MS_PROTO_CONTACTISTYPING
, (WPARAM
)hContact
, (LPARAM
)0);
58 void sipe_backend_user_ask(struct sipe_core_public
*sipe_public
,
60 const gchar
*accept_label
,
61 const gchar
*decline_label
,
67 void sipe_backend_user_close_ask(gpointer key
)
72 int sipe_miranda_SetAwayMsg(SIPPROTO
*pr
,
76 const gchar
*note
= TCHAR2CHAR(msg
);
78 SIPE_DEBUG_INFO("SetAwayMsg: status <%x> msg <%ls>", m_iStatus
, msg
);
79 sipe_miranda_setString(pr
, "note", note
);
81 if (pr
->state
== SIPE_MIRANDA_CONNECTED
)
82 sipe_core_set_status(pr
->sip
, note
, MirandaStatusToSipe(pr
->proto
.m_iStatus
));