Closed haselwarter closed 1 year ago
Working perfectly for me !
I'm running Firefox 83.0 and using Xfce4's settings daemon and tools to change my GTK theme. I used to have a similar problem when I was running an older version of Firefox and when I wasn't running an xsettings daemon.
Thank you @kajeli ! @haselwarter , please let us know if you're running Firefox 83.0 or later and still seeing the same problem.
I had the same problem on Mac OS with Firefox v84.0.2, had to restart as well.
I had the same problem on Mac OS with Firefox v84.0.2, had to restart as well.
I am having this problem in Firefox 89 on MacOS 11. The theme change goes crazy!
I'm having this problem on Firefox 90, MacOS 11
I guess it's related to this one. Window focus
event doesn't work for theme auto-changed in background. It should be additionally checked by interval
I experience the same issue in this environment:
OS: Kubuntu 21.04 x86_64 DE: Plasma 5.22.5 WM: KWin FF: 94.0 64-bit (non snap package)
If anyone is running Firefox 95 (or higher), please try out 1.4.0 and let me know if that fixes any issues you have with the "Change theme based on system theme" option.
Thanks!
UPD: It seems some other applications that supposed to match system theme are experiencing the same problem (Telegram, Element). So this behaviour might have something to do with my setup
Changing the system theme still doesn't make extension change FF theme (until restart) even though extension is functional: it does change FF theme to dark if I change daytime theme to dark regardless of the system theme.
The new permissions have been accepted on first prompt.
extension: 1.4.0 but for some reason it still states on settings page that it is 1.3.0
OS: Kubuntu 21.04 x86_64
DE: Plasma 5.22.5
WM: KWin
FF: 95.0 64-bit (non snap package)
Logs from extensions > debugging > inspect > console: run FF in light mode > switch system theme to dark > extension notices the change in theme but incorrectly perceives it as still being light
18:35:40.917 automaticDark DEBUG: DEBUG_MODE is enabled. common.js:39:21
18:35:41.320 Error: Please use $(ref:runtime.lastError). 7 00-init-apis.js:50
18:35:41.618 automaticDark DEBUG: Start setDefaultThemes common.js:363:17
18:35:41.689 automaticDark DEBUG: Start setStorage utils.js:57:17
18:35:41.692 Error: Please use $(ref:runtime.lastError). 00-init-apis.js:50
18:35:41.748 Unknown localization message sync failed
---------------------
invalid token: google icon-manager.js:80
18:35:41.778 Error: Please use $(ref:runtime.lastError). 00-init-apis.js:50
18:35:41.798 automaticDark DEBUG: Start changeThemeBasedOnChangeMode common.js:159:17
18:35:42.931 automaticDark DEBUG: 50 changeThemeBasedOnChangeMode - Mode is set to: system-theme common.js:166:25
18:35:42.931 automaticDark DEBUG: Start checkSysTheme common.js:310:17
18:35:42.931 automaticDark DEBUG: 90 checkSysTheme - User prefers light interface common.js:324:21
18:35:43.005 automaticDark DEBUG: Start enableTheme common.js:339:17
18:35:43.021 Error: Please use $(ref:runtime.lastError). 00-init-apis.js:50
18:35:43.035 automaticDark DEBUG: 100 enableTheme - Enabled theme firefox-compact-light@mozilla.org common.js:346:29
18:35:43.233 Error: Please use $(ref:runtime.lastError). 2 00-init-apis.js:50
18:35:48.037 automaticDark DEBUG: 10 - Window was focused. Attempt theme change. common.js:92:37
18:35:48.057 automaticDark DEBUG: Start changeThemeBasedOnChangeMode common.js:159:17
18:35:48.059 automaticDark DEBUG: 50 changeThemeBasedOnChangeMode - Mode is set to: system-theme common.js:166:25
18:35:48.060 automaticDark DEBUG: Start checkSysTheme common.js:310:17
18:35:48.060 automaticDark DEBUG: 90 checkSysTheme - User prefers light interface common.js:324:21
18:35:48.062 automaticDark DEBUG: Start enableTheme common.js:339:17
18:35:48.276 automaticDark DEBUG: 100 enableTheme - firefox-compact-light@mozilla.org is already enabled. common.js:351:29
18:35:48.306 Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. 0.js:1
18:35:48.570 Uncaught (in promise) Error: Could not establish connection. Receiving end does not exist.
w moz-extension://1e048cff-f7f0-451b-a010-bc2c114a3cbd/background/background_sa.js:1
background_sa.js:1:22496
18:35:49.634 Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. 0.js:1
18:35:50.845 Uncaught (in promise) Error: Could not establish connection. Receiving end does not exist.
w moz-extension://1e048cff-f7f0-451b-a010-bc2c114a3cbd/background/background_sa.js:1
background_sa.js:1:22496
18:35:51.320 Error: Please use $(ref:runtime.lastError). 70 00-init-apis.js:50
18:36:28.592 Uncaught (in promise) Error: Could not establish connection. Receiving end does not exist.
w moz-extension://1e048cff-f7f0-451b-a010-bc2c114a3cbd/background/background_sa.js:1
background_sa.js:1:22496
18:36:29.211 The Components object is deprecated. It will soon be removed. blank
18:36:29.342 Uncaught (in promise) Error: Could not establish connection. Receiving end does not exist.
w moz-extension://1e048cff-f7f0-451b-a010-bc2c114a3cbd/background/background_sa.js:1
background_sa.js:1:22496
18:36:29.974 The Web Console logging API (console.log, console.info, console.warn, console.error) has been disabled by a script on this page.
18:36:47.091 automaticDark DEBUG: 10 - Window was focused. Attempt theme change. common.js:92:37
18:36:47.106 automaticDark DEBUG: Start changeThemeBasedOnChangeMode common.js:159:17
18:36:47.113 automaticDark DEBUG: 50 changeThemeBasedOnChangeMode - Mode is set to: system-theme common.js:166:25
18:36:47.116 automaticDark DEBUG: Start checkSysTheme common.js:310:17
18:36:47.118 automaticDark DEBUG: 90 checkSysTheme - User prefers light interface common.js:324:21
18:36:47.125 automaticDark DEBUG: Start enableTheme common.js:339:17
18:36:47.227 automaticDark DEBUG: 100 enableTheme - firefox-compact-light@mozilla.org is already enabled. common.js:351:29
18:37:04.097 Uncaught (in promise) Error: Could not establish connection. Receiving end does not exist.
w moz-extension://1e048cff-f7f0-451b-a010-bc2c114a3cbd/background/background_sa.js:1
background_sa.js:1:22496
18:37:04.213 automaticDark DEBUG: DEBUG_MODE is enabled. common.js:39:21
18:37:04.215 automaticDark DEBUG: Changing logo to: day-mode options.js:129:25
18:37:04.225 automaticDark DEBUG: Changing options page theme to: day-mode options.js:157:25
18:37:04.231 Day time theme is the currentlyEnabledTheme. options.js:91:29
18:37:04.233 Night time theme is not the currentlyEnabledTheme. options.js:114:29
18:37:04.273 automaticDark DEBUG: Start checkTime common.js:275:17
18:37:04.274 automaticDark DEBUG: It is currently: 18:37. Conducting time check now... common.js:276:17
18:37:04.279 automaticDark DEBUG: Start checkTime common.js:275:17
18:37:04.280 automaticDark DEBUG: It is currently: 18:37. Conducting time check now... common.js:276:17
18:37:04.282 automaticDark DEBUG: Start createAlarm 2 common.js:181:17
18:37:04.288 automaticDark DEBUG: Start timeInBetween utils.js:10:17
18:37:04.289 automaticDark DEBUG: It is currently daytime utils.js:31:25
18:37:04.291 automaticDark DEBUG: Start timeInBetween utils.js:10:17
18:37:04.291 automaticDark DEBUG: It is currently daytime utils.js:31:25
18:37:04.293 automaticDark DEBUG: Start enableTheme 2 common.js:339:17
18:37:04.350 automaticDark DEBUG: 100 enableTheme - firefox-compact-light@mozilla.org is already enabled. common.js:351:29
18:37:04.354 automaticDark DEBUG: Start changeLogo options.js:122:17
18:37:04.356 automaticDark DEBUG: 100 enableTheme - firefox-compact-light@mozilla.org is already enabled. common.js:351:29
18:37:04.358 automaticDark DEBUG: Changing logo to: day-mode options.js:129:25
18:37:04.362 automaticDark DEBUG: Start changeLogo options.js:122:17
18:37:04.364 automaticDark DEBUG: Changing logo to: day-mode options.js:129:25
18:37:04.365 automaticDark DEBUG: Start changeLogo options.js:122:17
18:37:04.366 automaticDark DEBUG: Start changeOptionsPageTheme options.js:150:17
18:37:04.369 automaticDark DEBUG: Start changeLogo options.js:122:17
18:37:04.371 automaticDark DEBUG: Start changeOptionsPageTheme options.js:150:17
18:37:04.373 automaticDark DEBUG: Changing logo to: day-mode options.js:129:25
18:37:04.374 automaticDark DEBUG: Changing options page theme to: day-mode options.js:157:25
18:37:04.377 automaticDark DEBUG: Changing logo to: day-mode options.js:129:25
18:37:04.378 automaticDark DEBUG: Changing options page theme to: day-mode options.js:157:25
18:37:07.711 Uncaught (in promise) Error: Could not establish connection. Receiving end does not exist.
w moz-extension://1e048cff-f7f0-451b-a010-bc2c114a3cbd/background/background_sa.js:1
background_sa.js:1:22496
UPD: now logs with debug mode on
For the record, running an xsettings daemon as @kajeli mentioned does indeed solve the issue for me. I'm using sway and gsd-xsettings provided by gnome-setting-daemon.
Same issue on Windows with latest FF (108.0.1), even when not using this extension but only the "system theme".
Something seems to be broken in Firefox itself, isn't it?
Fixed with version 1.4.1 (https://github.com/skhzhang/time-based-themes/commit/95361c8e635b45b2f49fc661893cc74399f10970, https://github.com/skhzhang/time-based-themes/commit/c350c46ae3b56fc19b153319ada787e84d736281, https://github.com/skhzhang/time-based-themes/commit/c22df5863233328e846e21a1c2387474f181e7d7, https://github.com/skhzhang/time-based-themes/commit/97bd8d749befe24c230411baadab7b32d17bb8aa). Please open a new issue and reference this one if there are any issues. Thanks!
On Linux, changing the Gtk3 theme does not lead to a change in appearance until Firefox is closed and restarted.