From acbf8b438efe6f154952333a47f2465d2758e9dc Mon Sep 17 00:00:00 2001 From: Aleksey Samoilov Date: Sun, 8 Feb 2026 21:44:38 +0400 Subject: [PATCH 1/2] Adapat to new alocation API --- .../5.6/SU_messageTray.js | 14 +++++++------- .../applet.js | 18 +++++++++--------- .../files/cpufreq@mtwebster/panelMenu.js | 4 ++-- .../files/sticky@scollins/applet.js | 10 +++++----- .../files/window-list@sangorys/applet.js | 8 ++++---- .../window-list@zeripath.sdf-eu.org/applet.js | 8 ++++---- 6 files changed, 31 insertions(+), 31 deletions(-) diff --git a/SpicesUpdate@claudiux/files/SpicesUpdate@claudiux/5.6/SU_messageTray.js b/SpicesUpdate@claudiux/files/SpicesUpdate@claudiux/5.6/SU_messageTray.js index e2c6d54fc43..6f20068f6fd 100644 --- a/SpicesUpdate@claudiux/files/SpicesUpdate@claudiux/5.6/SU_messageTray.js +++ b/SpicesUpdate@claudiux/files/SpicesUpdate@claudiux/5.6/SU_messageTray.js @@ -853,7 +853,7 @@ Notification.prototype = { } }, - _bannerBoxAllocate: function(actor, box, flags) { + _bannerBoxAllocate: function(actor, box) { let availWidth = box.x2 - box.x1; let [titleMinW, titleNatW] = this._titleLabel.get_preferred_width(-1); @@ -889,9 +889,9 @@ Notification.prototype = { titleBox.y2 = titleNatH; } - this._titleLabel.allocate(titleBox, flags); + this._titleLabel.allocate(titleBox); if (this._inNotificationBin) { - this._timeLabel.allocate(timeBox, flags); + this._timeLabel.allocate(timeBox); } this._titleFitsInBannerMode = (titleNatW <= availWidth); @@ -921,7 +921,7 @@ Notification.prototype = { bannerBox.y1 = 0; bannerBox.y2 = titleNatH; } - this._bannerLabel.allocate(bannerBox, flags); + this._bannerLabel.allocate(bannerBox); // Make _bannerLabel visible if the entire notification // fits on one line, or if the notification is currently @@ -1085,9 +1085,9 @@ Source.prototype = { alloc.min_size = min; alloc.nat_size = nat; }, - _allocate: function(actor, box, flags) { + _allocate: function(actor, box) { // the iconBin should fill our entire box - this._iconBin.allocate(box, flags); + this._iconBin.allocate(box); let childBox = new Clutter.ActorBox(); @@ -1107,7 +1107,7 @@ Source.prototype = { childBox.y1 = box.y2 - naturalHeight; childBox.y2 = box.y2; - this._counterBin.allocate(childBox, flags); + this._counterBin.allocate(childBox); }, _setCount: function(count, visible) { diff --git a/cinnamon-multi-line-taskbar-applet/files/cinnamon-multi-line-taskbar-applet/applet.js b/cinnamon-multi-line-taskbar-applet/files/cinnamon-multi-line-taskbar-applet/applet.js index 0fe7c9906bd..75c8f455831 100644 --- a/cinnamon-multi-line-taskbar-applet/files/cinnamon-multi-line-taskbar-applet/applet.js +++ b/cinnamon-multi-line-taskbar-applet/files/cinnamon-multi-line-taskbar-applet/applet.js @@ -555,7 +555,7 @@ AppMenuButton.prototype = { alloc.natural_size = naturalSize; }, - _contentAllocate: function(actor, box, flags) { + _contentAllocate: function(actor, box) { let allocWidth = box.x2 - box.x1; let allocHeight = box.y2 - box.y1; let childBox = new Clutter.ActorBox(); @@ -574,7 +574,7 @@ AppMenuButton.prototype = { childBox.x1 = Math.max(0, allocWidth - naturalWidth); childBox.x2 = allocWidth; } - this._iconBox.allocate(childBox, flags); + this._iconBox.allocate(childBox); let iconWidth = this.iconSize; @@ -591,20 +591,20 @@ AppMenuButton.prototype = { childBox.x2 = allocWidth - Math.floor(iconWidth + 3); childBox.x1 = Math.max(0, childBox.x2 - naturalWidth); } - this._label.allocate(childBox, flags); + this._label.allocate(childBox); if (direction == Clutter.TextDirection.LTR) { childBox.x1 = Math.floor(iconWidth / 2) + this._label.width; childBox.x2 = childBox.x1 + this._spinner.actor.width; childBox.y1 = box.y1; childBox.y2 = box.y2 - 1; - this._spinner.actor.allocate(childBox, flags); + this._spinner.actor.allocate(childBox); } else { childBox.x1 = -this._spinner.actor.width; childBox.x2 = childBox.x1 + this._spinner.actor.width; childBox.y1 = box.y1; childBox.y2 = box.y2 - 1; - this._spinner.actor.allocate(childBox, flags); + this._spinner.actor.allocate(childBox); } }, @@ -1031,7 +1031,7 @@ try { } }, - _allocateBoxes: function(container, box, flags) { + _allocateBoxes: function(container, box) { _multirowtaskbarlog("MyApplet._allocateBoxes(" + container + ", " + box); let allocWidth = box.x2 - box.x1; let allocHeight = box.y2 - box.y1; @@ -1060,13 +1060,13 @@ try { childBox.x1 = 0; childBox.x2 = Math.min(allocWidth - rightNaturalWidth, leftNaturalWidth); } - this._leftBox.allocate(childBox, flags); + this._leftBox.allocate(childBox); childBox.x1 = Math.ceil(sideWidth); childBox.y1 = 0; childBox.x2 = childBox.x1 + centerWidth; childBox.y2 = allocHeight; - this._centerBox.allocate(childBox, flags); + this._centerBox.allocate(childBox); childBox.y1 = 0; childBox.y2 = allocHeight; @@ -1079,7 +1079,7 @@ try { rightNaturalWidth); childBox.x2 = allocWidth; } - this._rightBox.allocate(childBox, flags); + this._rightBox.allocate(childBox); } }; diff --git a/cpufreq@mtwebster/files/cpufreq@mtwebster/panelMenu.js b/cpufreq@mtwebster/files/cpufreq@mtwebster/panelMenu.js index 7195ffd6427..4d6aea84207 100644 --- a/cpufreq@mtwebster/files/cpufreq@mtwebster/panelMenu.js +++ b/cpufreq@mtwebster/files/cpufreq@mtwebster/panelMenu.js @@ -67,7 +67,7 @@ ButtonBox.prototype = { } }, - _allocate: function(actor, box, flags) { + _allocate: function(actor, box) { let children = actor.get_children(); if (children.length == 0) return; @@ -96,7 +96,7 @@ ButtonBox.prototype = { childBox.y2 = availHeight; } - child.allocate(childBox, flags); + child.allocate(childBox); }, } diff --git a/sticky@scollins/files/sticky@scollins/applet.js b/sticky@scollins/files/sticky@scollins/applet.js index bf71bf0a70b..facb38f2a45 100644 --- a/sticky@scollins/files/sticky@scollins/applet.js +++ b/sticky@scollins/files/sticky@scollins/applet.js @@ -506,14 +506,14 @@ Note.prototype = { switchTypeMenuItem.connect("activate", Lang.bind(this, this.switchType)); }, - allocate: function(actor, box, flags) { + allocate: function(actor, box) { let childBox = new Clutter.ActorBox(); childBox.x1 = box.x1; childBox.x2 = box.x2; childBox.y1 = box.y1; childBox.y2 = box.y2; - this.textBox.allocate(childBox, flags); + this.textBox.allocate(childBox); }, getPreferedHeight: function(actor, forWidth, alloc) { @@ -1072,7 +1072,7 @@ CheckListItem.prototype = { else this.entry.remove_style_pseudo_class("checked"); }, - allocate: function(actor, box, flags) { + allocate: function(actor, box) { let height = box.y2 - box.y1; let cbBox = new Clutter.ActorBox(); @@ -1103,8 +1103,8 @@ CheckListItem.prototype = { eBox.y2 = eBox.y1 + eHeight; } - this.checkBox.actor.allocate(cbBox, flags); - this.entry.allocate(eBox, flags); + this.checkBox.actor.allocate(cbBox); + this.entry.allocate(eBox); }, getPreferedHeight: function(actor, forWidth, alloc) { diff --git a/window-list@sangorys/files/window-list@sangorys/applet.js b/window-list@sangorys/files/window-list@sangorys/applet.js index 895f43f8951..52cabf36478 100644 --- a/window-list@sangorys/files/window-list@sangorys/applet.js +++ b/window-list@sangorys/files/window-list@sangorys/applet.js @@ -1069,7 +1069,7 @@ class AppMenuButton { } } - _allocate(actor, box, flags) { + _allocate(actor, box) { let allocWidth = box.x2 - box.x1; let allocHeight = box.y2 - box.y1; @@ -1101,7 +1101,7 @@ class AppMenuButton { childBox.x1 = box.x1 + Math.floor(Math.max(0, allocWidth - naturalWidth) / 2); childBox.x2 = Math.min(childBox.x1 + naturalWidth, box.x2); } - this._iconBox.allocate(childBox, flags); + this._iconBox.allocate(childBox); if (this.drawLabel) { [minWidth, minHeight, naturalWidth, naturalHeight] = this._label.get_preferred_size(); @@ -1118,7 +1118,7 @@ class AppMenuButton { childBox.x1 = box.x1; } - this._label.allocate(childBox, flags); + this._label.allocate(childBox); } if (!this.progressOverlay.visible) { @@ -1130,7 +1130,7 @@ class AppMenuButton { childBox.x2 = this.actor.width; childBox.y2 = this.actor.height; - this.progressOverlay.allocate(childBox, flags); + this.progressOverlay.allocate(childBox); let clip_width = Math.max((this.actor.width) * (this._progress / 100.0), 1.0); this.progressOverlay.set_clip(0, 0, clip_width, this.actor.height); diff --git a/window-list@zeripath.sdf-eu.org/files/window-list@zeripath.sdf-eu.org/applet.js b/window-list@zeripath.sdf-eu.org/files/window-list@zeripath.sdf-eu.org/applet.js index 1932bceed98..62ecbf349e1 100644 --- a/window-list@zeripath.sdf-eu.org/files/window-list@zeripath.sdf-eu.org/applet.js +++ b/window-list@zeripath.sdf-eu.org/files/window-list@zeripath.sdf-eu.org/applet.js @@ -684,7 +684,7 @@ class AppMenuButton { } } - _allocate(actor, box, flags) { + _allocate(actor, box) { let allocWidth = box.x2 - box.x1; let allocHeight = box.y2 - box.y1; @@ -710,7 +710,7 @@ class AppMenuButton { childBox.x1 = box.x1 + Math.floor(Math.max(0, allocWidth - naturalWidth) / 2); childBox.x2 = Math.min(childBox.x1 + naturalWidth, box.x2); } - this._iconBox.allocate(childBox, flags); + this._iconBox.allocate(childBox); if (this.labelVisible) { [minWidth, minHeight, naturalWidth, naturalHeight] = this._label.get_preferred_size(); @@ -727,7 +727,7 @@ class AppMenuButton { childBox.x1 = box.x1; } - this._label.allocate(childBox, flags); + this._label.allocate(childBox); } if (!this.progressOverlay.visible) { @@ -739,7 +739,7 @@ class AppMenuButton { childBox.x2 = this.actor.width; childBox.y2 = this.actor.height; - this.progressOverlay.allocate(childBox, flags); + this.progressOverlay.allocate(childBox); let clip_width = Math.max((this.actor.width) * (this._progress / 100.0), 1.0); this.progressOverlay.set_clip(0, 0, clip_width, this.actor.height); From 346c906c11c17a4854cf7d77182cb6f2a0db55ba Mon Sep 17 00:00:00 2001 From: Aleksey Samoilov Date: Mon, 9 Feb 2026 00:35:22 +0400 Subject: [PATCH 2/2] Don't change API in old versions --- .../SpicesUpdate@claudiux/5.6/SU_messageTray.js | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/SpicesUpdate@claudiux/files/SpicesUpdate@claudiux/5.6/SU_messageTray.js b/SpicesUpdate@claudiux/files/SpicesUpdate@claudiux/5.6/SU_messageTray.js index 6f20068f6fd..e2c6d54fc43 100644 --- a/SpicesUpdate@claudiux/files/SpicesUpdate@claudiux/5.6/SU_messageTray.js +++ b/SpicesUpdate@claudiux/files/SpicesUpdate@claudiux/5.6/SU_messageTray.js @@ -853,7 +853,7 @@ Notification.prototype = { } }, - _bannerBoxAllocate: function(actor, box) { + _bannerBoxAllocate: function(actor, box, flags) { let availWidth = box.x2 - box.x1; let [titleMinW, titleNatW] = this._titleLabel.get_preferred_width(-1); @@ -889,9 +889,9 @@ Notification.prototype = { titleBox.y2 = titleNatH; } - this._titleLabel.allocate(titleBox); + this._titleLabel.allocate(titleBox, flags); if (this._inNotificationBin) { - this._timeLabel.allocate(timeBox); + this._timeLabel.allocate(timeBox, flags); } this._titleFitsInBannerMode = (titleNatW <= availWidth); @@ -921,7 +921,7 @@ Notification.prototype = { bannerBox.y1 = 0; bannerBox.y2 = titleNatH; } - this._bannerLabel.allocate(bannerBox); + this._bannerLabel.allocate(bannerBox, flags); // Make _bannerLabel visible if the entire notification // fits on one line, or if the notification is currently @@ -1085,9 +1085,9 @@ Source.prototype = { alloc.min_size = min; alloc.nat_size = nat; }, - _allocate: function(actor, box) { + _allocate: function(actor, box, flags) { // the iconBin should fill our entire box - this._iconBin.allocate(box); + this._iconBin.allocate(box, flags); let childBox = new Clutter.ActorBox(); @@ -1107,7 +1107,7 @@ Source.prototype = { childBox.y1 = box.y2 - naturalHeight; childBox.y2 = box.y2; - this._counterBin.allocate(childBox); + this._counterBin.allocate(childBox, flags); }, _setCount: function(count, visible) {