mirror of
https://github.com/Cheviiot/Nivora.git
synced 2026-08-03 23:57:22 +00:00
fix(telegram-desktop): actually stop the shadow desktop-file self-install
The Exec-path and DBusActivatable matching from the previous two commits were treating the wrong cause: InstallLauncher() in tdesktop's specific_linux.cpp unconditionally wipes and rewrites its own ~/.local/share/applications/*.desktop and dbus-1/services/*.service on every launch, regardless of what the installed .desktop file says — unless the DESKTOPINTEGRATION env var is non-empty, which is upstream's documented opt-out for exactly this kind of repack. /usr/bin/telegram-desktop is now a wrapper script that sets DESKTOPINTEGRATION=1 before exec'ing the real binary, covering every launch path (desktop file, D-Bus activation, terminal). The .desktop file's Exec/TryExec/DBusActivatable revert to their original values since the field-matching theory they were built on didn't hold.
This commit is contained in:
@@ -1,8 +1,8 @@
|
||||
[Desktop Entry]
|
||||
Name=Telegram
|
||||
Comment=New era of messaging
|
||||
TryExec=/opt/telegram-desktop/Telegram
|
||||
Exec=/opt/telegram-desktop/Telegram -- %U
|
||||
TryExec=telegram-desktop
|
||||
Exec=telegram-desktop -- %U
|
||||
Icon=org.telegram.desktop
|
||||
Terminal=false
|
||||
StartupWMClass=TelegramDesktop
|
||||
@@ -11,12 +11,12 @@ Categories=Chat;Network;InstantMessaging;Qt;
|
||||
MimeType=x-scheme-handler/tg;x-scheme-handler/tonsite;
|
||||
Keywords=tg;chat;im;messaging;messenger;sms;tdesktop;
|
||||
Actions=quit;
|
||||
DBusActivatable=true
|
||||
DBusActivatable=false
|
||||
SingleMainWindow=true
|
||||
X-GNOME-UsesNotifications=true
|
||||
X-GNOME-SingleWindow=true
|
||||
|
||||
[Desktop Action quit]
|
||||
Exec=/opt/telegram-desktop/Telegram -quit
|
||||
Exec=telegram-desktop -quit
|
||||
Name=Quit Telegram
|
||||
Icon=application-exit
|
||||
|
||||
Reference in New Issue
Block a user