520 // Create new timer with ascending identifier. |
520 // Create new timer with ascending identifier. |
521 TInt count( iPulseData.Count() ); |
521 TInt count( iPulseData.Count() ); |
522 CHWRMGenericTimer* timer = |
522 CHWRMGenericTimer* timer = |
523 CHWRMGenericTimer::NewL(*this, iVibraCommonData.MaximumOnTime(), count ); |
523 CHWRMGenericTimer::NewL(*this, iVibraCommonData.MaximumOnTime(), count ); |
524 iActiveTimerId = count; |
524 iActiveTimerId = count; |
|
525 CleanupStack::PushL( timer ); |
525 CPulseData* pulseData = CPulseData::NewL(*timer, iLastIntensity, aIntensity, iActiveTimerId ); |
526 CPulseData* pulseData = CPulseData::NewL(*timer, iLastIntensity, aIntensity, iActiveTimerId ); |
526 CleanupStack::PushL( pulseData ); |
527 CleanupStack::PushL( pulseData ); |
527 iPulseData.AppendL( pulseData ); |
528 iPulseData.AppendL( pulseData ); |
528 CleanupStack::Pop( pulseData ); |
529 CleanupStack::Pop( 2, timer ); |
529 iPulseData[count]->Timer().Set(aDuration); |
530 iPulseData[count]->Timer().Set(aDuration); |
530 } |
531 } |
531 |
532 |
532 // complete message if suspended, as there will not be ProcessResponseL |
533 // complete message if suspended, as there will not be ProcessResponseL |
533 if ( iSuspended && aMessage.Handle() ) |
534 if ( iSuspended && aMessage.Handle() ) |