Skip to content
Snippets Groups Projects
Commit 2bc2327e authored by Stepan Salenikovich's avatar Stepan Salenikovich Committed by Guillaume Roguez
Browse files

autostart: preserve last window state

Use the --restore-last-window-state option in the autostart
.desktop file in order to autostart the client in the same
state as when it was quit.

The use case is that if users log-out with their client in
a hidden state, when they log back in, it should still be
hidden.

Issue: #78993
Change-Id: I43e5c27e14749dde9cc851f29560f88263d6c9a8
parent 593ddf5f
No related branches found
No related tags found
No related merge requests found
...@@ -337,6 +337,12 @@ CONFIGURE_FILE ( ...@@ -337,6 +337,12 @@ CONFIGURE_FILE (
"${PROJECT_BINARY_DIR}/gnome-ring.desktop" "${PROJECT_BINARY_DIR}/gnome-ring.desktop"
) )
# generate .desktop file for autostart
CONFIGURE_FILE (
"${PROJECT_SOURCE_DIR}/gnome-ring.desktop.autostart.in"
"${PROJECT_BINARY_DIR}/gnome-ring.desktop.autostart"
)
INSTALL(TARGETS gnome-ring INSTALL(TARGETS gnome-ring
RUNTIME DESTINATION bin RUNTIME DESTINATION bin
) )
...@@ -348,7 +354,7 @@ INSTALL(FILES ${PROJECT_BINARY_DIR}/gnome-ring.desktop ...@@ -348,7 +354,7 @@ INSTALL(FILES ${PROJECT_BINARY_DIR}/gnome-ring.desktop
# install .desktop in the gnome-ring data dir, so that it can be copied to the # install .desktop in the gnome-ring data dir, so that it can be copied to the
# autostart dir by the client # autostart dir by the client
INSTALL(FILES ${PROJECT_BINARY_DIR}/gnome-ring.desktop INSTALL(FILES ${PROJECT_BINARY_DIR}/gnome-ring.desktop.autostart
DESTINATION DESTINATION
${CMAKE_INSTALL_PREFIX}/share/gnome-ring/ ${CMAKE_INSTALL_PREFIX}/share/gnome-ring/
PERMISSIONS PERMISSIONS
...@@ -356,6 +362,8 @@ INSTALL(FILES ${PROJECT_BINARY_DIR}/gnome-ring.desktop ...@@ -356,6 +362,8 @@ INSTALL(FILES ${PROJECT_BINARY_DIR}/gnome-ring.desktop
OWNER_WRITE OWNER_WRITE
OWNER_READ OWNER_READ
GROUP_READ GROUP_READ
RENAME
gnome-ring.desktop
) )
INSTALL(FILES pixmaps/ring.svg INSTALL(FILES pixmaps/ring.svg
......
[Desktop Entry]
Name=Ring
Comment=Ring is a secured and distributed communication software.
Exec=gnome-ring --restore-last-window-state
Icon=@RING_INSTALL_PREFIX@/share/icons/hicolor/scalable/apps/ring.svg
StartupNotify=true
Terminal=false
Type=Application
Categories=GNOME;GTK;Network;Telephony;
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment