Avoid window geometry jittering when changing geometry from JavaScript
The QML API allowed only separate setting of geometry parameters which causes flickering when all parameters need to be changed. By exposing the setGeometry function it is possible to set all of these at once using an imperative setGeometry call from JavaScript. Note that bindings for x/y/width/height are still evaluated sequentially, resulting in four calls to the platform window's setGeometry. This patch only introduces an imperative workaround for that issue. Change-Id: Ie9b0d3c39434740e50757ba7cff0385ae80f47f4 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>bb10
parent
292cb12e02
commit
bde42ffb8b
|
|
@ -218,8 +218,6 @@ public:
|
|||
void setBaseSize(const QSize &size);
|
||||
void setSizeIncrement(const QSize &size);
|
||||
|
||||
void setGeometry(int posx, int posy, int w, int h);
|
||||
void setGeometry(const QRect &rect);
|
||||
QRect geometry() const;
|
||||
|
||||
QMargins frameMargins() const;
|
||||
|
|
@ -300,6 +298,8 @@ public Q_SLOTS:
|
|||
void setY(int arg);
|
||||
void setWidth(int arg);
|
||||
void setHeight(int arg);
|
||||
void setGeometry(int posx, int posy, int w, int h);
|
||||
void setGeometry(const QRect &rect);
|
||||
|
||||
void setMinimumWidth(int w);
|
||||
void setMinimumHeight(int h);
|
||||
|
|
|
|||
Loading…
Reference in New Issue