equal
deleted
inserted
replaced
106 // once already. |
106 // once already. |
107 if ( err == KErrAlreadyExists ) |
107 if ( err == KErrAlreadyExists ) |
108 { |
108 { |
109 User::LeaveIfError( iChunk.OpenGlobal( data.iChunkName, EFalse ) ); |
109 User::LeaveIfError( iChunk.OpenGlobal( data.iChunkName, EFalse ) ); |
110 } |
110 } |
|
111 else if( err != KErrNone ) |
|
112 { |
|
113 User::LeaveIfError( err ); |
|
114 } |
111 |
115 |
112 // #3 Set window count to zero |
116 // #3 Set window count to zero |
113 TInt* chunkPtr = reinterpret_cast<TInt*>( iChunk.Base() ); |
117 TInt* chunkPtr = reinterpret_cast<TInt*>( iChunk.Base() ); |
114 |
118 |
115 *chunkPtr = 0; // No entries in the chunk in the beginning |
119 *chunkPtr = 0; // No entries in the chunk in the beginning |
118 err = iSemaphore.CreateGlobal( KTouchFeedbackSemaphore, 1 ); |
122 err = iSemaphore.CreateGlobal( KTouchFeedbackSemaphore, 1 ); |
119 |
123 |
120 if ( err == KErrAlreadyExists ) |
124 if ( err == KErrAlreadyExists ) |
121 { |
125 { |
122 User::LeaveIfError( iSemaphore.OpenGlobal( KTouchFeedbackSemaphore ) ); |
126 User::LeaveIfError( iSemaphore.OpenGlobal( KTouchFeedbackSemaphore ) ); |
|
127 } |
|
128 else if( err != KErrNone ) |
|
129 { |
|
130 User::LeaveIfError( err ); |
123 } |
131 } |
124 |
132 |
125 // #5 Send chunk name to window server |
133 // #5 Send chunk name to window server |
126 TPckgC<TTactileFeedbackConnectData> dataPkg ( data ); |
134 TPckgC<TTactileFeedbackConnectData> dataPkg ( data ); |
127 |
135 |