Use CefRect for CefWindowInfo bounds (fixes issue #1515)

This commit is contained in:
Marshall Greenblatt
2021-09-27 11:48:30 +03:00
parent 41b64e428c
commit 23be17f693
16 changed files with 148 additions and 121 deletions

View File

@ -81,10 +81,7 @@ struct CefWindowInfoTraits {
bool copy) {
cef_string_set(src->window_name.str, src->window_name.length,
&target->window_name, copy);
target->x = src->x;
target->y = src->y;
target->width = src->width;
target->height = src->height;
target->bounds = src->bounds;
target->parent_window = src->parent_window;
target->windowless_rendering_enabled = src->windowless_rendering_enabled;
target->shared_texture_enabled = src->shared_texture_enabled;
@ -105,12 +102,9 @@ class CefWindowInfo : public CefStructBase<CefWindowInfoTraits> {
///
// Create the browser as a child window.
///
void SetAsChild(CefWindowHandle parent, const CefRect& windowRect) {
void SetAsChild(CefWindowHandle parent, const CefRect& bounds) {
parent_window = parent;
x = windowRect.x;
y = windowRect.y;
width = windowRect.width;
height = windowRect.height;
this->bounds = bounds;
}
///