Lines Matching refs:update
132 SpriteUpdate& update = updates.editItemAt(i); in doUpdateSprites() local
134 if (update.state.surfaceControl == NULL && update.state.wantSurfaceVisible()) { in doUpdateSprites()
135 update.state.surfaceWidth = update.state.icon.bitmap.width(); in doUpdateSprites()
136 update.state.surfaceHeight = update.state.icon.bitmap.height(); in doUpdateSprites()
137 update.state.surfaceDrawn = false; in doUpdateSprites()
138 update.state.surfaceVisible = false; in doUpdateSprites()
139 update.state.surfaceControl = obtainSurface( in doUpdateSprites()
140 update.state.surfaceWidth, update.state.surfaceHeight); in doUpdateSprites()
141 if (update.state.surfaceControl != NULL) { in doUpdateSprites()
142 update.surfaceChanged = surfaceChanged = true; in doUpdateSprites()
151 SpriteUpdate& update = updates.editItemAt(i); in doUpdateSprites() local
152 if (update.state.surfaceControl == nullptr) { in doUpdateSprites()
156 if (update.state.wantSurfaceVisible()) { in doUpdateSprites()
157 int32_t desiredWidth = update.state.icon.bitmap.width(); in doUpdateSprites()
158 int32_t desiredHeight = update.state.icon.bitmap.height(); in doUpdateSprites()
159 if (update.state.surfaceWidth < desiredWidth in doUpdateSprites()
160 || update.state.surfaceHeight < desiredHeight) { in doUpdateSprites()
163 t.setSize(update.state.surfaceControl, in doUpdateSprites()
165 update.state.surfaceWidth = desiredWidth; in doUpdateSprites()
166 update.state.surfaceHeight = desiredHeight; in doUpdateSprites()
167 update.state.surfaceDrawn = false; in doUpdateSprites()
168 update.surfaceChanged = surfaceChanged = true; in doUpdateSprites()
170 if (update.state.surfaceVisible) { in doUpdateSprites()
171 t.hide(update.state.surfaceControl); in doUpdateSprites()
172 update.state.surfaceVisible = false; in doUpdateSprites()
178 if (update.surfaceChanged || update.state.dirty & DIRTY_DISPLAY_ID) { in doUpdateSprites()
179 t.setLayerStack(update.state.surfaceControl, update.state.displayId); in doUpdateSprites()
189 SpriteUpdate& update = updates.editItemAt(i); in doUpdateSprites() local
191 if ((update.state.dirty & DIRTY_BITMAP) && update.state.surfaceDrawn) { in doUpdateSprites()
192 update.state.surfaceDrawn = false; in doUpdateSprites()
193 update.surfaceChanged = surfaceChanged = true; in doUpdateSprites()
196 if (update.state.surfaceControl != NULL && !update.state.surfaceDrawn in doUpdateSprites()
197 && update.state.wantSurfaceVisible()) { in doUpdateSprites()
198 sp<Surface> surface = update.state.surfaceControl->getSurface(); in doUpdateSprites()
213 surfaceCanvas.drawBitmap(update.state.icon.bitmap, 0, 0, &paint); in doUpdateSprites()
215 if (outBuffer.width > update.state.icon.bitmap.width()) { in doUpdateSprites()
217 surfaceCanvas.drawRect(SkRect::MakeLTRB(update.state.icon.bitmap.width(), 0, in doUpdateSprites()
218 outBuffer.width, update.state.icon.bitmap.height()), paint); in doUpdateSprites()
220 if (outBuffer.height > update.state.icon.bitmap.height()) { in doUpdateSprites()
222 surfaceCanvas.drawRect(SkRect::MakeLTRB(0, update.state.icon.bitmap.height(), in doUpdateSprites()
230 update.state.surfaceDrawn = true; in doUpdateSprites()
231 update.surfaceChanged = surfaceChanged = true; in doUpdateSprites()
239 SpriteUpdate& update = updates.editItemAt(i); in doUpdateSprites() local
241 bool wantSurfaceVisibleAndDrawn = update.state.wantSurfaceVisible() in doUpdateSprites()
242 && update.state.surfaceDrawn; in doUpdateSprites()
243 bool becomingVisible = wantSurfaceVisibleAndDrawn && !update.state.surfaceVisible; in doUpdateSprites()
244 bool becomingHidden = !wantSurfaceVisibleAndDrawn && update.state.surfaceVisible; in doUpdateSprites()
245 if (update.state.surfaceControl != NULL && (becomingVisible || becomingHidden in doUpdateSprites()
246 || (wantSurfaceVisibleAndDrawn && (update.state.dirty & (DIRTY_ALPHA in doUpdateSprites()
252 && (becomingVisible || (update.state.dirty & DIRTY_ALPHA))) { in doUpdateSprites()
253 t.setAlpha(update.state.surfaceControl, in doUpdateSprites()
254 update.state.alpha); in doUpdateSprites()
258 && (becomingVisible || (update.state.dirty & (DIRTY_POSITION in doUpdateSprites()
261 update.state.surfaceControl, in doUpdateSprites()
262 update.state.positionX - update.state.icon.hotSpotX, in doUpdateSprites()
263 update.state.positionY - update.state.icon.hotSpotY); in doUpdateSprites()
268 || (update.state.dirty & DIRTY_TRANSFORMATION_MATRIX))) { in doUpdateSprites()
270 update.state.surfaceControl, in doUpdateSprites()
271 update.state.transformationMatrix.dsdx, in doUpdateSprites()
272 update.state.transformationMatrix.dtdx, in doUpdateSprites()
273 update.state.transformationMatrix.dsdy, in doUpdateSprites()
274 update.state.transformationMatrix.dtdy); in doUpdateSprites()
277 int32_t surfaceLayer = mOverlayLayer + update.state.layer; in doUpdateSprites()
279 && (becomingVisible || (update.state.dirty & DIRTY_LAYER))) { in doUpdateSprites()
280 t.setLayer(update.state.surfaceControl, surfaceLayer); in doUpdateSprites()
284 t.show(update.state.surfaceControl); in doUpdateSprites()
286 update.state.surfaceVisible = true; in doUpdateSprites()
287 update.surfaceChanged = surfaceChanged = true; in doUpdateSprites()
289 t.hide(update.state.surfaceControl); in doUpdateSprites()
291 update.state.surfaceVisible = false; in doUpdateSprites()
292 update.surfaceChanged = surfaceChanged = true; in doUpdateSprites()
309 const SpriteUpdate& update = updates.itemAt(i); in doUpdateSprites() local
311 if (update.surfaceChanged) { in doUpdateSprites()
312 update.sprite->setSurfaceLocked(update.state.surfaceControl, in doUpdateSprites()
313 update.state.surfaceWidth, update.state.surfaceHeight, in doUpdateSprites()
314 update.state.surfaceDrawn, update.state.surfaceVisible); in doUpdateSprites()