Skip to content

Commit afba855

Browse files
committed
data/: Add .desktop file
1 parent ca88645 commit afba855

3 files changed

Lines changed: 24 additions & 0 deletions

File tree

CMakeLists.txt

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -133,6 +133,9 @@ file(MAKE_DIRECTORY ${CMAKE_BINARY_DIR}/share/openlock)
133133
configure_file(config/blocklist.json ${CMAKE_BINARY_DIR}/share/openlock/blocklist.json COPYONLY)
134134
configure_file(config/default.openlock ${CMAKE_BINARY_DIR}/share/openlock/default.openlock COPYONLY)
135135

136+
# Desktop file
137+
set(DESKTOP_FILE ${PROJECT_NAME}.desktop)
138+
136139
# Install
137140
install(TARGETS openlock RUNTIME DESTINATION bin)
138141
install(FILES config/default.openlock DESTINATION share/openlock)
@@ -168,3 +171,5 @@ set(CPACK_PACKAGE_LICENSE "MPL-2.0")
168171
set(CPACK_GENERATOR "DEB;RPM")
169172
set(CPACK_DEBIAN_PACKAGE_DEPENDS "qt6-webengine (>= 6.2)")
170173
include(CPack)
174+
175+
add_subdirectory(data)

data/CMakeLists.txt

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# Configure .desktop file
2+
configure_file(${DESKTOP_FILE}.in ${CMAKE_CURRENT_BINARY_DIR}/${DESKTOP_FILE})
3+
4+
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${DESKTOP_FILE}
5+
DESTINATION ${CMAKE_INSTALL_FULL_DATADIR}/applications
6+
)

data/OpenLock.desktop.in

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
[Desktop Entry]
2+
Version=1.0
3+
Name=OpenLock Browser
4+
GenericName=OpenLock Web Browser
5+
Comment=Secure kiosk-mode web browser for exams
6+
Keywords=Internet;WWW;Browser;Web;Explorer;Kiosk;SEB;Exam;
7+
Type=Application
8+
Icon=web-browser
9+
#Icon=@CMAKE_INSTALL_FULL_DATADIR@/openlock/openlock.svg
10+
Exec=openlock %u
11+
Terminal=false
12+
Categories=Network;WebBrowser;
13+
MimeType=text/html;text/xml;application/xhtml+xml;x-scheme-handler/http;x-scheme-handler/https;

0 commit comments

Comments
 (0)