2
0
mirror of https://github.com/telegramdesktop/tdesktop synced 2025-08-31 14:38:15 +00:00

Use MACRO_TO_STRING from lib_base.

This commit is contained in:
John Preston
2020-01-17 14:15:40 +03:00
parent 4f71383557
commit afe34121af
4 changed files with 5 additions and 10 deletions

View File

@@ -549,9 +549,7 @@ void MainWindow::psFirstShow() {
if(snapName.isEmpty()) {
std::vector<QString> possibleDesktopFiles = {
#ifdef TDESKTOP_LAUNCHER_FILENAME
#define TDESKTOP_LAUNCHER_FILENAME_TO_STRING_HELPER(V) #V
#define TDESKTOP_LAUNCHER_FILENAME_TO_STRING(V) TDESKTOP_LAUNCHER_FILENAME_TO_STRING_HELPER(V)
TDESKTOP_LAUNCHER_FILENAME_TO_STRING(TDESKTOP_LAUNCHER_FILENAME),
MACRO_TO_STRING(TDESKTOP_LAUNCHER_FILENAME),
#endif // TDESKTOP_LAUNCHER_FILENAME
"telegramdesktop.desktop",
"Telegram.desktop"

View File

@@ -139,10 +139,8 @@ NotificationData::NotificationData(
_hints["category"] = qsl("im.received");
#ifdef TDESKTOP_LAUNCHER_FILENAME
#define TDESKTOP_LAUNCHER_FILENAME_TO_STRING_HELPER(V) #V
#define TDESKTOP_LAUNCHER_FILENAME_TO_STRING(V) TDESKTOP_LAUNCHER_FILENAME_TO_STRING_HELPER(V)
_hints["desktop-entry"] =
qsl(TDESKTOP_LAUNCHER_FILENAME_TO_STRING(TDESKTOP_LAUNCHER_FILENAME))
qsl(MACRO_TO_STRING(TDESKTOP_LAUNCHER_FILENAME))
.remove(QRegExp(qsl("\\.desktop$"), Qt::CaseInsensitive));
#else
_hints["desktop-entry"] = qsl("telegramdesktop");