equal
deleted
inserted
replaced
59 void CMccRedrawHandler::BlackDrawingL( TBool aIsEnabled ) |
59 void CMccRedrawHandler::BlackDrawingL( TBool aIsEnabled ) |
60 { |
60 { |
61 __V_SOURCESINK_CONTROLL_INT1( "CMccRedrawHandler::BlackDrawingL, enabled:", |
61 __V_SOURCESINK_CONTROLL_INT1( "CMccRedrawHandler::BlackDrawingL, enabled:", |
62 aIsEnabled ) |
62 aIsEnabled ) |
63 |
63 |
64 iDrawBlack = aIsEnabled; |
|
65 |
64 |
66 if ( DoRedrawing() ) |
65 if ( DoRedrawing() ) |
67 { |
66 { |
68 StartRedrawing(); |
67 StartRedrawing(); |
69 } |
68 } |
114 RWindow& aWindow, |
113 RWindow& aWindow, |
115 CWindowGc& aGc ) : |
114 CWindowGc& aGc ) : |
116 CActive( CActive::EPriorityStandard ), |
115 CActive( CActive::EPriorityStandard ), |
117 iWsSession( aWsSession ), |
116 iWsSession( aWsSession ), |
118 iWindow( aWindow ), |
117 iWindow( aWindow ), |
119 iGc( aGc ), |
118 iGc( aGc ) |
120 iDrawBlack( EFalse ) |
|
121 { |
119 { |
122 CActiveScheduler::Add( this ); |
120 CActiveScheduler::Add( this ); |
123 } |
121 } |
124 |
122 |
125 // ----------------------------------------------------------------------------- |
123 // ----------------------------------------------------------------------------- |
148 |
146 |
149 iGc.Activate( iWindow ); |
147 iGc.Activate( iWindow ); |
150 iWindow.Invalidate( aRect ); |
148 iWindow.Invalidate( aRect ); |
151 iWindow.BeginRedraw( aRect ); |
149 iWindow.BeginRedraw( aRect ); |
152 |
150 |
153 if ( iDrawBlack ) |
151 if ( iWindow.DisplayMode() >= EColor16MA ) |
154 { |
|
155 iGc.SetBrushStyle( CGraphicsContext::ESolidBrush ); |
|
156 iGc.SetBrushColor( KRgbBlack ); |
|
157 iGc.Clear( aRect ); |
|
158 iDrawBlack = EFalse; |
|
159 } |
|
160 else if ( iWindow.DisplayMode() >= EColor16MA ) |
|
161 { |
152 { |
162 // Need to set alpha mode, otherwise video cannot be seen |
153 // Need to set alpha mode, otherwise video cannot be seen |
163 iGc.SetDrawMode( CGraphicsContext::EDrawModeWriteAlpha ); |
154 iGc.SetDrawMode( CGraphicsContext::EDrawModeWriteAlpha ); |
164 iGc.SetBrushColor( TRgb( 0, 0 ) ); |
155 iGc.SetBrushColor( TRgb( 0, 0 ) ); |
165 iGc.Clear( aRect ); |
156 iGc.Clear( aRect ); |
180 // CMccRedrawHandler::DoRedrawing |
171 // CMccRedrawHandler::DoRedrawing |
181 // ----------------------------------------------------------------------------- |
172 // ----------------------------------------------------------------------------- |
182 // |
173 // |
183 TBool CMccRedrawHandler::DoRedrawing() const |
174 TBool CMccRedrawHandler::DoRedrawing() const |
184 { |
175 { |
185 return ( iDrawBlack || iWindow.DisplayMode() >= EColor16MA ); |
176 return ( iWindow.DisplayMode() >= EColor16MA ); |
186 } |
177 } |
187 |
178 |
188 // ----------------------------------------------------------------------------- |
179 // ----------------------------------------------------------------------------- |
189 // CMccRedrawHandler::StartRedrawing |
180 // CMccRedrawHandler::StartRedrawing |
190 // ----------------------------------------------------------------------------- |
181 // ----------------------------------------------------------------------------- |