Commit e414951c authored by Ghislain MARY's avatar Ghislain MARY

Really fix duration of remote refresh timer for is-composing.

parent 5c8fe022
......@@ -123,8 +123,10 @@ void IsComposing::startRefreshTimer () {
}
}
void IsComposing::startRemoteRefreshTimer () {
void IsComposing::startRemoteRefreshTimer (const char *refreshStr) {
int duration = getRemoteRefreshTimerDuration();
if (refreshStr)
duration = atoi(refreshStr);
if (!remoteRefreshTimer) {
remoteRefreshTimer = sal_create_timer(core->sal, remoteRefreshTimerExpired, this,
duration * 1000, "composing remote refresh timeout");
......@@ -217,11 +219,8 @@ void IsComposing::parse (xmlparsing_context_t *xmlCtx) {
if (stateStr) {
if (strcmp(stateStr, "active") == 0) {
//int refreshDuration = getRefreshTimerDuration();
state = true;
//if (refreshStr)
// refreshDuration = atoi(refreshStr);
startRemoteRefreshTimer();
startRemoteRefreshTimer(refreshStr);
} else {
stopRemoteRefreshTimer();
}
......
......@@ -39,7 +39,7 @@ public:
void parse (const std::string &content);
void startIdleTimer ();
void startRefreshTimer ();
void startRemoteRefreshTimer ();
void startRemoteRefreshTimer (const char *refreshStr);
void stopComposing ();
void stopIdleTimer ();
void stopRefreshTimer ();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment