mirror of
https://github.com/Chatterino/chatterino2.git
synced 2024-11-21 22:24:07 +01:00
Use Version singleton to set window title
This commit is contained in:
parent
9c59efb985
commit
ddcce73111
1 changed files with 1 additions and 19 deletions
|
@ -363,30 +363,12 @@ void Window::addMenuBar()
|
|||
[=] { this->notebook_->selectPreviousTab(); });
|
||||
}
|
||||
|
||||
#define UGLYMACROHACK1(s) #s
|
||||
#define UGLYMACROHACK(s) UGLYMACROHACK1(s)
|
||||
|
||||
void Window::onAccountSelected()
|
||||
{
|
||||
auto user = getApp()->accounts->twitch.getCurrent();
|
||||
|
||||
// update title
|
||||
QString title = "Chatterino ";
|
||||
if (Modes::getInstance().isNightly)
|
||||
{
|
||||
title += "Nightly ";
|
||||
}
|
||||
title += CHATTERINO_VERSION;
|
||||
|
||||
if (Modes::getInstance().isNightly)
|
||||
{
|
||||
#ifdef CHATTERINO_NIGHTLY_VERSION_STRING
|
||||
title +=
|
||||
QString(" (" UGLYMACROHACK(CHATTERINO_NIGHTLY_VERSION_STRING) ")");
|
||||
#endif
|
||||
}
|
||||
|
||||
this->setWindowTitle(title);
|
||||
this->setWindowTitle(Version::getInstance().getFullVersion());
|
||||
|
||||
// update user
|
||||
if (user->isAnon())
|
||||
|
|
Loading…
Reference in a new issue