--
You received this message because you are subscribed to the Google Groups "Chromium Extensions" group.
To unsubscribe from this group and stop receiving emails from it, send an email to chromium-extens...@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/chromium-extensions/7a1e24b2-9fb6-49db-86e5-0425b14455efn%40chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/chromium-extensions/CAAgdh1Lq4z%3DWdkMhKCuUKGH-y8AVhC6q%3DeTmoEH8SOxYoC78MA%40mail.gmail.com.
Dr. Sebastian Benz
Developer Programs Engineer
Google Germany GmbH
Erika-Mann-Straße 33
80636 München
Geschäftsführer: Paul Manicle, Liana Sebastian
Registergericht und -nummer: Hamburg, HRB 86891
Sitz der Gesellschaft: Hamburg
Diese E-Mail ist vertraulich. Falls Sie diese fälschlicherweise erhalten haben sollten, leiten Sie diese bitte nicht an jemand anderes weiter, löschen Sie alle Kopien und Anhänge davon und lassen Sie mich bitte wissen, dass die E-Mail an die falsche Person gesendet wurde.
This e-mail is confidential. If you received this communication by mistake, please don't forward it to anyone else, please erase all copies and attachments, and please let me know that it has gone to the wrong person.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/chromium-extensions/CANby7pZQ_RzdOqJc3qhw7kNOt59zTVPGatm4%3D0gpo2okBSNT1w%40mail.gmail.com.
Just use try/catch and check the error text.
It doesn't support multiple documents.
if it will, the API should behave the same……
Thank you both for answering so fast.
As far as I know, getting an error doesn't prevent the extension from running. So, it's not a big deal, but it's annoying.
All I wanted to see was the changing action icon. It seems like only Firefox has it in the manifest file.
To detect the color scheme change, I used CSS to change the color of the body of the offscreen. I was checking its color, but it made this error.
You said, don't call it the first thing. When can I? I have an init function and some listeners in the global scope of the background. The init gets the storage.local and then the offscreen.Should I put some kind of setTimeout(), like for a second, or just try/catch it?
It's not a big project. I and a few other people that I shared it with are using it. I don't think they even realized the icon changes color when you change your system settings. Who changes it frequently?
That's why just putting in a try/catch would be an easy solution if there are none.
All I wanted to see was the changing action icon. It seems like only Firefox has it in the manifest file.
To detect the color scheme change, I used CSS to change the color of the body of the offscreen.
it detects whether it's dark or not, but it doesn't trigger the listener.