New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
DNDtoggle - Initial release #2125
Conversation
apps/a_dndtoggle/a_dndtoggle.app.js
Outdated
// reload clocks with new theme, otherwise just wait for user to switch apps | ||
if (Bangle.CLOCK) load(global.__FILE__); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No need for this: we always call load()
anyway in the next line.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good point. Will change that.
switch (current) { | ||
case 0: | ||
bSettings.quiet = 2; | ||
Bangle.buzz(); | ||
setTimeout('Bangle.buzz();',500); | ||
break; | ||
case 1: | ||
bSettings.quiet = 0; | ||
Bangle.buzz(); | ||
break; | ||
case 2: | ||
bSettings.quiet = 0; | ||
Bangle.buzz(); | ||
break; | ||
default: | ||
bSettings.quiet = 0; | ||
Bangle.buzz(); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The last three cases are all the same, and we always buzz, so you could just replace it with
if (current === 0) {
bSettings.quiet = 2;
setTimeout('Bangle.buzz();',500);
} else {
bSettings.quiet = 0;
}
Bangle.buzz();
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is for future use. I will make the behavior configurable.
Hi! Sorry for the delay. For the icon, you just want this? So basically on a whilte background you want it black (as above) and on black, you want it white? But no other colors? Or you say "2 color" - was part of the inner meant to be filled? Becayse I don't think it is in the source image. I think in the image converter you want Try:
|
This shows a totally white icon in light mode and a totally black icon in dark mode. |
This shows a totally white icon in light mode and a totally black icon in dark mode. |
I pushed the change and tried to re-load the app. Maybe something is cached somewhere. |
You can just connect with https://www.espruino.com/ide/ and paste the code in on the left hand side? Best to do a |
It looks good when sending it through the ide. But the launcher icon doesn't look good though. |
Ahh - I think I see what's happened - you have made a Please can you just use the format that we do in the examples? https://github.com/espruino/BangleApps/tree/master/apps/_example_app So |
Argh. Awesome, thanks! I knew it must have been that simple. Works like a charm. Finally :) |
Great - thanks! |
The app itself seems to be working now as intended, but I am struggeling with the icon for the launcher.
Can you help me to find a conversion that works for Dark and Light mode? The icon is transparrent and basically 2 color. It always shows wrong - regardless of the settings I use in the image converter.