Skip to content

Commit b854309

Browse files
committed
Ignore overlay texture when hardware accelerated
This fixes an issue where opening an <input type="date"> would result in flickering between the base texture & a smaller texture of the date picker. This brings behaviour in line with non-accelerated rendering. Ideally PET_POPUP textures (both accelerated & not) should be properly stored and rendered on top of the bs->texture displayed to the user. For more info see #148
1 parent f7aa2dc commit b854309

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

browser-client.cpp

+9-2
Original file line numberDiff line numberDiff line change
@@ -219,6 +219,7 @@ void BrowserClient::OnPaint(CefRefPtr<CefBrowser>, PaintElementType type,
219219
int height)
220220
{
221221
if (type != PET_VIEW) {
222+
// TODO Overlay texture on top of bs->texture
222223
return;
223224
}
224225

@@ -255,9 +256,15 @@ void BrowserClient::OnPaint(CefRefPtr<CefBrowser>, PaintElementType type,
255256
}
256257

257258
#ifdef SHARED_TEXTURE_SUPPORT_ENABLED
258-
void BrowserClient::OnAcceleratedPaint(CefRefPtr<CefBrowser>, PaintElementType,
259-
const RectList &, void *shared_handle)
259+
void BrowserClient::OnAcceleratedPaint(CefRefPtr<CefBrowser>,
260+
PaintElementType type, const RectList &,
261+
void *shared_handle)
260262
{
263+
if (type != PET_VIEW) {
264+
// TODO Overlay texture on top of bs->texture
265+
return;
266+
}
267+
261268
if (!bs) {
262269
return;
263270
}

0 commit comments

Comments
 (0)