Skip to content
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

fix: special shortcut for Windows live notifications #5975

Open
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

8thony
Copy link
Contributor

@8thony 8thony commented Feb 22, 2025

Fixes #5954

Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

clang-tidy made some suggestions

@8thony
Copy link
Contributor Author

8thony commented Feb 22, 2025

@Nerixyz there might be a bug with pinning c2 to the taskbar.

Steps
  • Installed
  • Run (from installer or the direct exe file)
  • Pin to taskbar
  • Login / configure a live notification
  • Close and Reopen from taskbar
  • Get a live notification (the name will be "Chatterino" but a new Shortcut will be created in %appdata%\...)
  • Close and reopen from taskbar once more
  • Get a live notification (the name is now "Chatterino2" and on the taskbar c2 is a new separate "window")

-> Tested the Taskbar shortcut, and it don't include the AUMI

Questions:
Do we need to set the AUMI for the exe file as well? (I don't know how to do this, and if it solves the issue)
Should we change the name of the App here?
Should we include the AUMI in the Installer created shortcut at all?
Is this change becoming more painful and not much useful at all?

Copy link
Member

@pajlada pajlada left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We can just change all AUMI/AppNames to "Chatterino", feel free to do that in this PR - I'm assuming that should not break anything. Rather that be changed now than before we start creating shortcuts

Comment on lines +54 to +61
settings.append(this->createCheckBox(
"Create start menu shortcut (requires "
"restart)",
getSettings()->createShortcutForToasts,
"When enabled, a shortcut will be created inside your "
"start menu folder if needed by live notifications."
"\n(On portable mode, this is disabled by "
"default)"));
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can use SettingWidget here, which means you wouldn't have to update the createCheckBox implementation - see

SettingWidget::dropdown("Show blocked term automod messages",
s.showBlockedTermAutomodMessages)
->setTooltip("Show messages that are blocked by AutoMod for containing "
"a public blocked term in the current channel.")
->addTo(layout);
as a reference

@@ -526,6 +527,9 @@ class Settings
"/notifications/suppressInitialLive", false};

BoolSetting notificationToast = {"/notifications/enableToast", false};
BoolSetting createShortcutForToasts = {
"/notifications/createShortcutForToasts",
Modes::instance().isPortable ? false : true};
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

add a , at the end of the ternary, that way it formats a bit nicer, causing nicer diffs in the future if we have to edit it

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

WinToast needs a special shortcut
2 participants