Skip to content

Commit 6bdead2

Browse files
authored
Improved functioning (#6739)
* Radio3.0 v2.5.11: Improved functioning * sound150 v7.4.4: Improved functioning
1 parent da97731 commit 6bdead2

File tree

7 files changed

+51
-19
lines changed

7 files changed

+51
-19
lines changed

Radio3.0@claudiux/files/Radio3.0@claudiux/CHANGELOG.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
### v2.5.11~20250105
2+
* Improved functioning.
3+
14
### v2.5.10~20250101
25
* Better monitoring of files and directories.
36

Radio3.0@claudiux/files/Radio3.0@claudiux/applet.js

Lines changed: 28 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -825,9 +825,11 @@ var RadioPopupSubMenuMenuItem = class RadioPopupSubMenuMenuItem extends PopupSub
825825

826826
let topMenu = this._getTopMenu();
827827
if(!topMenu)
828-
return false;
828+
return false;
829829
if(!topMenu.actor)
830-
return false;
830+
return false;
831+
if(!topMenu.actor.get_layout_manager())
832+
return false;
831833
let [topMinHeight, topNaturalHeight] = topMenu.actor.get_preferred_height(-1);
832834
let topThemeNode = null;
833835

@@ -1295,9 +1297,6 @@ class WebRadioReceiverAndRecorder extends TextIconApplet {
12951297
// Connect signals:
12961298
this._connect_signals();
12971299

1298-
// Shortcuts:
1299-
this.onShortcutChanged();
1300-
13011300
//title_obj.watch('prop', function(value){
13021301
//this._on_mpv_title_changed();
13031302
////global.log('wow!',value);
@@ -1927,8 +1926,8 @@ class WebRadioReceiverAndRecorder extends TextIconApplet {
19271926

19281927
try {
19291928
if (this.titleMonitorId) {
1930-
//this.titleMonitor.cancel();
19311929
this.titleMonitor.disconnect(this.titleMonitorId);
1930+
this.titleMonitor.cancel();
19321931
this.titleMonitor = null;
19331932
this.titleMonitorId = null;
19341933
}
@@ -1942,8 +1941,8 @@ class WebRadioReceiverAndRecorder extends TextIconApplet {
19421941

19431942
try {
19441943
if (this.r30stopMonitorId != null) {
1945-
//this.r30stopMonitor.cancel();
19461944
this.r30stopMonitor.disconnect(this.r30stopMonitorId);
1945+
this.r30stopMonitor.cancel();
19471946
this.r30stopMonitor = null;
19481947
this.r30stopMonitorId = null;
19491948
}
@@ -1957,8 +1956,8 @@ class WebRadioReceiverAndRecorder extends TextIconApplet {
19571956

19581957
try {
19591958
if (this.r30previousMonitorId != null) {
1960-
//this.r30previousMonitor.cancel();
19611959
this.r30previousMonitor.disconnect(this.r30previousMonitorId);
1960+
this.r30previousMonitor.cancel();
19621961
this.r30previousMonitor = null;
19631962
this.r30previousMonitorId = null;
19641963
}
@@ -1972,8 +1971,8 @@ class WebRadioReceiverAndRecorder extends TextIconApplet {
19721971

19731972
try {
19741973
if (this.r30nextMonitorId != null) {
1975-
//this.r30nextMonitor.cancel();
19761974
this.r30nextMonitor.disconnect(this.r30nextMonitorId);
1975+
this.r30nextMonitor.cancel();
19771976
this.r30nextMonitor = null;
19781977
this.r30nextMonitorId = null;
19791978
}
@@ -2050,8 +2049,8 @@ class WebRadioReceiverAndRecorder extends TextIconApplet {
20502049

20512050
try {
20522051
if (this.recMonitorId) {
2053-
//this.recMonitor.cancel();
20542052
this.recMonitor.disconnect(this.recMonitorId);
2053+
this.recMonitor.cancel();
20552054
this.recMonitor = null;
20562055
this.recMonitorId = null;
20572056
}
@@ -2091,8 +2090,8 @@ class WebRadioReceiverAndRecorder extends TextIconApplet {
20912090

20922091
try {
20932092
if (this.jobsMonitorId) {
2094-
//this.jobsMonitor.cancel();
20952093
this.jobsMonitor.disconnect(this.jobsMonitorId);
2094+
this.jobsMonitor.cancel();
20962095
this.jobsMonitor = null;
20972096
this.jobsMonitorId = null;
20982097
}
@@ -4090,11 +4089,18 @@ class WebRadioReceiverAndRecorder extends TextIconApplet {
40904089
//~ logDebug("Nbr of categories: "+Object.keys(cws).length);
40914090
//~ logDebug("categories_with_stations: \n"+JSON.stringify(this.categories_with_stations, null, 4));
40924091

4093-
40944092
this._applet_context_menu.removeAll();
40954093
this.create_contextmenu_items();
40964094
this.setContextMenuVisibilities();
40974095

4096+
// Shortcuts:
4097+
let to = setTimeout( () => {
4098+
this.onShortcutChanged();
4099+
clearTimeout(to);
4100+
},
4101+
300
4102+
);
4103+
40984104
if (this.desklet_is_activated)
40994105
reloadExtension("AlbumArt3.0@claudiux", Type.DESKLET);
41004106
}
@@ -4474,8 +4480,14 @@ class WebRadioReceiverAndRecorder extends TextIconApplet {
44744480
on_option_menu_reload_this_applet_clicked() {
44754481
//log("on_option_menu_reload_this_applet_clicked");
44764482
this.stop_mpv(false);
4477-
// Reload this applet
4478-
reloadExtension(UUID, Type.APPLET);
4483+
this._applet_context_menu.close();
4484+
let to = setTimeout( () => {
4485+
// Reload this applet
4486+
reloadExtension(UUID, Type.APPLET);
4487+
clearTimeout(to);
4488+
},
4489+
300
4490+
);
44794491
}
44804492

44814493
on_switch_on_last_station_at_start_up() {
@@ -5163,6 +5175,8 @@ class WebRadioReceiverAndRecorder extends TextIconApplet {
51635175
this.context_menu_item_showLogo._switch.setToggleState(this.show_favicon);
51645176
if (this.context_menu_item_showDesklet) {
51655177
this.context_menu_item_showDesklet.actor.visible = true;
5178+
if (!this._is_desklet_activated())
5179+
this.show_desklet = false;
51665180
this.context_menu_item_showDesklet._switch.setToggleState(this.show_desklet);
51675181
//~ this.context_menu_item_showDesklet.actor.visible = this._is_desklet_activated();
51685182
}

Radio3.0@claudiux/files/Radio3.0@claudiux/desklet/AlbumArt3.0@claudiux/desklet.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,8 @@ class AlbumArtRadio30 extends Desklet.Desklet {
8686

8787
this.isLooping = false;
8888
this.dir_monitor_loop_is_active = false;
89+
this.dir_monitor.cancel();
90+
this.dir_monitor = null;
8991
}
9092

9193
_scan_dir(dir) {

Radio3.0@claudiux/files/Radio3.0@claudiux/metadata.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"description": "The Ultimate Internet Radio Receiver & Recorder for Cinnamon",
33
"max-instances": 1,
4-
"version": "2.5.10",
4+
"version": "2.5.11",
55
"uuid": "Radio3.0@claudiux",
66
"name": "Radio3.0",
77
"author": "claudiux",

sound150@claudiux/files/sound150@claudiux/6.4/applet.js

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1920,7 +1920,6 @@ class Sound150Applet extends Applet.TextIconApplet {
19201920
this.menuManager = new PopupMenu.PopupMenuManager(this);
19211921
this.menu = new Applet.AppletPopupMenu(this, orientation);
19221922
this.menuManager.addMenu(this.menu);
1923-
this._setKeybinding();
19241923

19251924
this.set_applet_icon_symbolic_name("audio-x-generic");
19261925

@@ -2335,7 +2334,14 @@ class Sound150Applet extends Applet.TextIconApplet {
23352334
this._loopArtId = Mainloop.timeout_add_seconds(5, this.loopArt.bind(this));
23362335
//~ this.loopArt();
23372336

2338-
this.volume_near_icon()
2337+
this.volume_near_icon();
2338+
2339+
let to = setTimeout( () => {
2340+
this._setKeybinding();
2341+
clearTimeout(to);
2342+
},
2343+
300
2344+
);
23392345
}
23402346

23412347
on_applet_reloaded() {
@@ -3473,7 +3479,11 @@ class Sound150Applet extends Applet.TextIconApplet {
34733479
//~ this._applet_context_menu.close();
34743480
this.menu.close();
34753481
// Reload this applet
3476-
Extension.reloadExtension(UUID, Extension.Type.APPLET);
3482+
let to = setTimeout( () => {
3483+
Extension.reloadExtension(UUID, Extension.Type.APPLET);
3484+
clearTimeout(to);
3485+
},
3486+
300);
34773487
}
34783488

34793489
_onSystemSoundSettingsPressed() {

sound150@claudiux/files/sound150@claudiux/CHANGELOG.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
### v7.4.4~20250105
2+
* Improved functioning.
3+
14
### v7.4.3~20250104
25
* Fixes #6728: Corrects a regression in Cinnamon 6.2.
36

sound150@claudiux/files/sound150@claudiux/metadata.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
"max-instances": "1",
66
"description": "Enhanced sound applet",
77
"hide-configuration": false,
8-
"version": "7.4.3",
8+
"version": "7.4.4",
99
"cinnamon-version": [
1010
"2.8",
1111
"3.0",

0 commit comments

Comments
 (0)