Use MetaWindow.get_frame_rect()
get_outer_rect() has been deprecated for a while, use the new function instead.
This commit is contained in:
parent
4f08bebbf0
commit
2b9645b268
@ -610,7 +610,7 @@ const Keyboard = new Lang.Class({
|
|||||||
|
|
||||||
_moveTemporarily: function () {
|
_moveTemporarily: function () {
|
||||||
let currentWindow = global.screen.get_display().focus_window;
|
let currentWindow = global.screen.get_display().focus_window;
|
||||||
let rect = currentWindow.get_outer_rect();
|
let rect = currentWindow.get_frame_rect();
|
||||||
|
|
||||||
let newX = rect.x;
|
let newX = rect.x;
|
||||||
let newY = 3 * this.actor.height / 2;
|
let newY = 3 * this.actor.height / 2;
|
||||||
|
@ -1019,7 +1019,7 @@ const Panel = new Lang.Class({
|
|||||||
if (!dragWindow)
|
if (!dragWindow)
|
||||||
return Clutter.EVENT_PROPAGATE;
|
return Clutter.EVENT_PROPAGATE;
|
||||||
|
|
||||||
let rect = dragWindow.get_outer_rect();
|
let rect = dragWindow.get_frame_rect();
|
||||||
let [stageX, stageY] = event.get_coords();
|
let [stageX, stageY] = event.get_coords();
|
||||||
|
|
||||||
let allowDrag = dragWindow.maximized_vertically &&
|
let allowDrag = dragWindow.maximized_vertically &&
|
||||||
|
@ -413,7 +413,7 @@ const TilePreview = new Lang.Class({
|
|||||||
y: monitor.y,
|
y: monitor.y,
|
||||||
width: monitor.width,
|
width: monitor.width,
|
||||||
height: monitor.height });
|
height: monitor.height });
|
||||||
let [, rect] = window.get_outer_rect().intersect(monitorRect);
|
let [, rect] = window.get_frame_rect().intersect(monitorRect);
|
||||||
this.actor.set_size(rect.width, rect.height);
|
this.actor.set_size(rect.width, rect.height);
|
||||||
this.actor.set_position(rect.x, rect.y);
|
this.actor.set_position(rect.x, rect.y);
|
||||||
this.actor.opacity = 0;
|
this.actor.opacity = 0;
|
||||||
|
@ -254,7 +254,7 @@ const WindowClone = new Lang.Class({
|
|||||||
},
|
},
|
||||||
|
|
||||||
_computeBoundingBox: function() {
|
_computeBoundingBox: function() {
|
||||||
let rect = this.metaWindow.get_outer_rect();
|
let rect = this.metaWindow.get_frame_rect();
|
||||||
|
|
||||||
this.actor.get_children().forEach(function (child) {
|
this.actor.get_children().forEach(function (child) {
|
||||||
let realWindow;
|
let realWindow;
|
||||||
@ -264,7 +264,7 @@ const WindowClone = new Lang.Class({
|
|||||||
realWindow = child.source;
|
realWindow = child.source;
|
||||||
|
|
||||||
let metaWindow = realWindow.meta_window;
|
let metaWindow = realWindow.meta_window;
|
||||||
rect = rect.union(metaWindow.get_outer_rect());
|
rect = rect.union(metaWindow.get_frame_rect());
|
||||||
}, this);
|
}, this);
|
||||||
|
|
||||||
// Convert from a MetaRectangle to a native JS object
|
// Convert from a MetaRectangle to a native JS object
|
||||||
|
@ -161,14 +161,14 @@ const WindowClone = new Lang.Class({
|
|||||||
|
|
||||||
_updateDialogPosition: function(realDialog, cloneDialog) {
|
_updateDialogPosition: function(realDialog, cloneDialog) {
|
||||||
let metaDialog = realDialog.meta_window;
|
let metaDialog = realDialog.meta_window;
|
||||||
let dialogRect = metaDialog.get_outer_rect();
|
let dialogRect = metaDialog.get_frame_rect();
|
||||||
let rect = this.metaWindow.get_outer_rect();
|
let rect = this.metaWindow.get_frame_rect();
|
||||||
|
|
||||||
cloneDialog.set_position(dialogRect.x - rect.x, dialogRect.y - rect.y);
|
cloneDialog.set_position(dialogRect.x - rect.x, dialogRect.y - rect.y);
|
||||||
},
|
},
|
||||||
|
|
||||||
_onPositionChanged: function() {
|
_onPositionChanged: function() {
|
||||||
let rect = this.metaWindow.get_outer_rect();
|
let rect = this.metaWindow.get_frame_rect();
|
||||||
this.actor.set_position(this.realWindow.x, this.realWindow.y);
|
this.actor.set_position(this.realWindow.x, this.realWindow.y);
|
||||||
},
|
},
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user