diff --git a/AUTHORS b/AUTHORS deleted file mode 100644 index abb6e1f..0000000 --- a/AUTHORS +++ /dev/null @@ -1,10 +0,0 @@ -Upstream Authors: - LXQt team: http://lxqt.org - Razor team: http://razor-qt.org - -Copyright: - Copyright (c) 2010-2012 Razor team - Copyright (c) 2012-2017 LXQt team - -License: LGPL-2.1+ -The full text of the licenses can be found in the 'COPYING' file. diff --git a/CHANGELOG b/CHANGELOG deleted file mode 100644 index a7feecd..0000000 --- a/CHANGELOG +++ /dev/null @@ -1,505 +0,0 @@ - -lxqt-session-0.12.0 / 2017-10-21 -================================ - - * Set patch version - * lxqt-session: Unify arguments parsing - * Don't export github templates - * Add/Update Lithuanian language - * c'n'p bug - * add basic cli to lxqt-session - * lxqt-session: Provide reboot/powerOff methods - * Drops Qt5Core_VERSION_STRING - * lxqt-config-session: set Qt::AA_UseHighDpiPixmaps to true - * lxqt-leave: set Qt::AA_UseHighDpiPixmaps to true - * improved --version - * Added QCommandLineParser and basic cli interface to lxqt-conf-session - * Added default CMAKE_BUILD_TYPE and LXQT_SESSION_PATCH_VERSION - * String encoding (#103) - * Fixes a FTBFS in superbuild mode (#102) - * lxqt-leave: Fix "disabled items" key navigation - * Address "unused parameter" compiler warnings - * lxqt-leave: Redesign dialog for good key navigation - * Removed superfluous include(LXQtTranslateDesktop) - * fixed config/CMakeLists.txt - * Merged relevant parts of CMakeLists.txt.lxqt-common into CMakeLists.txt - * Rename CMakeLists.txt -> CMakeLists.txt.lxqt-common - * Add Basque translation of lxqt-leave and update Basque translation of lxqt-config-session - * leavedialog: Use "expected" tab order - * LeaveDialog: Accept enter key for action/cancel firing - * LeaveDialog: Use "override" keyword - * leavedialog: Don't trigger "cancel" on Enter - * LeaveDialog: Use correct method - * startlxqt: Consider $XDG_RUNTIME_DIR/bus for DBus - * Updated *_da.desktop files and removed *_da_DK.desktop files - * Bump year - * Update desktop entries and Replace fr_FR by fr - * Use the LXQtConfigVars module - * Fixed typo - * Remove cpack (#61) - * startlxqt: Consider LXQT_DEFAULT_OPENBOX_CONFIG - * startlxqt: Honor the pre-defined SAL_USE_VLCPLUGIN - * Replace lxqt-rc.xml with latest openbox version - * startlxqt: Consider pre-exising LXDE OB config also - * build: Revert @6d6d2bef54 - * build: Add xmessage as "dependency" - * Openbox: Fix informational message about adoption of rc.xml - * lxqt-rc.xml: Change default config install path - * startlxqt: Copy existing openbox config preferably - * Improves changed Openbox default path startup message (#51) - * Disable gtk+ 3 overlay scrollbars by default. - * Don't add XDG_DATA_HOME to XDG_DATA_DIRS (#47) - * Message about Openbox default path changed. - * Warning message about openbox settings path changed. - * startlxqt: Force XDG_CONFIG_DIRS to contain @LXQT_ETC_XDG_DIR@ - * Copy openbox defaults at session start. - * Rename openbox/rc.xml to openbox/lxqt-openbox-rc.xml - * Openbox aero snap using mouse wheel over title bar. - * Settings Openbox updated. - * Default key shortcuts added to lxqt-globalkeysd. - * CMakeLists: Use LXQT_GRAPHICS_DIR for graphics - * Add startlxqt man page - * Fixes #807 – Add XDG_CACHE_HOME definition - * startlxqt: optimization of XDG_DATA_DIRS - * corrected indentation - * startlxqt: Set proper prefix for XDG_DATA_DIRS - * Update Greek translation (el) Remove country variant from language code - * Rename LxQt to LXQt everywhere - * CMake: Adds Runtime and Devel install COMPONENTs - * Coding style changes - * Removes no added value comments - * Adds double quotes to everything that may break - * Use GNUINnstallDirs - * Updates the build system to use the Targets infrastructure - * Enable the "leave confirmation dialog" by default - * TryExec to detect proper installed lxqt-session - * Uniforms indentation - * Sets env variable XDG_CONFIG_DIRS - * Drops hardcoded /etc/xdg paths - * Set LibreOffice's plugin env var to kde4 - * config: auto-detect succesfully kwin on recent kwin versions - * Updated german translation, replaced Qt4 by Qt in all xsession/translations - * Adds an scalable start-here-lxqt icon - * use LXQt-specific menu file - * Renames some .desktop files - * Portuguese update for .desktop files - * - Unify naming for a unique lxqt. No more suffixes - * Make frost the default theme - * Defines XDG_DATA_HOME and XDG_DATA_DIRS environment variables - * Updates translations infrastructure - * Update the required minimum cmake version - * Clean up CMakeLists.txt and drop Qt 4 support - * Set environment variable GTK_CSD=0 to turn off the default client side decoration for gtk+ 3 programs. (This will not always work if a gtk+3 program explicitly sets a title bar and turns on CSD.) - * Add some more default values for Qt settings. - * Update default config file. - * Add Qt5 support. - * Support Qt5 platform plugin and add some more comments. - * Remove XDG_CURRENT_DESKTOP=Razor from environment variables. - * Set XDG_CURRENT_DESKTOP to LXQt - * remove dead template lines switch OnlyShowIn from Razor -> LXQt stringchanges LxQt -> LXQt - * Use LXQt as desktop name - * Add CPack rules for creating tarball - * Add session.conf and windowmanagers.conf. - * Change XDG_CURRENT_DESKTOP to Razor for now. (May rename to LxQt or something else in the future.) - * Export environment varialbe QT_PLATFORM_PLUGIN=lxqt to let all Qt programs load lxqt-qtplugin and apply lxqt settings. - * Support lxqt-session and add necessary xdg autostart desktop entry files. - * Run lxde-qt with XDG_CURRENT_DESKTOP=RAZOR - * Fix renaming bugs, replacing lxqt-qt with lxde-qt - * Finish the crazy razor=>lxqt renaming tasks. - * Rename dirs and replace razor with lxqt. Install lxqt.conf to /etc/xdg/lxqt and provide theme config. - * Properly set default wallpaper for pcmanfm-qt. Comment out openbox config handling in startlxde-qt since it's not needed. - * Remove custom openbox config file in desktop.conf temporarily until lxsession is fixed. - * Fix file paths, replacing razor with lxqt. * Remove Alt+F2 and Ctrl+Esc from openbox config file to avoid conflicts with lxqt-panel & lxqt-globalkeys. - * Add default configuration files for lxde-qt session. - -0.11.1 / 2017-01-01 -=================== - - * Release 0.11.1: Update changelog - * Adds an nullptr check when restarting a module (#90) - * Fixes a session logout crash (#88) - * Updated da.desktop files and removed da_DK.desktop files - * Moves FindUDev to the lxqt-build-tools repo - * Reworks X11 CMake libraries - * Removes all XCB stuff from CMake - * Update french desktop entries - * lxqt-config-session: Use localized comment - * Make CMakeLists.txt more uniform. - * Remove cpack (#83) - -0.11.0 / 2016-09-24 -=================== - - * Release 0.11.0: Add changelog - * lockscreenmanager: always listen to the session provider's lock signal (#79) - * Update Polish translation - * Add README.md - * lxqt-config-session: Warn about restart required when removing env variable - * Add Catalan translations - * lockscreenmanager: use categorized logger - * Make screen locking before power actions optional - * Add and Update Arabic Translations for Desktop Files - * lxqt-session: Replace qCInfo() by qCWarning() - * Adds an WITH_LIBUDEV CMake option (#74) - * lockscreenmanager: add more log messages - * Add logic to lock screen before system sleeps - * lxqt-session: Use QLoggingCategory for logging/debug - * lxqt-session: Use the base name to compare Wm's names - * build: Use external translations - * ts-files removal (#72) - * Use const references with the foreach iterator - * leave: ask or not for confirmation from main dialog - * Adjust config dialog's size on startup - * Make it compile using QT_USE_QSTRINGBUILDER - * Fix lxqt-leave tab order - * lxqt-session doesn't copy openbox defaults at session start. startlxqt from lxqt-common will copy it. - * fixup...centering & spacing - * leave: do not set maximum size as minimum size - * Use XdgDir to find default path. - * Openbox default settings removed. - * Load LXQt default settings for Openbox. - * UserLocations: An user entered empty string represents the default value - * lxqt-config-session: Adds tooltips to the User Directories edits - * lxqt-config-session: Replaces Locations by User Directories - * Bump year Fix used licenses. lxqt-session is LGPL only - * Re-arrange the buttons - * lxqt-leave: Reworks window flags - * lxqt-leave: Make all buttons of equal width - * lxqt-leave: Center the dialog relative to the screen - * lxqt-leave: Removes window border and makes it stay on top - * lxqt-leave: Make the icons bigger and improves button alignement - * Updated german translation. - * Fix realloc() usage Check malloc() call result against NULL - * Add HR translations - * lxqt-session: Update man pages and make session the overview - * Update italian translation - * Updated Russian translations Removed ru_RU files - * Makes the dependency on xdg-user-dirs-update explicit - * Fix ending session and stopping modules - * upd: lxqt-config-session_hu.ts del: lxt-config-session_hu_HU.ts - * Fix desktop file - * Make desktop files valid - * CMakeLists.txt: Add cmake minimum required version - -0.10.0 / 2015-10-31 -=================== - - * Fix license file - * Update translations - * Use AutostartUtils class - * Use QLatin1String when appropriate - * lxqt-config-session: Handle Basic Settings>Modules 'Restart Needed' trigger - * lxqt-config-session: Adds an 'Restarted Needed' trigger to Autostart page - * Adds a way to edit xdg user-dirs (Personal Files Locations) - * Install missing man pages - * ATTN: Set LIBUDEV_MONITOR to OFF by default - * Improve Session Restart Required info message - * Allow only one Leave Dialog instance - * lxqt-config-session: Adjust Environment and Default Applications 'Restarted Needed' trigger - * lxqt-config-session: Adjust Basic Settings page 'Restarted Needed' trigger - * Fix Japanese translations. - * Fix typos in lxqt-config-session and lxqt-config manpages - * lxqt-session: CMakeLists.txt build fix for X11 module - * lxqt-session: CMakeLists.txt using link/include options from pkg-config modules (xcb, x11, libudev) - * Support automatically turning on numlock after login (X11 only). - * Fix some invalid categories and missed main categories - * Fix typos - * Fix typo in Greek (el) translation - * Rename LxQt to LXQt everywhere - * Update Greek translation Remove country variant from language code - * Update Greek (el) translation - * Updated german translations. - * Better title of leave dialog. Updated template for modified leave strings. - * Handles CMake policy CMP0063 - * Use the LXQtCompilerSettings CMake module - * Removes appending to CMAKE_MODULE_PATH - * CMake: Adds Runtime and Devel install COMPONENTs - * Removes already included LXQtTranslate - * Use CMAKE_AUTOUIC, drop qt5_wrap_ui() - * Removes unneeded include_directories() - * Use GNUInstallDirs - * lxqt-session: execute setxkbmap only if there is something to set - * Updates the build system to use the Targets infrastructure - * Updated italian translation, discarding it_IT - * config: fix "leave confirmation dialog" label - * Leave confimation: disable by default if not set - * Remove trailing whitespaces - * Replace LXDE-Qt with LXQt in desktop file - * Replace LXDE-Qt with LXQt - * Fix naming and links - * lxqt-leave: lockscreen button in dialog - * Fix italian translation of lxqt-hibernate.desktop - * Add man page to lxqt-leave - * More german translation - * Update lxqt-config-session_it.desktop - * Create lxqt-hibernate_it.desktop - * Hungarian translations update - * Change CMakeLists.txt for new translation - * Update Russian translation - * Use qt5_wrap_ui macro for CMake 2.8.11 - * lxqt-leave: rename folder lxqtleave to lxqt-leave - * lxqt-leave: show the gui by default - * lxqt-session: keyboard layout/settings reload after new input device added - * lxqt-leave: switch to QCommandLineParser to deal with options - * lxqt-leave: close leave dialog before power action - * lxqt-leave: fixed size of leave dialog - * Fix position of lxqt leave dialog and add .desktop - * Better C++11 detection - * Set C++11 to lxqt-session and add leave dialog - * Add KDevelop 4 format to .gitignore - * lxqtleave: *.dekstop translations cleanup - * Update Russian translation - * Create lxqt-suspend_it.desktop - * Moves lxqt-lockscreen_it.desktop to the proper place - * Create lxqt-lockscreen_it.desktop - * Moves lxqt-reboot_it.desktop to the proper place - * Create lxqt-reboot_it.desktop - * Create lxqt-shutdown_it.desktop - * Create lxqt-logout_it.desktop - * remove KF5/ prefix from includes - -0.9.0 / 2015-01-29 -================== - - * Adjust the positions of buttons in autostart and environment variable settings pages. - * Revert "don't show the lxqt-leave actions in the "other" section of the menu" - * don't show the lxqt-leave actions in the "other" section of the menu - * Portuguese update - * add lxqtleave to lxqt-session, refs #22 - * - Unify naming for a unique lxqt. No more suffixes - * Use the new LxQt::SingleApplication - * CMakeLists coding style reformatting - * CMakeLists.txt maintenance. - * Removes duplicated cmake_minimum_required() - * Add .gitignore - * Updates translations - * Use the new LXQtTranslate modules - * Linking to X11 again, need it for mouse pointer settings. - * Better window manager detection - * Add Russian translation - * Port to KWindowSystem - * Drop support for very old xdg-utils - * Remove unused startrazor binary - * Drop Qt4 support in code - * CMakeLists.txt cleanup, drop Qt4 support - -0.8.0 / 2014-10-10 -================== - - * Adapt to the translation infrastructure - * Add option to disable confirmation dialogs to leave session - * Fix incorrect waiting for system tray and fix lxde/lxde-qt bug #38 - Battery icon doesn't show. - * Cleanup for Qt5 ready includes - * Fix broken build with Qt4. - * Simplify qt5 support. * Use cmake 2.8.9 for qt4 and 2.8.11 for qt5. - * Initial Qt5 support. - * Use new LXQt header files. - * Minor string fixes - * Update LxQt -> LXQt - * Update LXQt Session Settings title - * Update the shipped xdg-tools - * Update WM selection dialog - -0.7.0 / 2014-05-07 -================== - - * Rename X-LxQt-Module to X-LXQt-Module and fix broken lxqt module configurations. - -0.6.99 / 2014-05-01 -=================== - - * Update manpages - * remove old translation templates remove translated icon names - * Avoid using alloca, which is not portable. - * Add AUTHORS and COPYING - * Add CPack rules for creating tarball - * Load xkb settings with setxkbmap when available. - * Improvements to .desktop file - * Stop setting font antialias and hinting with xrdb. (We use fontconfig now) - * Fix bugs in font configurations - * Make lxqt-config-session read/write the same keys as lxqt-sesion. - * Make names of config groups and keys more consistent. - * export LXQT_SESSION_CONFIG environment variable. - * Load font settings, including dpi and antialiasing Fix xrdb merging problems. - * Update copyright info. - * Load keyboard and mouse settings during session startup. - * Do not hard-code "XDG_MENU_PREFIX=lxqt-". - * Avoid using busy loop to wait for creation of the system tray. - * Avoid waiting for the window manager with a busy loop. - * Rename razor(qt) to lxqt and fix broken build. - * X-RAZOR changed to Razor in desktop files - * Qt version check added. Fix for: https://github.com/Razor-qt/razor-qt/issues/531#issuecomment-18248309 - * Theme change autodetection - * Allow commandline arguments for windowmanager setting - * Session: Prevent unresponsiveness during startup - * Fix moc warning - * Add autostart entry API into the library - * Prevent run razor-session without WM. - * Preventing run razor-session without WM. - * Some debug prints removed. Timeout for Systray to load increased to 1 minute. Module crash detection improved. - * Simplify and clean up AutoStartItem - * preliminary manpages primary for razorqt and usefully in venenux - * Translations updated - * first part of fixes based on Coverity Scan (code static analysis) - * Delete bad en_GB translations - * Update translations - * Fix dbus race condition during startup - * Minor fixes - * Translations updated - * Removed line num from TS files. - * Do not display blank entries if xfce creates invalid files - * Emit a signal when a module is started/stopped - * Translations - * Deleted old translation methods. - * Translations for librazorqt - * Don't log out if the WM quits - * Fix for when no item is selected - * Rudimentary implementation of start/stop ui - * Start and stop modules over dbus - * Return module configuration to basic settings page - * Split autostart config logic out of the model - * Fixed Issue #395 - * razor-session and razor-config-session now have a separate CMakeLists files. - * Updated .ts.src files - * Translation for razor-config-sesion - * Translation for razor-sesion 2 - * Translation for razor-sesion - * Updated ts.src files - * Removed dead code from the razormodman (HAL) - * Starting the razor-confupdate from the razor-session. - * Small fixes (typo and a wrong parameter) - * Handle cases where browser/terminal are unset - * add module names to includes and tidy up the coding style - * Ts.src files updated. - * Language name zh_CN.GB2312 braked cmake process. - * Translations updated - * Add a "wait for system tray" checkbox - * Split sessionconfigwindow and remove old module config - * Use XDG autostart for modules - * Improved autostart dialog - * Don't quit session after a crash limit is reached - * Razor-session doesn't do variable expansion, and prepends it literally Closes #280 - * add qupzilla to the browser list - * Adding auto start option of global shortcut daemon - * issue #260 - notification: implementation of session module config - * reworked config stuff. No more special config registering. All 'Settings' desktop files are displayed in razor-config (grouped) - * Make bundling xdg-utils optional - * Revert "Make bundling xdg-tools optional" - * Make bundling xdg-tools optional - * Add some missing headers - * Move autostart directory code to XdgDirs - * fix for infinite loop when there is no systray implementation loaded - * Improvement in the WmSelectDialog - * Transifex desktop: sr_BA.ts should be a local - * Transifex desktop: local translations - * Transifex desktop: cmake files - * Transifex desktop: Translations pulled - * Transifex desktop: Reomove translations from desktop.in - * Transifex desktop: desktop->desktop.in - * Update Tradidtional Chinese Translations - * fixed #218 Use /session.log instead of ~/.razor-session.log - * RazorApplication class implemented; all modules ported to this class - * Translations update - * Added support for the online translation service. www.transifex.net - * Wait until system tray becomes available - * Update razorqt-session/translations/razor-session_it_IT.ts - * Serbian translation files - * Serbian translations (2 variants) - * Greek translation by iosifidis - * Added danish translations - * Make xdg scripts use bash - * X-RAZOR -> Razor for autostart - * Russian translation - * RAZOR -> X-RAZOR - * Razor-session: Wait until the WM loads - * Razor-session: Wait until the WM loads - * fix #169: italian translation - * add razor-policykit-agent into config - * prevent the forever autorestart of still-crashing-app in the session. The count of crashes is limited now. - * Relicense - * XdgAutoStart rewriten (lgpl2+) - * Fix gmail.ru -> gmail.com - * menus are adopted to the new backends; old code removed; check for running razor-session to allow/disallow "logout" item - * Sawfish DE - * Czech translations (cs_CZ) Desktop files - * Replace old autostart - * Make XDG autostart fully editable - * Update german [de] translation - * Add settings page to view and toggle XDG autostart entries - * fixed #138: system settings icons - * SVK translation finalized - * Replaces return"" by return QString() - * License audit - * License audit - * Add Chinese(simplified) translation files. - * HU translation by Kristóf Kiszel - * Initial spanish translation - * Add detection of Xfwm4 - * Add Slovak (sk) translation - * Adds newline to the end of .desktop files - * Fixes typo - * Czech translations (cs_CZ) - * huge refactoring of the libraries build organization - * show icons in the config tools - * Razor-session: Added startrazor script (cmake & deb) - * Razor-session: Added startrazor script - * GPL->LGPL where I'm the author - * config: remove toolbars - * Plugins translations - * Russian translation for razorqt-session - * Translation for session - * window manager detection is shared in session and its config tool - * Razor-session: Improved WM handling. * If WM already running we not start new one. * If is a first start we show WM select dialog. - * session: new argument -w windowmanager - * Polish translation part X - * Garbage in the code. - * Fix: Desktop Menu Specification category must be X-RAZOR. - * Russian translations - * better implementation of razor- menu discovering regarding the XDG standards - * removed unneeded parts after new config gui - * Added razor-application.menu - * New design of the razor-config-session - * fixed desktop files - * fix donfig desktp files install for rpm - * issue #37 - settings restore works - * homepage updated + auto replacement script - * show only in RAZOR; close/undo changes actions - * issue #37 config list widgets: no dnd, no editation - * config tools are registered in config center; desktop file for CC - * "pause" session for a while until all razor modules are set up and running - * Fixed incorrect incude - * session config: missing actions - * initial version of "session config". In progress. - * XDG-files are splitted into qtxdg library. - * implementation of issue #19: environment variables for razor-session - * The project uses RazorTheme. All except the desktop, switched to RazorSettings. - * initial support for screensaver/screen locking - * Fixed multithreaded building. Thanks Gustavo. - * fix for install 64bit - * install custom xdg-tools into lib directory (LSB requires it) - * set default razor icon for all apps - * our own (temporary) xdg scripts to handle mime/files directly - * copyrights - * removed obsolete/generated files - * XDG autostart for session; session cleanups - * fixed logout calls; ask for confirmation on power management calls - * Allow to call logout over DBus; removed unneeded file - * typo fixes - * allow more sessions for KDM/GDM. razor-session gets optional argument -c for session config file specification - * better logging for session logout - * session: logout from panel works now; splashscreen removed; internals rearranged to be smaller - * logout from openbox works now. Need review - * session simplified; session autostart user apps; qprocesses termination instead of bruteforce killing - * session's splash dialog is back... - * fixed processes restarting in session - * forgotten paths - * configuration reworked (may require to drop ~/.razor); plugins code split; new plugin: spacer - * - * debug outputs to help finding the session xorg resource consuming issue - * src formatted with astyle -A1 - * settings refactored a bit: SHARE_DIR dependen on th CMAKE_INSTALL_PREFIX is defined for the compilation phase (it allows to have more razors installed eg. for development); SHARE_DIR is searched in the startup too; optimized cfg file access (1x vs. 4x as before for every file); redundant conversions merged into Razorsettings; usage of QSettings to read the settings (it does the error handling for us). - * fixed cmake stuff (debug,lib location,do not install .svn,make uninstall,etc.); fixes for qss skinning - * - * - * - * diff --git a/CMakeLists.txt b/CMakeLists.txt deleted file mode 100644 index 3cd4112..0000000 --- a/CMakeLists.txt +++ /dev/null @@ -1,78 +0,0 @@ -cmake_minimum_required(VERSION 3.0.2 FATAL_ERROR) - -project(lxqt-session) - -list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake") - -include(GNUInstallDirs) - -set(CMAKE_AUTOMOC ON) -set(CMAKE_AUTOUIC ON) -set(CMAKE_INCLUDE_CURRENT_DIR ON) -set(CMAKE_POSITION_INDEPENDENT_CODE ON) - -option(UPDATE_TRANSLATIONS "Update source translation translations/*.ts files" OFF) -option(WITH_LIBUDEV "Build with libudev support" ON) - -find_package(X11 REQUIRED) - -find_package(Qt5DBus REQUIRED) -find_package(Qt5LinguistTools REQUIRED) -find_package(Qt5Widgets REQUIRED) -find_package(Qt5X11Extras REQUIRED) -message(STATUS "Building with Qt${Qt5Core_VERSION}") - -find_package(KF5WindowSystem REQUIRED) - -find_package(lxqt REQUIRED) - -# Please don't move, must be after lxqt -find_package(XdgUserDirs REQUIRED) - -if(NOT CMAKE_BUILD_TYPE) - set(CMAKE_BUILD_TYPE Release) -endif() - -# Patch Version -set(LXQT_SESSION_PATCH_VERSION 0) - -set(LXQT_SESSION_VERSION ${LXQT_MAJOR_VERSION}.${LXQT_MINOR_VERSION}.${LXQT_SESSION_PATCH_VERSION}) -add_definitions("-DLXQT_SESSION_VERSION=\"${LXQT_SESSION_VERSION}\"") - -include(LXQtCompilerSettings NO_POLICY_SCOPE) - -# Translations ********************************** -include(LXQtTranslate) - -add_subdirectory(lxqt-session) -add_subdirectory(lxqt-config-session) -add_subdirectory(lxqt-leave) - -# merged from lxqt-common -include(LXQtConfigVars) - -# startlxqt script -set(PREDEF_XDG_DATA_DIRS "$XDG_DATA_HOME") -if(NOT("${LXQT_DATA_DIR}" MATCHES "^/usr(/local)?/share$")) - set(PREDEF_XDG_DATA_DIRS "${PREDEF_XDG_DATA_DIRS}:${LXQT_DATA_DIR}") -endif() -set(PREDEF_XDG_DATA_DIRS "${PREDEF_XDG_DATA_DIRS}:/usr/local/share:/usr/share") -configure_file(startlxqt.in startlxqt @ONLY) -install(PROGRAMS - "${CMAKE_CURRENT_BINARY_DIR}/startlxqt" - DESTINATION "${CMAKE_INSTALL_BINDIR}" - COMPONENT Runtime -) -install(FILES - startlxqt.1 - DESTINATION "${CMAKE_INSTALL_MANDIR}/man1" - COMPONENT Runtime -) - -# default config files -add_subdirectory(config) -add_subdirectory(autostart) - -# xsession *.desktop file for display managers -add_subdirectory(xsession) - diff --git a/CMakeLists.txt.lxqt-common b/CMakeLists.txt.lxqt-common deleted file mode 100644 index 4415fc6..0000000 --- a/CMakeLists.txt.lxqt-common +++ /dev/null @@ -1,27 +0,0 @@ -include(LXQtTranslateDesktop) -include(LXQtConfigVars) - -# startlxqt script -set(PREDEF_XDG_DATA_DIRS "$XDG_DATA_HOME") -if(NOT("${LXQT_DATA_DIR}" MATCHES "^/usr(/local)?/share$")) - set(PREDEF_XDG_DATA_DIRS "${PREDEF_XDG_DATA_DIRS}:${LXQT_DATA_DIR}") -endif() -set(PREDEF_XDG_DATA_DIRS "${PREDEF_XDG_DATA_DIRS}:/usr/local/share:/usr/share") -configure_file(startlxqt.in startlxqt @ONLY) -install(PROGRAMS - "${CMAKE_CURRENT_BINARY_DIR}/startlxqt" - DESTINATION "${CMAKE_INSTALL_BINDIR}" - COMPONENT Runtime -) -install(FILES - startlxqt.1 - DESTINATION "${CMAKE_INSTALL_MANDIR}/man1" - COMPONENT Runtime -) - -# default config files -add_subdirectory(config) -add_subdirectory(autostart) - -# xsession *.desktop file for display managers -add_subdirectory(xsession) diff --git a/LICENSE b/LICENSE deleted file mode 100644 index 20fb9c7..0000000 --- a/LICENSE +++ /dev/null @@ -1,458 +0,0 @@ - GNU LESSER GENERAL PUBLIC LICENSE - Version 2.1, February 1999 - - Copyright (C) 1991, 1999 Free Software Foundation, Inc. - 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - -[This is the first released version of the Lesser GPL. It also counts - as the successor of the GNU Library Public License, version 2, hence - the version number 2.1.] - - Preamble - - The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -Licenses are intended to guarantee your freedom to share and change -free software--to make sure the software is free for all its users. - - This license, the Lesser General Public License, applies to some -specially designated software packages--typically libraries--of the -Free Software Foundation and other authors who decide to use it. You -can use it too, but we suggest you first think carefully about whether -this license or the ordinary General Public License is the better -strategy to use in any particular case, based on the explanations below. - - When we speak of free software, we are referring to freedom of use, -not price. Our General Public Licenses are designed to make sure that -you have the freedom to distribute copies of free software (and charge -for this service if you wish); that you receive source code or can get -it if you want it; that you can change the software and use pieces of -it in new free programs; and that you are informed that you can do -these things. - - To protect your rights, we need to make restrictions that forbid -distributors to deny you these rights or to ask you to surrender these -rights. These restrictions translate to certain responsibilities for -you if you distribute copies of the library or if you modify it. - - For example, if you distribute copies of the library, whether gratis -or for a fee, you must give the recipients all the rights that we gave -you. You must make sure that they, too, receive or can get the source -code. If you link other code with the library, you must provide -complete object files to the recipients, so that they can relink them -with the library after making changes to the library and recompiling -it. And you must show them these terms so they know their rights. - - We protect your rights with a two-step method: (1) we copyright the -library, and (2) we offer you this license, which gives you legal -permission to copy, distribute and/or modify the library. - - To protect each distributor, we want to make it very clear that -there is no warranty for the free library. Also, if the library is -modified by someone else and passed on, the recipients should know -that what they have is not the original version, so that the original -author's reputation will not be affected by problems that might be -introduced by others. - - Finally, software patents pose a constant threat to the existence of -any free program. We wish to make sure that a company cannot -effectively restrict the users of a free program by obtaining a -restrictive license from a patent holder. Therefore, we insist that -any patent license obtained for a version of the library must be -consistent with the full freedom of use specified in this license. - - Most GNU software, including some libraries, is covered by the -ordinary GNU General Public License. This license, the GNU Lesser -General Public License, applies to certain designated libraries, and -is quite different from the ordinary General Public License. We use -this license for certain libraries in order to permit linking those -libraries into non-free programs. - - When a program is linked with a library, whether statically or using -a shared library, the combination of the two is legally speaking a -combined work, a derivative of the original library. The ordinary -General Public License therefore permits such linking only if the -entire combination fits its criteria of freedom. The Lesser General -Public License permits more lax criteria for linking other code with -the library. - - We call this license the "Lesser" General Public License because it -does Less to protect the user's freedom than the ordinary General -Public License. It also provides other free software developers Less -of an advantage over competing non-free programs. These disadvantages -are the reason we use the ordinary General Public License for many -libraries. However, the Lesser license provides advantages in certain -special circumstances. - - For example, on rare occasions, there may be a special need to -encourage the widest possible use of a certain library, so that it becomes -a de-facto standard. To achieve this, non-free programs must be -allowed to use the library. A more frequent case is that a free -library does the same job as widely used non-free libraries. In this -case, there is little to gain by limiting the free library to free -software only, so we use the Lesser General Public License. - - In other cases, permission to use a particular library in non-free -programs enables a greater number of people to use a large body of -free software. For example, permission to use the GNU C Library in -non-free programs enables many more people to use the whole GNU -operating system, as well as its variant, the GNU/Linux operating -system. - - Although the Lesser General Public License is Less protective of the -users' freedom, it does ensure that the user of a program that is -linked with the Library has the freedom and the wherewithal to run -that program using a modified version of the Library. - - The precise terms and conditions for copying, distribution and -modification follow. Pay close attention to the difference between a -"work based on the library" and a "work that uses the library". The -former contains code derived from the library, whereas the latter must -be combined with the library in order to run. - - GNU LESSER GENERAL PUBLIC LICENSE - TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - - 0. This License Agreement applies to any software library or other -program which contains a notice placed by the copyright holder or -other authorized party saying it may be distributed under the terms of -this Lesser General Public License (also called "this License"). -Each licensee is addressed as "you". - - A "library" means a collection of software functions and/or data -prepared so as to be conveniently linked with application programs -(which use some of those functions and data) to form executables. - - The "Library", below, refers to any such software library or work -which has been distributed under these terms. A "work based on the -Library" means either the Library or any derivative work under -copyright law: that is to say, a work containing the Library or a -portion of it, either verbatim or with modifications and/or translated -straightforwardly into another language. (Hereinafter, translation is -included without limitation in the term "modification".) - - "Source code" for a work means the preferred form of the work for -making modifications to it. For a library, complete source code means -all the source code for all modules it contains, plus any associated -interface definition files, plus the scripts used to control compilation -and installation of the library. - - Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running a program using the Library is not restricted, and output from -such a program is covered only if its contents constitute a work based -on the Library (independent of the use of the Library in a tool for -writing it). Whether that is true depends on what the Library does -and what the program that uses the Library does. - - 1. You may copy and distribute verbatim copies of the Library's -complete source code as you receive it, in any medium, provided that -you conspicuously and appropriately publish on each copy an -appropriate copyright notice and disclaimer of warranty; keep intact -all the notices that refer to this License and to the absence of any -warranty; and distribute a copy of this License along with the -Library. - - You may charge a fee for the physical act of transferring a copy, -and you may at your option offer warranty protection in exchange for a -fee. - - 2. You may modify your copy or copies of the Library or any portion -of it, thus forming a work based on the Library, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - - a) The modified work must itself be a software library. - - b) You must cause the files modified to carry prominent notices - stating that you changed the files and the date of any change. - - c) You must cause the whole of the work to be licensed at no - charge to all third parties under the terms of this License. - - d) If a facility in the modified Library refers to a function or a - table of data to be supplied by an application program that uses - the facility, other than as an argument passed when the facility - is invoked, then you must make a good faith effort to ensure that, - in the event an application does not supply such function or - table, the facility still operates, and performs whatever part of - its purpose remains meaningful. - - (For example, a function in a library to compute square roots has - a purpose that is entirely well-defined independent of the - application. Therefore, Subsection 2d requires that any - application-supplied function or table used by this function must - be optional: if the application does not supply it, the square - root function must still compute square roots.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Library, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Library, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote -it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Library. - -In addition, mere aggregation of another work not based on the Library -with the Library (or with a work based on the Library) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - - 3. You may opt to apply the terms of the ordinary GNU General Public -License instead of this License to a given copy of the Library. To do -this, you must alter all the notices that refer to this License, so -that they refer to the ordinary GNU General Public License, version 2, -instead of to this License. (If a newer version than version 2 of the -ordinary GNU General Public License has appeared, then you can specify -that version instead if you wish.) Do not make any other change in -these notices. - - Once this change is made in a given copy, it is irreversible for -that copy, so the ordinary GNU General Public License applies to all -subsequent copies and derivative works made from that copy. - - This option is useful when you wish to copy part of the code of -the Library into a program that is not a library. - - 4. You may copy and distribute the Library (or a portion or -derivative of it, under Section 2) in object code or executable form -under the terms of Sections 1 and 2 above provided that you accompany -it with the complete corresponding machine-readable source code, which -must be distributed under the terms of Sections 1 and 2 above on a -medium customarily used for software interchange. - - If distribution of object code is made by offering access to copy -from a designated place, then offering equivalent access to copy the -source code from the same place satisfies the requirement to -distribute the source code, even though third parties are not -compelled to copy the source along with the object code. - - 5. A program that contains no derivative of any portion of the -Library, but is designed to work with the Library by being compiled or -linked with it, is called a "work that uses the Library". Such a -work, in isolation, is not a derivative work of the Library, and -therefore falls outside the scope of this License. - - However, linking a "work that uses the Library" with the Library -creates an executable that is a derivative of the Library (because it -contains portions of the Library), rather than a "work that uses the -library". The executable is therefore covered by this License. -Section 6 states terms for distribution of such executables. - - When a "work that uses the Library" uses material from a header file -that is part of the Library, the object code for the work may be a -derivative work of the Library even though the source code is not. -Whether this is true is especially significant if the work can be -linked without the Library, or if the work is itself a library. The -threshold for this to be true is not precisely defined by law. - - If such an object file uses only numerical parameters, data -structure layouts and accessors, and small macros and small inline -functions (ten lines or less in length), then the use of the object -file is unrestricted, regardless of whether it is legally a derivative -work. (Executables containing this object code plus portions of the -Library will still fall under Section 6.) - - Otherwise, if the work is a derivative of the Library, you may -distribute the object code for the work under the terms of Section 6. -Any executables containing that work also fall under Section 6, -whether or not they are linked directly with the Library itself. - - 6. As an exception to the Sections above, you may also combine or -link a "work that uses the Library" with the Library to produce a -work containing portions of the Library, and distribute that work -under terms of your choice, provided that the terms permit -modification of the work for the customer's own use and reverse -engineering for debugging such modifications. - - You must give prominent notice with each copy of the work that the -Library is used in it and that the Library and its use are covered by -this License. You must supply a copy of this License. If the work -during execution displays copyright notices, you must include the -copyright notice for the Library among them, as well as a reference -directing the user to the copy of this License. Also, you must do one -of these things: - - a) Accompany the work with the complete corresponding - machine-readable source code for the Library including whatever - changes were used in the work (which must be distributed under - Sections 1 and 2 above); and, if the work is an executable linked - with the Library, with the complete machine-readable "work that - uses the Library", as object code and/or source code, so that the - user can modify the Library and then relink to produce a modified - executable containing the modified Library. (It is understood - that the user who changes the contents of definitions files in the - Library will not necessarily be able to recompile the application - to use the modified definitions.) - - b) Use a suitable shared library mechanism for linking with the - Library. A suitable mechanism is one that (1) uses at run time a - copy of the library already present on the user's computer system, - rather than copying library functions into the executable, and (2) - will operate properly with a modified version of the library, if - the user installs one, as long as the modified version is - interface-compatible with the version that the work was made with. - - c) Accompany the work with a written offer, valid for at - least three years, to give the same user the materials - specified in Subsection 6a, above, for a charge no more - than the cost of performing this distribution. - - d) If distribution of the work is made by offering access to copy - from a designated place, offer equivalent access to copy the above - specified materials from the same place. - - e) Verify that the user has already received a copy of these - materials or that you have already sent this user a copy. - - For an executable, the required form of the "work that uses the -Library" must include any data and utility programs needed for -reproducing the executable from it. However, as a special exception, -the materials to be distributed need not include anything that is -normally distributed (in either source or binary form) with the major -components (compiler, kernel, and so on) of the operating system on -which the executable runs, unless that component itself accompanies -the executable. - - It may happen that this requirement contradicts the license -restrictions of other proprietary libraries that do not normally -accompany the operating system. Such a contradiction means you cannot -use both them and the Library together in an executable that you -distribute. - - 7. You may place library facilities that are a work based on the -Library side-by-side in a single library together with other library -facilities not covered by this License, and distribute such a combined -library, provided that the separate distribution of the work based on -the Library and of the other library facilities is otherwise -permitted, and provided that you do these two things: - - a) Accompany the combined library with a copy of the same work - based on the Library, uncombined with any other library - facilities. This must be distributed under the terms of the - Sections above. - - b) Give prominent notice with the combined library of the fact - that part of it is a work based on the Library, and explaining - where to find the accompanying uncombined form of the same work. - - 8. You may not copy, modify, sublicense, link with, or distribute -the Library except as expressly provided under this License. Any -attempt otherwise to copy, modify, sublicense, link with, or -distribute the Library is void, and will automatically terminate your -rights under this License. However, parties who have received copies, -or rights, from you under this License will not have their licenses -terminated so long as such parties remain in full compliance. - - 9. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Library or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Library (or any work based on the -Library), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Library or works based on it. - - 10. Each time you redistribute the Library (or any work based on the -Library), the recipient automatically receives a license from the -original licensor to copy, distribute, link with or modify the Library -subject to these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties with -this License. - - 11. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Library at all. For example, if a patent -license would not permit royalty-free redistribution of the Library by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Library. - -If any portion of this section is held invalid or unenforceable under any -particular circumstance, the balance of the section is intended to apply, -and the section as a whole is intended to apply in other circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - - 12. If the distribution and/or use of the Library is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Library under this License may add -an explicit geographical distribution limitation excluding those countries, -so that distribution is permitted only in or among countries not thus -excluded. In such case, this License incorporates the limitation as if -written in the body of this License. - - 13. The Free Software Foundation may publish revised and/or new -versions of the Lesser General Public License from time to time. -Such new versions will be similar in spirit to the present version, -but may differ in detail to address new problems or concerns. - -Each version is given a distinguishing version number. If the Library -specifies a version number of this License which applies to it and -"any later version", you have the option of following the terms and -conditions either of that version or of any later version published by -the Free Software Foundation. If the Library does not specify a -license version number, you may choose any version ever published by -the Free Software Foundation. - - 14. If you wish to incorporate parts of the Library into other free -programs whose distribution conditions are incompatible with these, -write to the author to ask for permission. For software which is -copyrighted by the Free Software Foundation, write to the Free -Software Foundation; we sometimes make exceptions for this. Our -decision will be guided by the two goals of preserving the free status -of all derivatives of our free software and of promoting the sharing -and reuse of software generally. - - NO WARRANTY - - 15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO -WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW. -EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR -OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY -KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE -IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE -LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME -THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN -WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY -AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU -FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR -CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE -LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING -RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A -FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF -SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH -DAMAGES. - - END OF TERMS AND CONDITIONS diff --git a/README.md b/README.md deleted file mode 100644 index d6a89c8..0000000 --- a/README.md +++ /dev/null @@ -1,75 +0,0 @@ -# lxqt-session - -## Overview - -### General - -Repository lxqt-session is providing tools to handle LXQt sessions. - -First of all there's session manager `lxqt-session`. The binary is launched right at the beginning of LXQt sessions and in turn responsible for launching and monitoring all other components constituting the sessions. - -GUI "LXQt Session Settings" (binary `lxqt-config-session`) is used to configure various settings affecting the session, e. g. which window manager to use or which applications to start automatically. - -Binary `lxqt-leave` deals with interrupting or terminating sessions. It comes with several options expressing the action they trigger, e. g. `--leave`, `--hibernate`, `--shutdown` or `--reboot`. - -### LXQt Modules - -Term "LXQt Modules" refers to a way to launch binaries at the beginning of LXQt sessions and to make sure these will be available all over the session. -Technically those binaries are basically launched according to the XDG [Autostart Specification](https://www.freedesktop.org/wiki/Specifications/autostart-spec/). But unlike binaries handled according to this specification only LXQt Modules are monitored all over the session and automatically relaunched should they exit unexpectedly. - -## Installation - -### Compiling source code - -Runtime dependencies are xdg-user-dirs and [liblxqt](https://github.com/lxde/liblxqt). -Additional build dependencies are CMake and optionally Git to pull latest VCS checkouts. The localization files were outsourced to repository [lxqt-l10n](https://github.com/lxde/lxqt-l10n) so the corresponding dependencies are needed, too. Please refer to this repository's `README.md` for further information. - -Code configuration is handled by CMake. CMake variable `CMAKE_INSTALL_PREFIX` has to be set to `/usr` on most operating systems. - -To build run `make`, to install `make install` which accepts variable `DESTDIR` as usual. - -### Binary packages - -Official binary packages are provided by all major Linux distributions like Arch Linux, Debian (as of Debian stretch), Fedora and openSUSE. Just use your package manager to search for string `lxqt-session`. - -## Configuration, Usage - -### LXQt Modules - -Basically these are launched by desktop entry files according to the [Autostart Specification](https://www.freedesktop.org/wiki/Specifications/autostart-spec/). An additional key `X-LXQt-Module=true` makes binary `lxqt-session` recognize the binary in question as an LXQt Module and treat as such. -Corresponding configuration can be handled by "LXQt Session Settings", see below. - -### LXQt Session Settings - -A GUI to tweak all kinds of settings affecting the session as a whole. - -![lxqt-config-session](lxqt-config-session.png) - -It can be launched from panel's main menu - Preferences - LXQt settings - Session Settings and is provided by "Configuration Center" (binary `lxqt-config`) of [lxqt-config](https://github.com/lxde/lxqt-config) as well. - -Notes on some settings: - -#### Basic Settings -Window Manager, LXQt Modules and some settings upon leaving the session. See screenshot. As for the LXQt Modules the checkbox at the left refers to launching the module at sessions' beginning, stopping and launching within running sessions works as well. - -#### Default Applications -Defines a default terminal emulator and web browser by setting environment variables `TERM` and `BROWSER`. -The usage of `TERM` is faulty in this context, see [lxqt #433](https://github.com/lxde/lxqt/issues/433). Usage of `BROWSER` is correct but not recognized by too many applications any longer. -All in all the configuration of default applications will probably be handled by a different approach one day like improving GUI "File Associations" of [lxqt-config](https://github.com/lxde/lxqt-config) so setting environment variables `TERM` and `BROWSER` with `lxqt-config-session` has actually to be discouraged. - -#### User Directories -This refers to defining directories in terms of the [xdg-user-dirs](https://www.freedesktop.org/wiki/Software/xdg-user-dirs/) concept. This is a specification to define a number of directories used for certain kinds of content like documents, audio or video files and to create those directories in each user's home directory in case they do not preexist. -This dialogue allows for setting custom directory names differing from those defined by the specification. - -#### Autostart -Applications to launch according to the [Autostart Specification](https://www.freedesktop.org/wiki/Specifications/autostart-spec/). -Term "LXQt Autostart" refers to applications launched in LXQt sessions only, "Global Autostart" to those launched in all kinds of session. The distinction is relying on keys `OnlyShowIn` and `NotShowIn` of the desktop entry files in use. -The underlying desktop entry files can be edited manually, buttons `Add`, `Edit` and `Delete` at the right of pane "Autostart" can serve as some rudimentary editor, too. - -#### Environment (Advanced) -Allows for setting arbitrary environment variables which will be available for all software running within LXQt sessions (so not only the components of LXQt itself). - -### lxqt-leave - -Desktop entry files providing the various invocations of the binary as depicted above are summed up in sub-menu "Leave" of the panel's main menu. -Item "Leave" opens a dialogue window to select from all actions which are available, all other topics trigger the action stated by their title. diff --git a/autostart/CMakeLists.txt b/autostart/CMakeLists.txt deleted file mode 100644 index 5fb270d..0000000 --- a/autostart/CMakeLists.txt +++ /dev/null @@ -1,17 +0,0 @@ -cmake_minimum_required(VERSION 3.0.2 FATAL_ERROR) - -file(GLOB DESKTOP_FILES_IN *.desktop.in) - -# Translations ********************************** -lxqt_translate_desktop(DESKTOP_FILES - SOURCES - ${DESKTOP_FILES_IN} -) -add_custom_target(lxqt_sesstion_autostart_desktop_files ALL DEPENDS ${DESKTOP_FILES}) -#************************************************ - -install(FILES - ${DESKTOP_FILES} - DESTINATION "${LXQT_ETC_XDG_DIR}/autostart" - COMPONENT Runtime -) diff --git a/autostart/lxqt-xscreensaver-autostart.desktop.in b/autostart/lxqt-xscreensaver-autostart.desktop.in deleted file mode 100644 index 199a759..0000000 --- a/autostart/lxqt-xscreensaver-autostart.desktop.in +++ /dev/null @@ -1,9 +0,0 @@ -[Desktop Entry] -Type=Application -Version=1.0 -Name=XScreenSaver -TryExec=xscreensaver -Exec=xscreensaver -no-splash -OnlyShowIn=LXQt; - -#TRANSLATIONS_DIR=translations diff --git a/autostart/translations/lxqt-xscreensaver-autostart_ar.desktop b/autostart/translations/lxqt-xscreensaver-autostart_ar.desktop deleted file mode 100644 index f118d67..0000000 --- a/autostart/translations/lxqt-xscreensaver-autostart_ar.desktop +++ /dev/null @@ -1,2 +0,0 @@ -# Translations -Name[ar]=حافظ الشَّاشة diff --git a/autostart/translations/lxqt-xscreensaver-autostart_cs.desktop b/autostart/translations/lxqt-xscreensaver-autostart_cs.desktop deleted file mode 100644 index 0b613dd..0000000 --- a/autostart/translations/lxqt-xscreensaver-autostart_cs.desktop +++ /dev/null @@ -1,2 +0,0 @@ -# Translations -Name[cs]=Šetřič obrazovky diff --git a/autostart/translations/lxqt-xscreensaver-autostart_cs_CZ.desktop b/autostart/translations/lxqt-xscreensaver-autostart_cs_CZ.desktop deleted file mode 100644 index 6faaf82..0000000 --- a/autostart/translations/lxqt-xscreensaver-autostart_cs_CZ.desktop +++ /dev/null @@ -1,2 +0,0 @@ -# Translations -Name[cs_CZ]=Šetřič obrazovky diff --git a/autostart/translations/lxqt-xscreensaver-autostart_da.desktop b/autostart/translations/lxqt-xscreensaver-autostart_da.desktop deleted file mode 100644 index 3977f00..0000000 --- a/autostart/translations/lxqt-xscreensaver-autostart_da.desktop +++ /dev/null @@ -1,2 +0,0 @@ -# Translations -Name[da]=Pauseskærm diff --git a/autostart/translations/lxqt-xscreensaver-autostart_de.desktop b/autostart/translations/lxqt-xscreensaver-autostart_de.desktop deleted file mode 100644 index d357c12..0000000 --- a/autostart/translations/lxqt-xscreensaver-autostart_de.desktop +++ /dev/null @@ -1,2 +0,0 @@ -# Translations -Name[de]=Bildschirmschoner diff --git a/autostart/translations/lxqt-xscreensaver-autostart_el.desktop b/autostart/translations/lxqt-xscreensaver-autostart_el.desktop deleted file mode 100644 index db70514..0000000 --- a/autostart/translations/lxqt-xscreensaver-autostart_el.desktop +++ /dev/null @@ -1,2 +0,0 @@ -# Translations -Name[el]=ΠροφύλαξηOθόνηςΧ diff --git a/autostart/translations/lxqt-xscreensaver-autostart_eo.desktop b/autostart/translations/lxqt-xscreensaver-autostart_eo.desktop deleted file mode 100644 index ff5188c..0000000 --- a/autostart/translations/lxqt-xscreensaver-autostart_eo.desktop +++ /dev/null @@ -1,2 +0,0 @@ -# Translations -Name[eo]=XEkranKurteno diff --git a/autostart/translations/lxqt-xscreensaver-autostart_es.desktop b/autostart/translations/lxqt-xscreensaver-autostart_es.desktop deleted file mode 100644 index 990c7ba..0000000 --- a/autostart/translations/lxqt-xscreensaver-autostart_es.desktop +++ /dev/null @@ -1,2 +0,0 @@ -# Translations -Name[es]=XScreenSaver diff --git a/autostart/translations/lxqt-xscreensaver-autostart_es_VE.desktop b/autostart/translations/lxqt-xscreensaver-autostart_es_VE.desktop deleted file mode 100644 index cf3ffbb..0000000 --- a/autostart/translations/lxqt-xscreensaver-autostart_es_VE.desktop +++ /dev/null @@ -1,2 +0,0 @@ -# Translations -Name[es_VE]=XScreenSaver diff --git a/autostart/translations/lxqt-xscreensaver-autostart_eu.desktop b/autostart/translations/lxqt-xscreensaver-autostart_eu.desktop deleted file mode 100644 index 1c27510..0000000 --- a/autostart/translations/lxqt-xscreensaver-autostart_eu.desktop +++ /dev/null @@ -1,2 +0,0 @@ -# Translations -Name[eu]=XScreenSaver diff --git a/autostart/translations/lxqt-xscreensaver-autostart_fi.desktop b/autostart/translations/lxqt-xscreensaver-autostart_fi.desktop deleted file mode 100644 index 9de2c06..0000000 --- a/autostart/translations/lxqt-xscreensaver-autostart_fi.desktop +++ /dev/null @@ -1,2 +0,0 @@ -# Translations -Name[fi]=XScreenSaver diff --git a/autostart/translations/lxqt-xscreensaver-autostart_fr.desktop b/autostart/translations/lxqt-xscreensaver-autostart_fr.desktop deleted file mode 100644 index a15c487..0000000 --- a/autostart/translations/lxqt-xscreensaver-autostart_fr.desktop +++ /dev/null @@ -1,2 +0,0 @@ -# Translations -Name[fr_FR]=XScreenSaver diff --git a/autostart/translations/lxqt-xscreensaver-autostart_hu.desktop b/autostart/translations/lxqt-xscreensaver-autostart_hu.desktop deleted file mode 100644 index 26b0d99..0000000 --- a/autostart/translations/lxqt-xscreensaver-autostart_hu.desktop +++ /dev/null @@ -1 +0,0 @@ -# Translations diff --git a/autostart/translations/lxqt-xscreensaver-autostart_ia.desktop b/autostart/translations/lxqt-xscreensaver-autostart_ia.desktop deleted file mode 100644 index 26b0d99..0000000 --- a/autostart/translations/lxqt-xscreensaver-autostart_ia.desktop +++ /dev/null @@ -1 +0,0 @@ -# Translations diff --git a/autostart/translations/lxqt-xscreensaver-autostart_id_ID.desktop b/autostart/translations/lxqt-xscreensaver-autostart_id_ID.desktop deleted file mode 100644 index d9e7d2e..0000000 --- a/autostart/translations/lxqt-xscreensaver-autostart_id_ID.desktop +++ /dev/null @@ -1,2 +0,0 @@ -# Translations -Name[id_ID]=XScreenSaver diff --git a/autostart/translations/lxqt-xscreensaver-autostart_it_IT.desktop b/autostart/translations/lxqt-xscreensaver-autostart_it_IT.desktop deleted file mode 100644 index 73eb838..0000000 --- a/autostart/translations/lxqt-xscreensaver-autostart_it_IT.desktop +++ /dev/null @@ -1,2 +0,0 @@ -# Translations -Name[it_IT]=XScreenSaver diff --git a/autostart/translations/lxqt-xscreensaver-autostart_ja.desktop b/autostart/translations/lxqt-xscreensaver-autostart_ja.desktop deleted file mode 100644 index 90c84a5..0000000 --- a/autostart/translations/lxqt-xscreensaver-autostart_ja.desktop +++ /dev/null @@ -1,2 +0,0 @@ -# Translations -Name[ja]=Xスクリーンセーバ diff --git a/autostart/translations/lxqt-xscreensaver-autostart_ko.desktop b/autostart/translations/lxqt-xscreensaver-autostart_ko.desktop deleted file mode 100644 index 26b0d99..0000000 --- a/autostart/translations/lxqt-xscreensaver-autostart_ko.desktop +++ /dev/null @@ -1 +0,0 @@ -# Translations diff --git a/autostart/translations/lxqt-xscreensaver-autostart_lt.desktop b/autostart/translations/lxqt-xscreensaver-autostart_lt.desktop deleted file mode 100644 index 6744cc9..0000000 --- a/autostart/translations/lxqt-xscreensaver-autostart_lt.desktop +++ /dev/null @@ -1,2 +0,0 @@ -# Translations -Name[lt]=XScreenSaver diff --git a/autostart/translations/lxqt-xscreensaver-autostart_nl.desktop b/autostart/translations/lxqt-xscreensaver-autostart_nl.desktop deleted file mode 100644 index a368b1c..0000000 --- a/autostart/translations/lxqt-xscreensaver-autostart_nl.desktop +++ /dev/null @@ -1,2 +0,0 @@ -# Translations -Name[nl]=X-schermbeveiliging diff --git a/autostart/translations/lxqt-xscreensaver-autostart_pl_PL.desktop b/autostart/translations/lxqt-xscreensaver-autostart_pl_PL.desktop deleted file mode 100644 index 51f0c85..0000000 --- a/autostart/translations/lxqt-xscreensaver-autostart_pl_PL.desktop +++ /dev/null @@ -1,2 +0,0 @@ -# Translations -Name[pl_PL]=XScreenSaver diff --git a/autostart/translations/lxqt-xscreensaver-autostart_pt.desktop b/autostart/translations/lxqt-xscreensaver-autostart_pt.desktop deleted file mode 100644 index 2bcf851..0000000 --- a/autostart/translations/lxqt-xscreensaver-autostart_pt.desktop +++ /dev/null @@ -1,2 +0,0 @@ -# Translations -Name[pt]=Proteção de ecrã diff --git a/autostart/translations/lxqt-xscreensaver-autostart_pt_BR.desktop b/autostart/translations/lxqt-xscreensaver-autostart_pt_BR.desktop deleted file mode 100644 index 482dd1d..0000000 --- a/autostart/translations/lxqt-xscreensaver-autostart_pt_BR.desktop +++ /dev/null @@ -1,2 +0,0 @@ -# Translations -Name[pt_BR]=XScreenSaver diff --git a/autostart/translations/lxqt-xscreensaver-autostart_ro_RO.desktop b/autostart/translations/lxqt-xscreensaver-autostart_ro_RO.desktop deleted file mode 100644 index 1349bc4..0000000 --- a/autostart/translations/lxqt-xscreensaver-autostart_ro_RO.desktop +++ /dev/null @@ -1,2 +0,0 @@ -# Translations -Name[ro_RO]=XScreenSaver diff --git a/autostart/translations/lxqt-xscreensaver-autostart_ru.desktop b/autostart/translations/lxqt-xscreensaver-autostart_ru.desktop deleted file mode 100644 index bffcef1..0000000 --- a/autostart/translations/lxqt-xscreensaver-autostart_ru.desktop +++ /dev/null @@ -1,2 +0,0 @@ -# Translations -Name[ru]=XэкранCпаситель diff --git a/autostart/translations/lxqt-xscreensaver-autostart_ru_RU.desktop b/autostart/translations/lxqt-xscreensaver-autostart_ru_RU.desktop deleted file mode 100644 index 789e9d7..0000000 --- a/autostart/translations/lxqt-xscreensaver-autostart_ru_RU.desktop +++ /dev/null @@ -1,2 +0,0 @@ -# Translations -Name[ru_RU]=XScreenSaver diff --git a/autostart/translations/lxqt-xscreensaver-autostart_sl.desktop b/autostart/translations/lxqt-xscreensaver-autostart_sl.desktop deleted file mode 100644 index 470b430..0000000 --- a/autostart/translations/lxqt-xscreensaver-autostart_sl.desktop +++ /dev/null @@ -1,2 +0,0 @@ -# Translations -Name[sl]=XScreenSaver diff --git a/autostart/translations/lxqt-xscreensaver-autostart_sr.desktop b/autostart/translations/lxqt-xscreensaver-autostart_sr.desktop deleted file mode 100644 index 694caf2..0000000 --- a/autostart/translations/lxqt-xscreensaver-autostart_sr.desktop +++ /dev/null @@ -1,2 +0,0 @@ -# Translations -Name[sr]=Икс-ЧуварЕкрана diff --git a/autostart/translations/lxqt-xscreensaver-autostart_sr@ijekavian.desktop b/autostart/translations/lxqt-xscreensaver-autostart_sr@ijekavian.desktop deleted file mode 100644 index ba7db07..0000000 --- a/autostart/translations/lxqt-xscreensaver-autostart_sr@ijekavian.desktop +++ /dev/null @@ -1 +0,0 @@ -Name[sr@ijekavian]=Икс-ЧуварЕкрана diff --git a/autostart/translations/lxqt-xscreensaver-autostart_sr@ijekavianlatin.desktop b/autostart/translations/lxqt-xscreensaver-autostart_sr@ijekavianlatin.desktop deleted file mode 100644 index adf75e0..0000000 --- a/autostart/translations/lxqt-xscreensaver-autostart_sr@ijekavianlatin.desktop +++ /dev/null @@ -1 +0,0 @@ -Name[sr@ijekavianlatin]=Iks-ČuvarEkrana diff --git a/autostart/translations/lxqt-xscreensaver-autostart_sr@latin.desktop b/autostart/translations/lxqt-xscreensaver-autostart_sr@latin.desktop deleted file mode 100644 index 6f0e4f0..0000000 --- a/autostart/translations/lxqt-xscreensaver-autostart_sr@latin.desktop +++ /dev/null @@ -1,2 +0,0 @@ -# Translations -Name[sr@latin]=Iks-ČuvarEkrana diff --git a/autostart/translations/lxqt-xscreensaver-autostart_th_TH.desktop b/autostart/translations/lxqt-xscreensaver-autostart_th_TH.desktop deleted file mode 100644 index d9f982a..0000000 --- a/autostart/translations/lxqt-xscreensaver-autostart_th_TH.desktop +++ /dev/null @@ -1,2 +0,0 @@ -# Translations -Name[th_TH]=โปรแกรมรักษาหน้าจอของX diff --git a/autostart/translations/lxqt-xscreensaver-autostart_tr.desktop b/autostart/translations/lxqt-xscreensaver-autostart_tr.desktop deleted file mode 100644 index abb0253..0000000 --- a/autostart/translations/lxqt-xscreensaver-autostart_tr.desktop +++ /dev/null @@ -1,2 +0,0 @@ -# Translations -Name[tr]=XScreenSaver diff --git a/autostart/translations/lxqt-xscreensaver-autostart_uk.desktop b/autostart/translations/lxqt-xscreensaver-autostart_uk.desktop deleted file mode 100644 index f491066..0000000 --- a/autostart/translations/lxqt-xscreensaver-autostart_uk.desktop +++ /dev/null @@ -1,2 +0,0 @@ -# Translations -Name[uk]=XScreenSaver diff --git a/autostart/translations/lxqt-xscreensaver-autostart_zh_CN.GB2312.desktop b/autostart/translations/lxqt-xscreensaver-autostart_zh_CN.GB2312.desktop deleted file mode 100644 index 26b0d99..0000000 --- a/autostart/translations/lxqt-xscreensaver-autostart_zh_CN.GB2312.desktop +++ /dev/null @@ -1 +0,0 @@ -# Translations diff --git a/autostart/translations/lxqt-xscreensaver-autostart_zh_CN.desktop b/autostart/translations/lxqt-xscreensaver-autostart_zh_CN.desktop deleted file mode 100644 index fc4c9e6..0000000 --- a/autostart/translations/lxqt-xscreensaver-autostart_zh_CN.desktop +++ /dev/null @@ -1,2 +0,0 @@ -# Translations -Name[zh_CN]=屏保 diff --git a/autostart/translations/lxqt-xscreensaver-autostart_zh_TW.desktop b/autostart/translations/lxqt-xscreensaver-autostart_zh_TW.desktop deleted file mode 100644 index 0eaf52a..0000000 --- a/autostart/translations/lxqt-xscreensaver-autostart_zh_TW.desktop +++ /dev/null @@ -1,2 +0,0 @@ -# Translations -Name[zh_TW]=螢幕保護程式 diff --git a/config/CMakeLists.txt b/config/CMakeLists.txt deleted file mode 100644 index caabdf2..0000000 --- a/config/CMakeLists.txt +++ /dev/null @@ -1,12 +0,0 @@ -# install default config files to /etc/xdg -install(FILES - lxqt.conf - session.conf - windowmanagers.conf - DESTINATION "${LXQT_ETC_XDG_DIR}/lxqt" - COMPONENT Runtime -) -install(DIRECTORY openbox - DESTINATION "${LXQT_ETC_XDG_DIR}" - COMPONENT Runtime -) diff --git a/config/lxqt.conf b/config/lxqt.conf deleted file mode 100644 index 1d48e56..0000000 --- a/config/lxqt.conf +++ /dev/null @@ -1,11 +0,0 @@ -[General] -theme=frost -icon_theme=oxygen -single_click_activate=false -tool_button_style=ToolButtonTextBesideIcon - -[Qt] -font="Sans,11,-1,5,50,0,0,0,0,0" -doubleClickInterval=400 -style=Fusion -wheelScrollLines=3 diff --git a/config/openbox/lxqt-rc.xml b/config/openbox/lxqt-rc.xml deleted file mode 100644 index 5c19f5e..0000000 --- a/config/openbox/lxqt-rc.xml +++ /dev/null @@ -1,744 +0,0 @@ - - - - - - - - 10 - 20 - - - - yes - - no - - yes - - no - - 200 - - no - - - - - Smart - -
yes
- - Primary - - 1 - -
- - - Onyx - NLIMC - - yes - yes - - sans - 10 - - bold - - normal - - - - sans - 10 - - bold - - normal - - - - sans - 9 - - normal - - normal - - - - sans - 9 - - normal - - normal - - - - sans - 9 - - bold - - normal - - - - sans - 9 - - bold - - normal - - - - - - - 2 - 1 - - - - 875 - - - - - yes - Nonpixel - - Center - - - - - 10 - - 10 - - - - - - - 0 - 0 - 0 - 0 - - - - TopLeft - - 0 - 0 - no - Above - - Vertical - - no - 300 - - 300 - - Middle - - - - - C-g - - - - leftno - - - rightno - - - upno - - - downno - - - leftno - - - rightno - - - upno - - - downno - - - 1 - - - 2 - - - 3 - - - 4 - - - - - - - - - - - - - - - - client-menu - - - - - - - - - - - - - - - - - - - - - - - - yesyes - - - - - - - - - - - - right - - - - - left - - - - - up - - - - - down - - - - - - - - 1 - - 500 - - 400 - - false - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - previous - - - next - - - previous - - - next - - - previous - - - next - - - - - - - - - - - - - - no - - - - - - - - - - - yes - - - - - - - - - - - - - - - - - - - - - - - - - client-menu - - - - - - top - - - - - - left - - - - - - right - - - - - - bottom - - - - - - client-menu - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - client-menu - - - - - client-menu - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - vertical - - - horizontal - - - - - - - - - - - - - - - - - previous - - - next - - - - previous - - - next - - - previous - - - next - - - - - - - - - - - - - - - - client-list-combined-menu - - - root-menu - - - - - - previous - - - next - - - previous - - - next - - - - - - - - - menu.xml - 200 - - no - - 100 - - 400 - - yes - - yes - - - - - - - -
diff --git a/config/session.conf b/config/session.conf deleted file mode 100644 index ded6aa8..0000000 --- a/config/session.conf +++ /dev/null @@ -1,24 +0,0 @@ -[General] -window_manager=openbox -leave_confirmation=true - -[Environment] -GTK_CSD=0 -GTK_OVERLAY_SCROLLING=0 - -[Mouse] -cursor_size=18 -cursor_theme=whiteglass -acc_factor=20 -acc_threshold=10 -left_handed=false - -[Keyboard] -delay=500 -interval=30 -beep=false - -[Font] -antialias=true -hinting=true -dpi=96 diff --git a/config/windowmanagers.conf b/config/windowmanagers.conf deleted file mode 100644 index 7545908..0000000 --- a/config/windowmanagers.conf +++ /dev/null @@ -1,26 +0,0 @@ -[KnownManagers] -openbox/Name=Openbox -openbox/Comment=Light-weight window manager - -kwin/Name=KWin -kwin/Comment=Window manager of the KDE Software Compilation - -kwin_x11/Name=KWin -kwin_x11/Comment=Window manager of the KDE Software Compilation - -metacity/Name=Metacity -metacity/Comment=Window manager of the GNOME desktop environment - -windowmaker/Name=Windowmaker -windowmaker/Comment=A classical lightweight window manager - -e16/Name=Enlightenement 16 - -fvwm2/Name=Fvwm2 -fvwm2/Comment=A classical lightweight window manager - -xfwm4/Name=Xfwm4 -xfwm4/Comment=A window manager for the Xfce desktop environment - -sawfish/Name=Sawfish -sawfish/Comment="A lightweight, flexible window manager" diff --git a/lxqt-config-session.png b/lxqt-config-session.png deleted file mode 100644 index bd9f41a..0000000 Binary files a/lxqt-config-session.png and /dev/null differ diff --git a/lxqt-config-session/CMakeLists.txt b/lxqt-config-session/CMakeLists.txt deleted file mode 100644 index 692de88..0000000 --- a/lxqt-config-session/CMakeLists.txt +++ /dev/null @@ -1,97 +0,0 @@ -project(lxqt-config-session) - - -set(lxqt-sessioncfg_HDRS - sessionconfigwindow.h - basicsettings.h - modulemodel.h - autostartpage.h - autostartmodel.h - autostartitem.h - autostartedit.h - autostartutils.h - defaultappspage.h - environmentpage.h - userlocationspage.h -) - -set(lxqt-sessioncfg_SRCS - main.cpp - sessionconfigwindow.cpp - basicsettings.cpp - modulemodel.cpp - autostartpage.cpp - autostartmodel.cpp - autostartitem.cpp - autostartedit.cpp - autostartutils.cpp - defaultappspage.cpp - environmentpage.cpp - userlocationspage.cpp - ../lxqt-session/src/windowmanager.cpp -) - -set(lxqt-sessioncfg_UI_FILES - basicsettings.ui - autostartpage.ui - autostartedit.ui - defaultappspage.ui - environmentpage.ui -) - -# Translations -lxqt_translate_ts(lxqt-sessioncfg_QM_FILES - UPDATE_TRANSLATIONS - ${UPDATE_TRANSLATIONS} - SOURCES - ${lxqt-sessioncfg_HDRS} - ${lxqt-sessioncfg_SRCS} - ${lxqt-sessioncfg_UI_FILES} - INSTALL_DIR - "${LXQT_TRANSLATIONS_DIR}/${PROJECT_NAME}" - PULL_TRANSLATIONS - ${PULL_TRANSLATIONS} - CLEAN_TRANSLATIONS - ${CLEAN_TRANSLATIONS} - TRANSLATIONS_REPO - ${TRANSLATIONS_REPO} - TRANSLATIONS_REFSPEC - ${TRANSLATIONS_REFSPEC} - REPO_SUBDIR - "lxqt-session/${PROJECT_NAME}" -) - -lxqt_app_translation_loader(lxqt-sessioncfg_QM_LOADER ${PROJECT_NAME}) -lxqt_translate_desktop(lxqt-sessioncfg_DESKTOP_FILES SOURCES lxqt-config-session.desktop.in) - -add_executable(lxqt-config-session - ${lxqt-sessioncfg_SRCS} - ${lxqt-sessioncfg_DESKTOP_FILES} - ${lxqt-sessioncfg_QM_FILES} - ${lxqt-sessioncfg_QM_LOADER}) - -target_link_libraries(lxqt-config-session - KF5::WindowSystem - Qt5::Widgets - Qt5::DBus - Qt5::X11Extras - lxqt -) - -INSTALL(TARGETS - lxqt-config-session - RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}" - COMPONENT Runtime -) - -install(FILES - ${lxqt-sessioncfg_DESKTOP_FILES} - DESTINATION - "${CMAKE_INSTALL_DATAROOTDIR}/applications" - COMPONENT Runtime -) -install(FILES - man/lxqt-config-session.1 - DESTINATION "${CMAKE_INSTALL_MANDIR}/man1" - COMPONENT Runtime -) diff --git a/lxqt-config-session/autostartedit.cpp b/lxqt-config-session/autostartedit.cpp deleted file mode 100644 index 7091844..0000000 --- a/lxqt-config-session/autostartedit.cpp +++ /dev/null @@ -1,67 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXQt - a lightweight, Qt based, desktop toolset - * http://razor-qt.org, http://lxde.org/ - * - * Copyright (C) 2011 Alec Moskvin - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - - * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#include - -#include "autostartedit.h" -#include "ui_autostartedit.h" - -AutoStartEdit::AutoStartEdit(QString name, QString command, bool needTray, QWidget *parent) : - QDialog(parent), - ui(new Ui::AutoStartEdit) -{ - ui->setupUi(this); - ui->nameEdit->setFocus(); - ui->nameEdit->setText(name); - ui->commandEdit->setText(command); - ui->trayCheckBox->setChecked(needTray); - connect(ui->browseButton, SIGNAL(clicked()), SLOT(browse())); -} - -QString AutoStartEdit::name() -{ - return ui->nameEdit->text(); -} - -QString AutoStartEdit::command() -{ - return ui->commandEdit->text(); -} - -bool AutoStartEdit::needTray() -{ - return ui->trayCheckBox->isChecked(); -} - -void AutoStartEdit::browse() -{ - QString filePath = QFileDialog::getOpenFileName(this, tr("Select Application"), "/usr/bin/"); - if (!filePath.isEmpty()) - ui->commandEdit->setText(filePath); -} - -AutoStartEdit::~AutoStartEdit() -{ - delete ui; -} diff --git a/lxqt-config-session/autostartedit.h b/lxqt-config-session/autostartedit.h deleted file mode 100644 index 13d207d..0000000 --- a/lxqt-config-session/autostartedit.h +++ /dev/null @@ -1,52 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXQt - a lightweight, Qt based, desktop toolset - * http://razor-qt.org, http://lxde.org/ - * - * Copyright (C) 2011 Alec Moskvin - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - - * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#ifndef AUTOSTARTEDIT_H -#define AUTOSTARTEDIT_H - -#include - -namespace Ui { -class AutoStartEdit; -} - -class AutoStartEdit : public QDialog -{ - Q_OBJECT - -public: - explicit AutoStartEdit(QString name, QString command, bool needTray, QWidget* parent = 0); - ~AutoStartEdit(); - QString name(); - QString command(); - bool needTray(); - -private slots: - void browse(); - -private: - Ui::AutoStartEdit *ui; -}; - -#endif // AUTOSTARTEDIT_H diff --git a/lxqt-config-session/autostartedit.ui b/lxqt-config-session/autostartedit.ui deleted file mode 100644 index 16f14f8..0000000 --- a/lxqt-config-session/autostartedit.ui +++ /dev/null @@ -1,105 +0,0 @@ - - - AutoStartEdit - - - - 0 - 0 - 296 - 118 - - - - Edit - - - - - - Name: - - - - - - - Search... - - - - - - - Qt::Horizontal - - - QDialogButtonBox::Cancel|QDialogButtonBox::Ok - - - - - - - - - - Command: - - - - - - - - - - Wait for system tray - - - - - - - nameEdit - commandEdit - trayCheckBox - buttonBox - browseButton - - - - - buttonBox - accepted() - AutoStartEdit - accept() - - - 254 - 96 - - - 157 - 102 - - - - - buttonBox - rejected() - AutoStartEdit - reject() - - - 322 - 96 - - - 286 - 102 - - - - - diff --git a/lxqt-config-session/autostartitem.cpp b/lxqt-config-session/autostartitem.cpp deleted file mode 100644 index f61be94..0000000 --- a/lxqt-config-session/autostartitem.cpp +++ /dev/null @@ -1,75 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXQt - a lightweight, Qt based, desktop toolset - * http://razor-qt.org, http://lxde.org/ - * - * Copyright (C) 2012 Alec Moskvin - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - - * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#include "autostartitem.h" -#include -#include -#include - -AutostartItem::AutostartItem() : - LXQt::AutostartEntry() -{ -} - -AutostartItem::AutostartItem(const XdgDesktopFile& systemFile) : - LXQt::AutostartEntry() -{ - mSystemFile = systemFile; - mSystem = true; -} - -void AutostartItem::setLocalFromFile(const XdgDesktopFile& file) -{ - mLocalFile = file; - mLocalState = StateExists; -} - -QMap AutostartItem::createItemMap() -{ - QMap items; - - XdgDesktopFileList systemList = XdgAutoStart::desktopFileList(XdgDirs::autostartDirs(), false); - foreach (const XdgDesktopFile& file, systemList) - { - QString name = QFileInfo(file.fileName()).fileName(); - items.insert(name, AutostartItem(file)); - } - - XdgDesktopFileList localList = XdgAutoStart::desktopFileList(QStringList(XdgDirs::autostartHome()), false); - foreach (const XdgDesktopFile& file, localList) - { - QString name = QFileInfo(file.fileName()).fileName(); - if (items.contains(name)) - { - items[name].setLocalFromFile(file); - } - else - { - AutostartItem item; - item.setLocalFromFile(file); - items.insert(name, item); - } - } - return items; -} diff --git a/lxqt-config-session/autostartitem.h b/lxqt-config-session/autostartitem.h deleted file mode 100644 index 78b336d..0000000 --- a/lxqt-config-session/autostartitem.h +++ /dev/null @@ -1,77 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXQt - a lightweight, Qt based, desktop toolset - * http://razor-qt.org, http://lxde.org/ - * - * Copyright (C) 2012 Alec Moskvin - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - - * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#ifndef AUTOSTARTITEM_H -#define AUTOSTARTITEM_H - -#include - -/*! \brief The AutostartItem class provides an interface for staging configuration of individual -autostart items. All changes are made in memory until commit() is called. - - - "system" file refers to a read-only file in /etc/xdg/autostart (or a directory in $XDG_CONFIG_DIRS) - - "local" file refers to the file in user's ~/.config/autostart (or in $XDG_CONFIG_HOME/autostart) - -When a "local" file has the same name as the "system" file, the local one overrides it. This class -tries to ensure that the "local" file is deleted if it's the same as the "system" file. -*/ - -class AutostartItem : public LXQt::AutostartEntry -{ -public: - //! \brief Default constructor - AutostartItem(); - - /*! Creates an autostart item with a "system" file - * \param systemFile - */ - AutostartItem(const XdgDesktopFile& systemFile); - - //! Returns the "system" file - const XdgDesktopFile& systemfile() const { return mSystemFile; } - - /*! Sets the local version that exists on disk - * \param file the desktop file, must already exist in user's autostart directory - */ - void setLocalFromFile(const XdgDesktopFile &file); - - /*! Removes the "local" version of the file - * \return true if there is no "system" version left (i.e. the item was entirely deleted) - */ - bool removeLocal() { return LXQt::AutostartEntry::removeLocal(); } - - //! Returns true if both the "local" and "system" versions exist - bool overrides() const { return mSystem && isLocal(); } - - //! Returns true if the local version exists - bool isLocal() const { return LXQt::AutostartEntry::isLocal(); } - - //! Returns true if the local file does not exist on disk - bool isTransient() const { return mLocalState == StateTransient; } - - //! Creates a mapping of file name (a unique ID) to AutostartItem for the running system - static QMap createItemMap(); -}; - -#endif // AUTOSTARTITEM_H diff --git a/lxqt-config-session/autostartmodel.cpp b/lxqt-config-session/autostartmodel.cpp deleted file mode 100644 index 572ca42..0000000 --- a/lxqt-config-session/autostartmodel.cpp +++ /dev/null @@ -1,300 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXQt - The Lightweight Desktop Environment - * http://lxqt.org - * - * Copyright (C) 2011 Alec Moskvin - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - - * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#include -#include -#include - -#include "autostartmodel.h" -#include "autostartutils.h" - -AutoStartItemModel::AutoStartItemModel(QObject* parent) : - QAbstractItemModel(parent), - mItemMap(AutostartItem::createItemMap()), - mGlobalIndex(QAbstractItemModel::createIndex(0, 0)), - mLXQtIndex(QAbstractItemModel::createIndex(1, 0)) -{ - QMap::iterator iter; - for (iter = mItemMap.begin(); iter != mItemMap.end(); ++iter) - { - if (!AutostartUtils::isLXQtModule(iter.value().file())) - { - if (showOnlyInLXQt(iter.value().file())) - mLXQtItems.append(iter.key()); - else - mGlobalItems.append(iter.key()); - } - } -} - -AutoStartItemModel::~AutoStartItemModel() -{ -} - -/* - * All actual file operations are perfomed here when the window is closed. - */ -bool AutoStartItemModel::writeChanges() -{ - foreach (AutostartItem item, mItemMap.values()) - item.commit(); - return true; -} - -QMap AutoStartItemModel::items() -{ - QMap allItems; - - foreach(const QString &s, mLXQtItems) - allItems[s] = mItemMap.value(s); - - foreach(const QString &s, mGlobalItems) - allItems[s] = mItemMap.value(s); - - return allItems; -} - -/* - * Creates or replaces an autostart entry - */ -bool AutoStartItemModel::setEntry(const QModelIndex& index, XdgDesktopFile entry, bool overwrite) -{ - QModelIndex parent; - if (index.parent().isValid()) - parent = index.parent(); - else if (index.isValid()) - parent = index; - else - parent = mGlobalIndex; - - QString fileName = QFileInfo(entry.fileName()).fileName(); - bool replacing = mItemMap.contains(fileName); - if (!overwrite && replacing) - return false; - - if (parent == mLXQtIndex) - entry.setValue("OnlyShowIn", "LXQt;"); - - mItemMap[fileName].setFile(entry); - - if (replacing) - { - emit dataChanged(index, index); - return true; - } - - beginInsertRows(parent, 0, 0); - if (parent == mGlobalIndex) - mGlobalItems.append(fileName); - else - mLXQtItems.append(fileName); - endInsertRows(); - - return true; -} - -bool AutoStartItemModel::setData(const QModelIndex& index, const QVariant& value, int role) -{ - if (role == Qt::CheckStateRole) - { - QString name; - if (index.parent() == mGlobalIndex) - name = mGlobalItems.value(index.row()); - else - name = mLXQtItems.value(index.row()); - - mItemMap[name].setEnabled(value == Qt::Checked); - emit dataChanged(index, index); - return true; - } - return false; -} - -/* - * When user clicks "Delete", removes the local item. If there is a "system" item, - * it replaces it. - */ -bool AutoStartItemModel::removeRow(int row, const QModelIndex& parent) -{ - if (!parent.isValid()) - return false; - QString item; - - if (parent == mGlobalIndex) - item = mGlobalItems[row]; - else - item = mLXQtItems[row]; - - if (!mItemMap[item].removeLocal()) - { - QModelIndex index = parent.child(row, 0); - emit dataChanged(index, index); - return false; - } - - beginRemoveRows(parent, row, row); - if (parent == mGlobalIndex) - mGlobalItems.removeAt(row); - else - mLXQtItems.removeAt(row); - endRemoveRows(); - - if (mItemMap.value(item).isEmpty()) - mItemMap.remove(item); - return true; -} - -QModelIndex AutoStartItemModel::index(int row, int column, const QModelIndex& parent) const -{ - if (!parent.isValid()) - { - if (row == 0) - return mGlobalIndex; - else if (row == 1) - return mLXQtIndex; - } - else if (parent == mGlobalIndex && row < mGlobalItems.size()) - return QAbstractItemModel::createIndex(row, column, (void*)&mGlobalItems[row]); - else if (parent == mLXQtIndex && row < mLXQtItems.size()) - return QAbstractItemModel::createIndex(row, column, (void*)&mLXQtItems[row]); - return QModelIndex(); -} - -QVariant AutoStartItemModel::data(const QModelIndex& index, int role) const -{ - if (!index.parent().isValid()) - { - if (role == Qt::DisplayRole) - { - if (index.row() == 0) - return QString(tr("Global Autostart")); - else if (index.row() == 1) - return QString(tr("LXQt Autostart")); - } - return QVariant(); - } - - QString name = indexToName(index); - const AutostartItem& item = mItemMap.value(name); - if (role == Qt::DisplayRole) - { - QString title = item.file().name(); - if (title.isEmpty()) - return name; - return title; - } - else if (role == Qt::ToolTipRole) - { - QStringList tooltip; - if (!item.isTransient()) - tooltip << tr("Location: %1").arg(item.file().fileName()); - if (item.overrides()) - tooltip << tr("Overrides: %1").arg(item.systemfile().fileName()); - return tooltip.join("\n"); - } - else if (role == Qt::DecorationRole) - { - if (item.overrides()) - return XdgIcon::fromTheme("dialog-warning"); - else if (!item.isLocal()) - return XdgIcon::fromTheme("computer"); - } - else if (role == Qt::CheckStateRole) - { - return item.isEnabled() ? Qt::Checked : Qt::Unchecked; - } - return QVariant(); -} - -Qt::ItemFlags AutoStartItemModel::flags(const QModelIndex& index) const -{ - if (index.parent().isValid()) - return Qt::ItemIsEnabled | Qt::ItemIsSelectable | Qt::ItemIsUserCheckable; - if (index.isValid()) - return Qt::ItemIsEnabled | Qt::ItemIsSelectable; - return 0; -} - -/* - * Controls which buttons are enabled/disabled based on the selecton. - */ -AutoStartItemModel::ActiveButtons AutoStartItemModel::activeButtons(const QModelIndex& selection) const -{ - if (!selection.isValid() || !selection.parent().isValid()) - return AddButton; - else if (!mItemMap.value(indexToName(selection)).isLocal()) - return AddButton | EditButton; - else - return AddButton | EditButton | DeleteButton; -} - -QModelIndex AutoStartItemModel::parent(const QModelIndex& child) const -{ - QString name = indexToName(child); - if (!name.isEmpty()) - { - if (showOnlyInLXQt(mItemMap.value(name).file())) - return mLXQtIndex; - return mGlobalIndex; - } - return QModelIndex(); -} - -int AutoStartItemModel::columnCount(const QModelIndex& parent) const -{ - Q_UNUSED(parent); - return 1; -} - -int AutoStartItemModel::rowCount(const QModelIndex& parent) const -{ - if (!parent.isValid()) - return 2; - if (parent == mGlobalIndex) - return mGlobalItems.size(); - if (parent == mLXQtIndex) - return mLXQtItems.size(); - return 0; -} - -bool AutoStartItemModel::showOnlyInLXQt(const XdgDesktopFile& file) -{ - return file.value("OnlyShowIn") == "LXQt;"; -} - -/* - * Maps the index to file name - */ -QString AutoStartItemModel::indexToName(const QModelIndex& index) -{ - QString* data = static_cast(index.internalPointer()); - if (data) - return *data; - return QString(); -} - -XdgDesktopFile AutoStartItemModel::desktopFile(const QModelIndex& index) const -{ - return mItemMap.value(indexToName(index)).file(); -} diff --git a/lxqt-config-session/autostartmodel.h b/lxqt-config-session/autostartmodel.h deleted file mode 100644 index 1b79132..0000000 --- a/lxqt-config-session/autostartmodel.h +++ /dev/null @@ -1,78 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXQt - a lightweight, Qt based, desktop toolset - * http://razor-qt.org, http://lxde.org/ - * - * Copyright (C) 2011 Alec Moskvin - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - - * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#ifndef AUTOSTARTMODEL_H -#define AUTOSTARTMODEL_H - -#include -#include - -#include "autostartitem.h" - -class AutoStartItemModel : public QAbstractItemModel -{ - Q_OBJECT -public: - enum ActiveButton - { - AddButton = 1, - EditButton = 2, - DeleteButton = 4 - }; - Q_DECLARE_FLAGS(ActiveButtons, ActiveButton) - - explicit AutoStartItemModel(QObject* parent = 0); - ~AutoStartItemModel(); - int columnCount(const QModelIndex& parent = QModelIndex()) const; - int rowCount(const QModelIndex& parent = QModelIndex()) const; - QModelIndex index(int row, int column, const QModelIndex& parent = QModelIndex()) const; - Qt::ItemFlags flags(const QModelIndex& index) const; - QVariant data(const QModelIndex& index, int role = Qt::DisplayRole) const; - QModelIndex parent(const QModelIndex &child) const; - bool setData(const QModelIndex& index, const QVariant& value, int role = Qt::EditRole); - bool removeRow(int row, const QModelIndex& parent = QModelIndex()); - bool setEntry(const QModelIndex& index, XdgDesktopFile entry, bool overwrite=false); - ActiveButtons activeButtons(const QModelIndex& selection) const; - XdgDesktopFile desktopFile(const QModelIndex& index) const; - -public slots: - bool writeChanges(); - -public: - QMap items(); - -private: - QMap mItemMap; - QPersistentModelIndex mGlobalIndex; - QPersistentModelIndex mLXQtIndex; - QStringList mGlobalItems; - QStringList mLXQtItems; - - static QString indexToName(const QModelIndex& index); - static bool showOnlyInLXQt(const XdgDesktopFile& file); -}; - -Q_DECLARE_OPERATORS_FOR_FLAGS(AutoStartItemModel::ActiveButtons) - -#endif // AUTOSTARTMODEL_H diff --git a/lxqt-config-session/autostartpage.cpp b/lxqt-config-session/autostartpage.cpp deleted file mode 100644 index 94111a2..0000000 --- a/lxqt-config-session/autostartpage.cpp +++ /dev/null @@ -1,180 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXQt - a lightweight, Qt based, desktop toolset - * http://razor-qt.org, http://lxde.org/ - * - * Copyright (C) 2012 Alec Moskvin - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - - * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#include "autostartpage.h" -#include "ui_autostartpage.h" - -#include "autostartedit.h" -#include "autostartutils.h" - -#include - -AutoStartPage::AutoStartPage(QWidget* parent) : - QWidget(parent), - ui(new Ui::AutoStartPage) -{ - ui->setupUi(this); - - connect(ui->addButton, SIGNAL(clicked()), SLOT(addButton_clicked())); - connect(ui->editButton, SIGNAL(clicked()), SLOT(editButton_clicked())); - connect(ui->deleteButton, SIGNAL(clicked()), SLOT(deleteButton_clicked())); - - restoreSettings(); -} - -AutoStartPage::~AutoStartPage() -{ - delete ui; -} - -void AutoStartPage::restoreSettings() -{ - QAbstractItemModel* oldModel = ui->autoStartView->model(); - mXdgAutoStartModel = new AutoStartItemModel(ui->autoStartView); - ui->autoStartView->setModel(mXdgAutoStartModel); - delete oldModel; - ui->autoStartView->setExpanded(mXdgAutoStartModel->index(0, 0), true); - ui->autoStartView->setExpanded(mXdgAutoStartModel->index(1, 0), true); - updateButtons(); - connect(mXdgAutoStartModel, SIGNAL(dataChanged(QModelIndex,QModelIndex)), SLOT(updateButtons())); - connect(ui->autoStartView->selectionModel(), SIGNAL(currentChanged(QModelIndex,QModelIndex)), - SLOT(selectionChanged(QModelIndex))); -} - -void AutoStartPage::save() -{ - bool doRestart = false; - - /* - * Get the previous settings - */ - QMap previousItems(AutostartItem::createItemMap()); - QMutableMapIterator i(previousItems); - while (i.hasNext()) { - i.next(); - if (AutostartUtils::isLXQtModule(i.value().file())) - i.remove(); - } - - - /* - * Get the settings from the Ui - */ - QMap currentItems = mXdgAutoStartModel->items(); - QMutableMapIterator j(currentItems); - - while (j.hasNext()) { - j.next(); - if (AutostartUtils::isLXQtModule(j.value().file())) - j.remove(); - } - - - /* Compare the settings */ - - if (previousItems.count() != currentItems.count()) - { - doRestart = true; - } - else - { - QMap::const_iterator k = currentItems.constBegin(); - while (k != currentItems.constEnd()) - { - if (previousItems.contains(k.key())) - { - if (k.value().file() != previousItems.value(k.key()).file()) - { - doRestart = true; - break; - } - } - else - { - doRestart = true; - break; - } - ++k; - } - } - - if (doRestart) - emit needRestart(); - - mXdgAutoStartModel->writeChanges(); -} - -void AutoStartPage::addButton_clicked() -{ - AutoStartEdit edit(QString(), QString(), false); - bool success = false; - while (!success && edit.exec() == QDialog::Accepted) - { - QModelIndex index = ui->autoStartView->selectionModel()->currentIndex(); - XdgDesktopFile file(XdgDesktopFile::ApplicationType, edit.name(), edit.command()); - if (edit.needTray()) - file.setValue("X-LXQt-Need-Tray", true); - if (mXdgAutoStartModel->setEntry(index, file)) - success = true; - else - QMessageBox::critical(this, tr("Error"), tr("File '%1' already exists!").arg(file.fileName())); - } -} - -void AutoStartPage::editButton_clicked() -{ - QModelIndex index = ui->autoStartView->selectionModel()->currentIndex(); - XdgDesktopFile file = mXdgAutoStartModel->desktopFile(index); - AutoStartEdit edit(file.name(), file.value("Exec").toString(), file.contains("X-LXQt-Need-Tray")); - if (edit.exec() == QDialog::Accepted) - { - file.setLocalizedValue("Name", edit.name()); - file.setValue("Exec", edit.command()); - if (edit.needTray()) - file.setValue("X-LXQt-Need-Tray", true); - else - file.removeEntry("X-LXQt-Need-Tray"); - - mXdgAutoStartModel->setEntry(index, file, true); - } -} - -void AutoStartPage::deleteButton_clicked() -{ - QModelIndex index = ui->autoStartView->selectionModel()->currentIndex(); - mXdgAutoStartModel->removeRow(index.row(), index.parent()); -} - -void AutoStartPage::selectionChanged(QModelIndex curr) -{ - AutoStartItemModel::ActiveButtons active = mXdgAutoStartModel->activeButtons(curr); - ui->addButton->setEnabled(active & AutoStartItemModel::AddButton); - ui->editButton->setEnabled(active & AutoStartItemModel::EditButton); - ui->deleteButton->setEnabled(active & AutoStartItemModel::DeleteButton); -} - -void AutoStartPage::updateButtons() -{ - selectionChanged(ui->autoStartView->selectionModel()->currentIndex()); -} diff --git a/lxqt-config-session/autostartpage.h b/lxqt-config-session/autostartpage.h deleted file mode 100644 index 7431d4f..0000000 --- a/lxqt-config-session/autostartpage.h +++ /dev/null @@ -1,63 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXQt - a lightweight, Qt based, desktop toolset - * http://razor-qt.org, http://lxde.org/ - * - * Copyright (C) 2012 Alec Moskvin - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - - * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#ifndef AUTOSTARTPAGE_H -#define AUTOSTARTPAGE_H - -#include -#include -#include "autostartmodel.h" - -namespace Ui { -class AutoStartPage; -} - -class AutoStartPage : public QWidget -{ - Q_OBJECT - -public: - explicit AutoStartPage(QWidget* parent = 0); - ~AutoStartPage(); - -signals: - void needRestart(); - -public slots: - void save(); - void restoreSettings(); - -private: - AutoStartItemModel* mXdgAutoStartModel; - Ui::AutoStartPage* ui; - -private slots: - void addButton_clicked(); - void editButton_clicked(); - void deleteButton_clicked(); - void selectionChanged(QModelIndex curr); - void updateButtons(); -}; - -#endif // AUTOSTARTPAGE_H diff --git a/lxqt-config-session/autostartpage.ui b/lxqt-config-session/autostartpage.ui deleted file mode 100644 index a6ff280..0000000 --- a/lxqt-config-session/autostartpage.ui +++ /dev/null @@ -1,72 +0,0 @@ - - - AutoStartPage - - - - 0 - 0 - 320 - 240 - - - - - - - Delete - - - - - - - Add - - - - - - - Edit - - - - - - - - 75 - true - - - - Application Autostart - - - - - - - Qt::Vertical - - - - 20 - 40 - - - - - - - - false - - - - - - - - diff --git a/lxqt-config-session/autostartutils.cpp b/lxqt-config-session/autostartutils.cpp deleted file mode 100644 index 671f4c3..0000000 --- a/lxqt-config-session/autostartutils.cpp +++ /dev/null @@ -1,33 +0,0 @@ -/* This file is part of the LXQt project. - * Copyright (C) 2015 Luís Pereira - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA - */ - -#include "autostartutils.h" -#include - -#include - -bool AutostartUtils::showOnlyInLXQt(const XdgDesktopFile &file) -{ - return file.value(QLatin1String("OnlyShowIn")) == QLatin1String("LXQt;"); -} - -bool AutostartUtils::isLXQtModule(const XdgDesktopFile& file) -{ - return file.value(QLatin1String("X-LXQt-Module"), false).toBool(); -} - diff --git a/lxqt-config-session/autostartutils.h b/lxqt-config-session/autostartutils.h deleted file mode 100644 index f1cbfb2..0000000 --- a/lxqt-config-session/autostartutils.h +++ /dev/null @@ -1,31 +0,0 @@ -/* This file is part of the LXQt project. - * Copyright (C) 2015 Luís Pereira - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA - */ - -#ifndef AUTOSTARTUTILS_H -#define AUTOSTARTUTILS_H - -class XdgDesktopFile; - -class AutostartUtils -{ -public: - static bool showOnlyInLXQt(const XdgDesktopFile& file); - static bool isLXQtModule(const XdgDesktopFile& file); -}; - -#endif // AUTOSTARTUTILS_H diff --git a/lxqt-config-session/basicsettings.cpp b/lxqt-config-session/basicsettings.cpp deleted file mode 100644 index ff0c37f..0000000 --- a/lxqt-config-session/basicsettings.cpp +++ /dev/null @@ -1,157 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXQt - a lightweight, Qt based, desktop toolset - * http://razor-qt.org, http://lxde.org/ - * - * Copyright: 2010-2012 LXQt team - * Authors: - * Petr Vanek - * - * This program or library is free software; you can redistribute it - * and/or modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - - * You should have received a copy of the GNU Lesser General - * Public License along with this library; if not, write to the - * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#include "basicsettings.h" -#include "ui_basicsettings.h" - -#include "../lxqt-session/src/windowmanager.h" -#include "sessionconfigwindow.h" -#include "autostartutils.h" - -static const QLatin1String windowManagerKey("window_manager"); -static const QLatin1String leaveConfirmationKey("leave_confirmation"); -static const QLatin1String lockBeforePowerActionsKey("lock_screen_before_power_actions"); -static const QLatin1String openboxValue("openbox"); - -BasicSettings::BasicSettings(LXQt::Settings *settings, QWidget *parent) : - QWidget(parent), - m_settings(settings), - m_moduleModel(new ModuleModel()), - ui(new Ui::BasicSettings) -{ - ui->setupUi(this); - connect(ui->findWmButton, SIGNAL(clicked()), this, SLOT(findWmButton_clicked())); - connect(ui->startButton, SIGNAL(clicked()), this, SLOT(startButton_clicked())); - connect(ui->stopButton, SIGNAL(clicked()), this, SLOT(stopButton_clicked())); - restoreSettings(); - - ui->moduleView->setModel(m_moduleModel); - ui->moduleView->header()->setSectionResizeMode(0, QHeaderView::Stretch); - ui->moduleView->header()->setSectionResizeMode(1, QHeaderView::ResizeToContents); -} - -BasicSettings::~BasicSettings() -{ - delete ui; -} - -void BasicSettings::restoreSettings() -{ - QStringList knownWMs; - foreach (const WindowManager &wm, getWindowManagerList(true)) - { - knownWMs << wm.command; - } - - QString wm = m_settings->value(windowManagerKey, openboxValue).toString(); - SessionConfigWindow::handleCfgComboBox(ui->wmComboBox, knownWMs, wm); - m_moduleModel->reset(); - - ui->leaveConfirmationCheckBox->setChecked(m_settings->value(leaveConfirmationKey, false).toBool()); - ui->lockBeforePowerActionsCheckBox->setChecked(m_settings->value(lockBeforePowerActionsKey, true).toBool()); -} - -void BasicSettings::save() -{ - /* If the setting actually changed: - * * Save the setting - * * Emit a needsRestart signal - */ - - bool doRestart = false; - const QString windowManager = ui->wmComboBox->currentText(); - const bool leaveConfirmation = ui->leaveConfirmationCheckBox->isChecked(); - const bool lockBeforePowerActions = ui->lockBeforePowerActionsCheckBox->isChecked(); - - QMap previousItems(AutostartItem::createItemMap()); - QMutableMapIterator i(previousItems); - while (i.hasNext()) { - i.next(); - if (!AutostartUtils::isLXQtModule(i.value().file())) - i.remove(); - } - - - if (windowManager != m_settings->value(windowManagerKey, openboxValue).toString()) - { - m_settings->setValue(windowManagerKey, windowManager); - doRestart = true; - } - - - if (leaveConfirmation != m_settings->value(leaveConfirmationKey, false).toBool()) - { - m_settings->setValue(leaveConfirmationKey, leaveConfirmation); - doRestart = true; - } - - if (lockBeforePowerActions != m_settings->value(lockBeforePowerActionsKey, true).toBool()) - { - m_settings->setValue(lockBeforePowerActionsKey, lockBeforePowerActions); - doRestart = true; - } - - QMap currentItems = m_moduleModel->items(); - QMap::const_iterator k = currentItems.constBegin(); - while (k != currentItems.constEnd()) - { - if (previousItems.contains(k.key())) - { - if (k.value().file() != previousItems.value(k.key()).file()) - { - doRestart = true; - break; - } - } - else - { - doRestart = true; - break; - } - ++k; - } - - if (doRestart) - emit needRestart(); - - m_moduleModel->writeChanges(); -} - -void BasicSettings::findWmButton_clicked() -{ - SessionConfigWindow::updateCfgComboBox(ui->wmComboBox, tr("Select a window manager")); -} - -void BasicSettings::startButton_clicked() -{ - m_moduleModel->toggleModule(ui->moduleView->selectionModel()->currentIndex(), true); -} - -void BasicSettings::stopButton_clicked() -{ - m_moduleModel->toggleModule(ui->moduleView->selectionModel()->currentIndex(), false); -} diff --git a/lxqt-config-session/basicsettings.h b/lxqt-config-session/basicsettings.h deleted file mode 100644 index ab36a58..0000000 --- a/lxqt-config-session/basicsettings.h +++ /dev/null @@ -1,66 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXQt - a lightweight, Qt based, desktop toolset - * http://razor-qt.org, http://lxde.org/ - * - * Copyright: 2010-2012 LXQt team - * Authors: - * Petr Vanek - * - * This program or library is free software; you can redistribute it - * and/or modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - - * You should have received a copy of the GNU Lesser General - * Public License along with this library; if not, write to the - * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#ifndef BASICSETTINGS_H -#define BASICSETTINGS_H - -#include -#include - -#include "modulemodel.h" - -namespace Ui { -class BasicSettings; -} - -class BasicSettings : public QWidget -{ - Q_OBJECT - -public: - explicit BasicSettings(LXQt::Settings *settings, QWidget *parent = 0); - ~BasicSettings(); - -signals: - void needRestart(); - -public slots: - void restoreSettings(); - void save(); - -private: - LXQt::Settings* m_settings; - ModuleModel* m_moduleModel; - Ui::BasicSettings* ui; - -private slots: - void findWmButton_clicked(); - void startButton_clicked(); - void stopButton_clicked(); -}; - -#endif // BASICSETTINGS_H diff --git a/lxqt-config-session/basicsettings.ui b/lxqt-config-session/basicsettings.ui deleted file mode 100644 index 3c4449a..0000000 --- a/lxqt-config-session/basicsettings.ui +++ /dev/null @@ -1,135 +0,0 @@ - - - BasicSettings - - - - 0 - 0 - 322 - 380 - - - - - - - - 75 - true - - - - Basic Settings - - - - - - - Window Manager - - - - - - - 0 - 0 - - - - true - - - - - - - Search... - - - - - - - - - - LXQt Modules - - - - - - Start - - - - - - - Stop - - - - - - - Qt::Horizontal - - - - 40 - 20 - - - - - - - - true - - - false - - - true - - - false - - - - - - - - - - Leave Session - - - - - - Ask for confirmation to leave session - - - - - - - Lock screen before suspending/hibernating - - - - - - - - - - - diff --git a/lxqt-config-session/defaultappspage.cpp b/lxqt-config-session/defaultappspage.cpp deleted file mode 100644 index 15eb177..0000000 --- a/lxqt-config-session/defaultappspage.cpp +++ /dev/null @@ -1,88 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXQt - a lightweight, Qt based, desktop toolset - * http://razor-qt.org, http://lxde.org/ - * - * Copyright: 2010-2012 LXQt team - * Authors: - * Petr Vanek - * - * This program or library is free software; you can redistribute it - * and/or modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - - * You should have received a copy of the GNU Lesser General - * Public License along with this library; if not, write to the - * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#include - -#include "defaultappspage.h" -#include "ui_defaultappspage.h" - -#include "sessionconfigwindow.h" - -DefaultApps::DefaultApps(QWidget *parent) : - QWidget(parent), - ui(new Ui::DefaultAppsPage) -{ - ui->setupUi(this); - - connect(ui->terminalButton, SIGNAL(clicked()), this, SLOT(terminalButton_clicked())); - connect(ui->terminalComboBox->lineEdit(), SIGNAL(editingFinished()), - SLOT(terminalChanged())); - connect(ui->browserButton, SIGNAL(clicked()), this, SLOT(browserButton_clicked())); - connect(ui->browserComboBox->lineEdit(), SIGNAL(editingFinished()), - SLOT(browserChanged())); -} - -DefaultApps::~DefaultApps() -{ - delete ui; -} - -void DefaultApps::updateEnvVar(const QString& var, const QString& val) -{ - if (var == "BROWSER") - { - QStringList knownBrowsers; - knownBrowsers << "firefox" << "qupzilla" << "arora" << "konqueror" << "opera"; - SessionConfigWindow::handleCfgComboBox(ui->browserComboBox, knownBrowsers, val); - } - else if (var == "TERM") - { - QStringList knownTerms; - knownTerms << "qterminal" << "xterm" << "konsole" << "uterm"; - SessionConfigWindow::handleCfgComboBox(ui->terminalComboBox, knownTerms, val); - } -} - -void DefaultApps::terminalButton_clicked() -{ - SessionConfigWindow::updateCfgComboBox(ui->terminalComboBox, tr("Select a terminal emulator")); -} - -void DefaultApps::browserButton_clicked() -{ - SessionConfigWindow::updateCfgComboBox(ui->browserComboBox, tr("Select a web browser")); -} - -void DefaultApps::terminalChanged() -{ - emit defaultAppChanged("TERM", ui->terminalComboBox->lineEdit()->text()); -} - -void DefaultApps::browserChanged() -{ - emit defaultAppChanged("BROWSER", ui->browserComboBox->lineEdit()->text()); -} diff --git a/lxqt-config-session/defaultappspage.h b/lxqt-config-session/defaultappspage.h deleted file mode 100644 index 59a1339..0000000 --- a/lxqt-config-session/defaultappspage.h +++ /dev/null @@ -1,61 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXQt - a lightweight, Qt based, desktop toolset - * http://razor-qt.org, http://lxde.org/ - * - * Copyright: 2010-2012 LXQt team - * Authors: - * Petr Vanek - * - * This program or library is free software; you can redistribute it - * and/or modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - - * You should have received a copy of the GNU Lesser General - * Public License along with this library; if not, write to the - * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#ifndef DEFAULTAPPS_H -#define DEFAULTAPPS_H - -#include - -namespace Ui { -class DefaultAppsPage; -} - -class DefaultApps : public QWidget -{ - Q_OBJECT - -public: - explicit DefaultApps(QWidget *parent = 0); - ~DefaultApps(); - -signals: - void defaultAppChanged(const QString&, const QString&); - -public slots: - void updateEnvVar(const QString &var, const QString &val); - -private: - Ui::DefaultAppsPage *ui; - -private slots: - void browserButton_clicked(); - void terminalButton_clicked(); - void browserChanged(); - void terminalChanged(); -}; - -#endif // DEFAULTAPPS_H diff --git a/lxqt-config-session/defaultappspage.ui b/lxqt-config-session/defaultappspage.ui deleted file mode 100644 index dbd9545..0000000 --- a/lxqt-config-session/defaultappspage.ui +++ /dev/null @@ -1,102 +0,0 @@ - - - DefaultAppsPage - - - - 0 - 0 - 340 - 135 - - - - - - - - 75 - true - - - - Default Applications - - - - - - - - - Terminal Emulation: - - - - - - - - 0 - 0 - - - - true - - - - - - - Search... - - - - - - - Web Browser: - - - - - - - - 0 - 0 - - - - true - - - - - - - Search... - - - - - - - Qt::Vertical - - - - 118 - 186 - - - - - - - - - - - diff --git a/lxqt-config-session/environmentpage.cpp b/lxqt-config-session/environmentpage.cpp deleted file mode 100644 index 7cc95d8..0000000 --- a/lxqt-config-session/environmentpage.cpp +++ /dev/null @@ -1,150 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXQt - a lightweight, Qt based, desktop toolset - * http://razor-qt.org, http://lxde.org/ - * - * Copyright: 2010-2012 LXQt team - * Authors: - * Petr Vanek - * - * This program or library is free software; you can redistribute it - * and/or modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - - * You should have received a copy of the GNU Lesser General - * Public License along with this library; if not, write to the - * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#include "environmentpage.h" -#include "ui_environmentpage.h" - -EnvironmentPage::EnvironmentPage(LXQt::Settings *settings, QWidget *parent) : - QWidget(parent), - m_settings(settings), - ui(new Ui::EnvironmentPage) -{ - ui->setupUi(this); - - connect(ui->addButton, SIGNAL(clicked()), SLOT(addButton_clicked())); - connect(ui->deleteButton, SIGNAL(clicked()), SLOT(deleteButton_clicked())); - connect(ui->treeWidget, SIGNAL(itemChanged(QTreeWidgetItem*,int)), - SLOT(itemChanged(QTreeWidgetItem*,int))); - - /* restoreSettings() is called from SessionConfigWindow - after connections with DefaultApps have been set up */ -} - -EnvironmentPage::~EnvironmentPage() -{ - delete ui; -} - -void EnvironmentPage::restoreSettings() -{ - m_settings->beginGroup("Environment"); - QString value; - ui->treeWidget->clear(); - foreach (const QString& i, m_settings->childKeys()) - { - value = m_settings->value(i).toString(); - QTreeWidgetItem *item = new QTreeWidgetItem(ui->treeWidget, QStringList() << i << value); - item->setFlags(item->flags() | Qt::ItemIsEditable); - ui->treeWidget->addTopLevelItem(item); - emit envVarChanged(i, value); - } - - if (m_settings->value("BROWSER").isNull()) - emit envVarChanged("BROWSER", ""); - if (m_settings->value("TERM").isNull()) - emit envVarChanged("TERM", ""); - - m_settings->endGroup(); -} - -void EnvironmentPage::save() -{ - bool doRestart = false; - QMap oldSettings; - - m_settings->beginGroup("Environment"); - - /* We erase the Enviroment group and them write the Ui settings. To know if - they changed or not we need to save them to memory. - */ - foreach (const QString &key, m_settings->childKeys()) - oldSettings[key] = m_settings->value(key, QString()).toString(); - m_settings->remove(""); - - const int nItems = ui->treeWidget->topLevelItemCount(); - for(int i = 0; i < nItems; ++i) - { - QTreeWidgetItem *item = ui->treeWidget->topLevelItem(i); - const QString key = item->text(0); - const QString value = item->text(1); - - if (oldSettings.value(key) != value) - doRestart = true; - - m_settings->setValue(item->text(0), item->text(1)); - } - m_settings->endGroup(); - - if (oldSettings.size() != nItems) - doRestart = true; - - if (doRestart) - emit needRestart(); -} - -void EnvironmentPage::addButton_clicked() -{ - QTreeWidgetItem *item = new QTreeWidgetItem(ui->treeWidget, QStringList() << "" << ""); - item->setFlags(item->flags() | Qt::ItemIsEditable); - ui->treeWidget->addTopLevelItem(item); - ui->treeWidget->setCurrentItem(item); -} - -void EnvironmentPage::deleteButton_clicked() -{ - foreach (QTreeWidgetItem* item, ui->treeWidget->selectedItems()) - { - emit envVarChanged(item->text(0), ""); - delete item; - } -} - -void EnvironmentPage::itemChanged(QTreeWidgetItem *item, int column) -{ - Q_UNUSED(column); - emit envVarChanged(item->text(0), item->text(1)); -} - -void EnvironmentPage::updateItem(const QString& var, const QString& val) -{ - QList itemList = ui->treeWidget->findItems(var, Qt::MatchExactly); - if (itemList.isEmpty()) - { - QTreeWidgetItem *item = new QTreeWidgetItem(ui->treeWidget, QStringList() << var << val); - item->setFlags(item->flags() | Qt::ItemIsEditable); - ui->treeWidget->addTopLevelItem(item); - return; - } - - foreach (QTreeWidgetItem* item, itemList) - { - if (!val.isEmpty()) - item->setText(1, val); - else - delete item; - } -} diff --git a/lxqt-config-session/environmentpage.h b/lxqt-config-session/environmentpage.h deleted file mode 100644 index befbe23..0000000 --- a/lxqt-config-session/environmentpage.h +++ /dev/null @@ -1,65 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXQt - a lightweight, Qt based, desktop toolset - * http://razor-qt.org, http://lxde.org/ - * - * Copyright: 2010-2012 LXQt team - * Authors: - * Petr Vanek - * - * This program or library is free software; you can redistribute it - * and/or modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - - * You should have received a copy of the GNU Lesser General - * Public License along with this library; if not, write to the - * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#ifndef ENVIRONMENTPAGE_H -#define ENVIRONMENTPAGE_H - -#include -#include - -namespace Ui { -class EnvironmentPage; -} - -class EnvironmentPage : public QWidget -{ - Q_OBJECT - -public: - explicit EnvironmentPage(LXQt::Settings *settings, QWidget *parent = 0); - ~EnvironmentPage(); - -signals: - void needRestart(); - void envVarChanged(const QString&, const QString&); - -public slots: - void restoreSettings(); - void save(); - void updateItem(const QString &var, const QString &val); - -private: - LXQt::Settings *m_settings; - Ui::EnvironmentPage *ui; - -private slots: - void addButton_clicked(); - void deleteButton_clicked(); - void itemChanged(QTreeWidgetItem *item, int column); -}; - -#endif // ENVIRONMENTPAGE_H diff --git a/lxqt-config-session/environmentpage.ui b/lxqt-config-session/environmentpage.ui deleted file mode 100644 index 0f6932f..0000000 --- a/lxqt-config-session/environmentpage.ui +++ /dev/null @@ -1,75 +0,0 @@ - - - EnvironmentPage - - - - 0 - 0 - 400 - 320 - - - - - - - Add - - - - - - - Delete - - - - - - - Qt::Vertical - - - - 59 - 96 - - - - - - - - - 75 - true - - - - Environment Variables (Advanced) - - - - - - - true - - - - Variable Name - - - - - Value - - - - - - - - - diff --git a/lxqt-config-session/lxqt-config-session.desktop.in b/lxqt-config-session/lxqt-config-session.desktop.in deleted file mode 100644 index eb6526f..0000000 --- a/lxqt-config-session/lxqt-config-session.desktop.in +++ /dev/null @@ -1,11 +0,0 @@ -[Desktop Entry] -Type=Application -Name=Session Settings -GenericName=LXQt Session Settings -Comment=Configuration for LXQt sessions -Exec=lxqt-config-session -Icon=preferences-system-session-services -Categories=Settings;DesktopSettings;Qt;LXQt; -OnlyShowIn=LXQt; - -#TRANSLATIONS_DIR=translations diff --git a/lxqt-config-session/main.cpp b/lxqt-config-session/main.cpp deleted file mode 100644 index 483efd5..0000000 --- a/lxqt-config-session/main.cpp +++ /dev/null @@ -1,56 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXQt - a lightweight, Qt based, desktop toolset - * http://razor-qt.org, http://lxde.org/ - * - * Copyright: 2010-2011 LXQt team - * Authors: - * Petr Vanek - * - * This program or library is free software; you can redistribute it - * and/or modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - - * You should have received a copy of the GNU Lesser General - * Public License along with this library; if not, write to the - * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#include - -#include -#include -#include - -#include "sessionconfigwindow.h" - -int main(int argc, char** argv) -{ - LXQt::SingleApplication a(argc, argv); - a.setAttribute(Qt::AA_UseHighDpiPixmaps, true); - - QCommandLineParser parser; - parser.setApplicationDescription(QStringLiteral("LXQt Config Session")); - const QString VERINFO = QStringLiteral(LXQT_SESSION_VERSION - "\nliblxqt " LXQT_VERSION - "\nQt " QT_VERSION_STR); - a.setApplicationVersion(VERINFO); - parser.addVersionOption(); - parser.addHelpOption(); - parser.process(a); - - SessionConfigWindow w; - a.setActivationWindow(&w); - w.show(); - - return a.exec(); -} diff --git a/lxqt-config-session/man/lxqt-config-session.1 b/lxqt-config-session/man/lxqt-config-session.1 deleted file mode 100644 index ceeb7b6..0000000 --- a/lxqt-config-session/man/lxqt-config-session.1 +++ /dev/null @@ -1,20 +0,0 @@ -.TH lxqt-config-session "1" "2015-11-05" "LXQt 0.10.0" "LXQt Application/Environment Configuration" -.SH NAME -\fBlxqt-config-session\fR \- Application settings of \fBLXQt\fR: The Lightweight -Qt Desktop Environment -.SH SYNOPSIS -.B lxqt-config-session -.br -.SH DESCRIPTION -This application handles \fBLXQt\fR default applications settings, autostart -configuration, and environment settings. -.SH "REPORTING BUGS" -Report bugs to https://github.com/lxde/lxqt/issues -.SH "SEE ALSO" -.\" any module must refer to the session application, for module overview and initiation -\fBstartlxqt.1\fR LXQt session initialization and launch script (e.g. in \fB.xinitrc\fR) -.P -\fBlxqt-session.1\fR LXQt \fIoverview\fR and complete session environment -.P -\fBlxqt-config.1\fR LXQt settings Configuration Center interface -.P diff --git a/lxqt-config-session/modulemodel.cpp b/lxqt-config-session/modulemodel.cpp deleted file mode 100644 index 30d472c..0000000 --- a/lxqt-config-session/modulemodel.cpp +++ /dev/null @@ -1,151 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXQt - a lightweight, Qt based, desktop toolset - * http://razor-qt.org, http://lxde.org/ - * - * Copyright (C) 2012 Alec Moskvin - * - * This program or library is free software; you can redistribute it - * and/or modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - - * You should have received a copy of the GNU Lesser General - * Public License along with this library; if not, write to the - * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#include -#include -#include -#include -#include "modulemodel.h" -#include "autostartutils.h" - -ModuleModel::ModuleModel(QObject* parent) - : QAbstractListModel(parent) -{ - mInterface = new QDBusInterface("org.lxqt.session", "/LXQtSession", "", - QDBusConnection::sessionBus(), this); - connect(mInterface, SIGNAL(moduleStateChanged(QString,bool)), SLOT(updateModuleState(QString,bool))); -} - -ModuleModel::~ModuleModel() -{ - delete mInterface; -} - -void ModuleModel::reset() -{ - mKeyList.clear(); - mStateMap.clear(); - mItemMap = AutostartItem::createItemMap(); - - QMap::iterator iter; - for (iter = mItemMap.begin(); iter != mItemMap.end(); ++iter) - { - if (AutostartUtils::isLXQtModule(iter.value().file())) - mKeyList.append(iter.key()); - } - - QDBusReply reply = mInterface->call("listModules"); - const QStringList moduleList = reply.value().toStringList(); - foreach (const QString& moduleName, moduleList) - { - if (mItemMap.contains(moduleName)) - mStateMap[moduleName] = true; - } -} - -QVariant ModuleModel::data(const QModelIndex& index, int role) const -{ - QString name = mKeyList.at(index.row()); - if (index.column() == 0) - { - switch (role) - { - case Qt::DisplayRole: - return mItemMap.value(name).file().name(); - case Qt::CheckStateRole: - return mItemMap.value(name).isEnabled() ? Qt::Checked : Qt::Unchecked; - case Qt::ToolTipRole: - return mItemMap.value(name).file().comment(); - } - } - else if (index.column() == 1 && (role == Qt::DisplayRole || role == Qt::DecorationRole)) - { - if (role == Qt::DisplayRole && mStateMap[name] == true) - return QString(tr("Running") + QLatin1Char(' ')); - } - return QVariant(); -} - -bool ModuleModel::setData(const QModelIndex& index, const QVariant& value, int role) -{ - if (role == Qt::CheckStateRole) - { - QString key = mKeyList.at(index.row()); - mItemMap[key].setEnabled(value == Qt::Checked); - emit dataChanged(index, index); - return true; - } - return false; -} - -Qt::ItemFlags ModuleModel::flags(const QModelIndex& index) const -{ - Q_UNUSED(index); - return Qt::ItemIsEnabled | Qt::ItemIsSelectable | Qt::ItemIsUserCheckable; -} - -QMap ModuleModel::items() -{ - QMap allItems; - - foreach(const QString &s, mKeyList) - allItems[s] = mItemMap.value(s); - - return allItems; -} - -int ModuleModel::rowCount(const QModelIndex& parent) const -{ - Q_UNUSED(parent); - return mKeyList.size(); -} - -void ModuleModel::writeChanges() -{ - foreach (const QString& key, mKeyList) - mItemMap[key].commit(); -} - -void ModuleModel::updateModuleState(QString moduleName, bool state) -{ - if (mItemMap.contains(moduleName)) - { - mStateMap[moduleName] = state; - QModelIndex i = index(mKeyList.indexOf(moduleName), 1); - emit dataChanged(i, i); - } -} - -void ModuleModel::toggleModule(const QModelIndex &index, bool status) -{ - if (!index.isValid()) - return; - - QList arg; - arg.append(mKeyList.at(index.row())); - mInterface->callWithArgumentList(QDBus::NoBlock, - status ? "startModule" : "stopModule", - arg); -} diff --git a/lxqt-config-session/modulemodel.h b/lxqt-config-session/modulemodel.h deleted file mode 100644 index db345ed..0000000 --- a/lxqt-config-session/modulemodel.h +++ /dev/null @@ -1,61 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXQt - a lightweight, Qt based, desktop toolset - * http://razor-qt.org, http://lxde.org/ - * - * Copyright (C) 2012 Alec Moskvin - * - * This program or library is free software; you can redistribute it - * and/or modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - - * You should have received a copy of the GNU Lesser General - * Public License along with this library; if not, write to the - * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#ifndef MODULEMODEL_H -#define MODULEMODEL_H - -#include -#include -#include "autostartitem.h" - -class ModuleModel : public QAbstractListModel -{ - Q_OBJECT -public: - ModuleModel(QObject *parent = 0); - ~ModuleModel(); - void reset(); - void writeChanges(); - void toggleModule(const QModelIndex &index, bool status); - - QVariant data(const QModelIndex& index, int role = Qt::DisplayRole) const; - bool setData(const QModelIndex& index, const QVariant& value, int role); - int rowCount(const QModelIndex& parent) const; - int columnCount(const QModelIndex&) const { return 2; } - Qt::ItemFlags flags(const QModelIndex& index) const; - - QMap items(); - -private slots: - void updateModuleState(QString moduleName, bool state); - -private: - QMap mItemMap; - QMap mStateMap; - QStringList mKeyList; - QDBusInterface* mInterface; -}; - -#endif // MODULEMODEL_H diff --git a/lxqt-config-session/sessionconfigwindow.cpp b/lxqt-config-session/sessionconfigwindow.cpp deleted file mode 100644 index cdb6443..0000000 --- a/lxqt-config-session/sessionconfigwindow.cpp +++ /dev/null @@ -1,144 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXQt - a lightweight, Qt based, desktop toolset - * http://razor-qt.org, http://lxde.org/ - * - * Copyright: 2010-2011 LXQt team - * Authors: - * Petr Vanek - * - * This program or library is free software; you can redistribute it - * and/or modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - - * You should have received a copy of the GNU Lesser General - * Public License along with this library; if not, write to the - * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#include -#include -#include - -#include - -#include "sessionconfigwindow.h" -#include "../lxqt-session/src/windowmanager.h" -#include "basicsettings.h" -#include "autostartpage.h" -#include "defaultappspage.h" -#include "environmentpage.h" -#include "userlocationspage.h" - - -SessionConfigWindow::SessionConfigWindow() : - LXQt::ConfigDialog(tr("LXQt Session Settings"), new LXQt::Settings("session"), 0) -{ - BasicSettings* basicSettings = new BasicSettings(mSettings, this); - addPage(basicSettings, tr("Basic Settings"), "preferences-desktop-display-color"); - connect(basicSettings, SIGNAL(needRestart()), SLOT(setRestart())); - connect(this, SIGNAL(reset()), basicSettings, SLOT(restoreSettings())); - connect(this, SIGNAL(save()), basicSettings, SLOT(save())); - - DefaultApps* defaultApps = new DefaultApps(this); - addPage(defaultApps, tr("Default Applications"), "preferences-desktop-filetype-association"); - - UserLocationsPage* userLocations = new UserLocationsPage(this); - addPage(userLocations, tr("User Directories"), QStringLiteral("folder")); - connect(userLocations, SIGNAL(needRestart()), SLOT(setRestart())); - connect(this, SIGNAL(reset()), userLocations, SLOT(restoreSettings())); - connect(this, SIGNAL(save()), userLocations, SLOT(save())); - - AutoStartPage* autoStart = new AutoStartPage(this); - addPage(autoStart, tr("Autostart"), "preferences-desktop-launch-feedback"); - connect(autoStart, SIGNAL(needRestart()), SLOT(setRestart())); - connect(this, SIGNAL(reset()), autoStart, SLOT(restoreSettings())); - connect(this, SIGNAL(save()), autoStart, SLOT(save())); - - EnvironmentPage* environmentPage = new EnvironmentPage(mSettings, this); - addPage(environmentPage, tr("Environment (Advanced)"), "preferences-system-session-services"); - connect(environmentPage, SIGNAL(needRestart()), SLOT(setRestart())); - connect(this, SIGNAL(reset()), environmentPage, SLOT(restoreSettings())); - connect(this, SIGNAL(save()), environmentPage, SLOT(save())); - - // sync Default Apps and Environment - connect(environmentPage, SIGNAL(envVarChanged(QString,QString)), - defaultApps, SLOT(updateEnvVar(QString,QString))); - connect(defaultApps, SIGNAL(defaultAppChanged(QString,QString)), - environmentPage, SLOT(updateItem(QString,QString))); - environmentPage->restoreSettings(); - connect(this, SIGNAL(reset()), SLOT(clearRestart())); - m_restart = false; - - adjustSize(); -} - -SessionConfigWindow::~SessionConfigWindow() -{ - delete mSettings; -} - -void SessionConfigWindow::closeEvent(QCloseEvent * event) -{ - LXQt::ConfigDialog::closeEvent(event); - if (m_restart) { - QMessageBox::information(this, tr("Session Restart Required"), - tr("Some settings will not take effect until the next log in.") - ); - } -} - -void SessionConfigWindow::handleCfgComboBox(QComboBox * cb, - const QStringList &availableValues, - const QString &value - ) -{ - QStringList realValues; - foreach (const QString &s, availableValues) - { - if (findProgram(s)) - realValues << s; - } - cb->clear(); - cb->addItems(realValues); - - int ix = cb->findText(value); - if (ix == -1) - cb->lineEdit()->setText(value); - else - cb->setCurrentIndex(ix); -} - -void SessionConfigWindow::updateCfgComboBox(QComboBox * cb, - const QString &prompt - ) -{ - QString fname = QFileDialog::getOpenFileName(cb, prompt, "/usr/bin/"); - if (fname.isEmpty()) - return; - - QFileInfo fi(fname); - if (!fi.exists() || !fi.isExecutable()) - return; - - cb->lineEdit()->setText(fname); -} - -void SessionConfigWindow::setRestart() -{ - m_restart = true; -} - -void SessionConfigWindow::clearRestart() -{ - m_restart = false; -} diff --git a/lxqt-config-session/sessionconfigwindow.h b/lxqt-config-session/sessionconfigwindow.h deleted file mode 100644 index 02ff443..0000000 --- a/lxqt-config-session/sessionconfigwindow.h +++ /dev/null @@ -1,63 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXQt - a lightweight, Qt based, desktop toolset - * http://razor-qt.org, http://lxde.org/ - * - * Copyright: 2010-2011 LXQt team - * Authors: - * Petr Vanek - * - * This program or library is free software; you can redistribute it - * and/or modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - - * You should have received a copy of the GNU Lesser General - * Public License along with this library; if not, write to the - * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#ifndef SESSIONCONFIGWINDOW_H -#define SESSIONCONFIGWINDOW_H - -#include -#include - - -class SessionConfigWindow : public LXQt::ConfigDialog -{ - Q_OBJECT - -public: - SessionConfigWindow(); - ~SessionConfigWindow(); - - static void handleCfgComboBox(QComboBox * cb, - const QStringList &availableValues, - const QString &value - ); - - static void updateCfgComboBox(QComboBox * cb, const QString &prompt); - - void closeEvent(QCloseEvent * event); - -public slots: - void setRestart(); - -private: - // display restart warning - bool m_restart; - -private slots: - void clearRestart(); -}; - -#endif diff --git a/lxqt-config-session/translations/lxqt-config-session_ar.desktop b/lxqt-config-session/translations/lxqt-config-session_ar.desktop deleted file mode 100644 index 5dbe7d9..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_ar.desktop +++ /dev/null @@ -1,4 +0,0 @@ -# Translations -Comment[ar]=ضبط جلسات لكسكيوت -GenericName[ar]=إعدادات لكسكيوت للجلسات -Name[ar]=إعدادات الجلسات diff --git a/lxqt-config-session/translations/lxqt-config-session_ca.desktop b/lxqt-config-session/translations/lxqt-config-session_ca.desktop deleted file mode 100644 index 12b6a1d..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_ca.desktop +++ /dev/null @@ -1,4 +0,0 @@ -# Translations -Name[ca]=Ajusts de la sessió -GenericName[ca]=Ajusts de la sessió de LXQt -Comment[ca]=Configuració per a les sessions de LXQt diff --git a/lxqt-config-session/translations/lxqt-config-session_cs.desktop b/lxqt-config-session/translations/lxqt-config-session_cs.desktop deleted file mode 100644 index 9666aaa..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_cs.desktop +++ /dev/null @@ -1,4 +0,0 @@ -# Translations -Comment[cs]=Nastavit modul sezení LXQt -GenericName[cs]=Nastavení sezení LXQt -Name[cs]=Nastavení sezení LXQt diff --git a/lxqt-config-session/translations/lxqt-config-session_cs_CZ.desktop b/lxqt-config-session/translations/lxqt-config-session_cs_CZ.desktop deleted file mode 100644 index 06e41a4..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_cs_CZ.desktop +++ /dev/null @@ -1,4 +0,0 @@ -# Translations -Comment[cs_CZ]=Nastavit modul sezení LXQtu -GenericName[cs_CZ]=Nastavení sezení LXQtu -Name[cs_CZ]=Nastavení sezení LXQtu diff --git a/lxqt-config-session/translations/lxqt-config-session_da.desktop b/lxqt-config-session/translations/lxqt-config-session_da.desktop deleted file mode 100644 index 5668227..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_da.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[da]=Sessionsindstillinger -Comment[da]=Konfiguration af LXQt-sessioner diff --git a/lxqt-config-session/translations/lxqt-config-session_de.desktop b/lxqt-config-session/translations/lxqt-config-session_de.desktop deleted file mode 100644 index 1e8749f..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_de.desktop +++ /dev/null @@ -1,3 +0,0 @@ -Name[de]=Sitzungskonfiguration -GenericName[de]=LXQt Sitzungskonfiguration -Comment[de]=Die LXQt Sitzung konfigurieren diff --git a/lxqt-config-session/translations/lxqt-config-session_el.desktop b/lxqt-config-session/translations/lxqt-config-session_el.desktop deleted file mode 100644 index 362dae7..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_el.desktop +++ /dev/null @@ -1,4 +0,0 @@ -# Translations -Name[el]=Ρυθμίσεις συνεδρίας -GenericName[el]=Ρυθμίσεις συνεδρίας του LXQt -Comment[el]=Διαμόρφωση των συνεδριών LXQt diff --git a/lxqt-config-session/translations/lxqt-config-session_eo.desktop b/lxqt-config-session/translations/lxqt-config-session_eo.desktop deleted file mode 100644 index 3f6aeb5..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_eo.desktop +++ /dev/null @@ -1,4 +0,0 @@ -# Translations -Comment[eo]=Agordi modulon de seanco de LXQt -GenericName[eo]=Agordilo de seanco de LXQt -Name[eo]=Agordilo de seanco de LXQt diff --git a/lxqt-config-session/translations/lxqt-config-session_es.desktop b/lxqt-config-session/translations/lxqt-config-session_es.desktop deleted file mode 100644 index c5d7940..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_es.desktop +++ /dev/null @@ -1,4 +0,0 @@ -# Translations -Comment[es]=Configura el módulo de sesiones de LXQt -GenericName[es]=Configuración de sesiones LXQt -Name[es]=Configuración de sesiones LXQt diff --git a/lxqt-config-session/translations/lxqt-config-session_es_VE.desktop b/lxqt-config-session/translations/lxqt-config-session_es_VE.desktop deleted file mode 100644 index becc22c..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_es_VE.desktop +++ /dev/null @@ -1,4 +0,0 @@ -# Translations -Comment[es_VE]=Configuracion de modulo de LXQt -GenericName[es_VE]=Configuracion de sesion de LXQt -Name[es_VE]=Configuracion de sesion de LXQt diff --git a/lxqt-config-session/translations/lxqt-config-session_eu.desktop b/lxqt-config-session/translations/lxqt-config-session_eu.desktop deleted file mode 100644 index 0e22683..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_eu.desktop +++ /dev/null @@ -1,4 +0,0 @@ -# Translations -Comment[eu]=LXQt saioen konfigurazioa -GenericName[eu]=LXQt saioaren ezarpenak -Name[eu]=Saioaren ezarpenak diff --git a/lxqt-config-session/translations/lxqt-config-session_fi.desktop b/lxqt-config-session/translations/lxqt-config-session_fi.desktop deleted file mode 100644 index 28859eb..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_fi.desktop +++ /dev/null @@ -1,4 +0,0 @@ -# Translations -Comment[fi]=Hallinnoi LXQt:n istuntomoduulia -GenericName[fi]=LXQtin istunnonhallinta -Name[fi]=LXQtin istunnonhallinta diff --git a/lxqt-config-session/translations/lxqt-config-session_fr.desktop b/lxqt-config-session/translations/lxqt-config-session_fr.desktop deleted file mode 100644 index 1079695..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_fr.desktop +++ /dev/null @@ -1,4 +0,0 @@ -# Translations -Comment[fr]=Configurer le module 'session' de LXQt -GenericName[fr]=Paramétreur de session LXQt -Name[fr]=Paramétreur de session LXQt diff --git a/lxqt-config-session/translations/lxqt-config-session_hu.desktop b/lxqt-config-session/translations/lxqt-config-session_hu.desktop deleted file mode 100644 index 0d9529e..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_hu.desktop +++ /dev/null @@ -1,4 +0,0 @@ -# Translations -Comment[hu]=A LXQt munkamenetmodul beállítása -GenericName[hu]=LXQt munkamenetbeállíó -Name[hu]=LXQt munkamenetbeállíó diff --git a/lxqt-config-session/translations/lxqt-config-session_ia.desktop b/lxqt-config-session/translations/lxqt-config-session_ia.desktop deleted file mode 100644 index 26b0d99..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_ia.desktop +++ /dev/null @@ -1 +0,0 @@ -# Translations diff --git a/lxqt-config-session/translations/lxqt-config-session_id_ID.desktop b/lxqt-config-session/translations/lxqt-config-session_id_ID.desktop deleted file mode 100644 index 5e4f28c..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_id_ID.desktop +++ /dev/null @@ -1,4 +0,0 @@ -# Translations -Comment[id_ID]=Konfigurasi modul sesi LXQt -GenericName[id_ID]=Konfigurator Sesi LXQt -Name[id_ID]=Konfigurator Sesi LXQt diff --git a/lxqt-config-session/translations/lxqt-config-session_it.desktop b/lxqt-config-session/translations/lxqt-config-session_it.desktop deleted file mode 100644 index f1e3ecc..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_it.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[it]=Impostazioni della sessione -Comment[it]=Configura i moduli della sessione di LXQt diff --git a/lxqt-config-session/translations/lxqt-config-session_ja.desktop b/lxqt-config-session/translations/lxqt-config-session_ja.desktop deleted file mode 100644 index 6c04df4..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_ja.desktop +++ /dev/null @@ -1,4 +0,0 @@ -# Translations -Comment[ja]=LXQtセッションもジュールを設定 -GenericName[ja]=LXQtセッションの設定 -Name[ja]=LXQtセッションの設定 diff --git a/lxqt-config-session/translations/lxqt-config-session_ko.desktop b/lxqt-config-session/translations/lxqt-config-session_ko.desktop deleted file mode 100644 index 26b0d99..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_ko.desktop +++ /dev/null @@ -1 +0,0 @@ -# Translations diff --git a/lxqt-config-session/translations/lxqt-config-session_lt.desktop b/lxqt-config-session/translations/lxqt-config-session_lt.desktop deleted file mode 100644 index 59dac09..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_lt.desktop +++ /dev/null @@ -1,4 +0,0 @@ -# Translations -Comment[lt]=LXQt seansų konfigūravimas -GenericName[lt]=LXQt seansų nustatymai -Name[lt]=Seanso nustatymai diff --git a/lxqt-config-session/translations/lxqt-config-session_nl.desktop b/lxqt-config-session/translations/lxqt-config-session_nl.desktop deleted file mode 100644 index dd68619..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_nl.desktop +++ /dev/null @@ -1,4 +0,0 @@ -# Translations -Comment[nl]=Configureer LXQt sessie module -GenericName[nl]=LXQt sessie Configurator -Name[nl]=LXQt sessie Configurator diff --git a/lxqt-config-session/translations/lxqt-config-session_pl.desktop b/lxqt-config-session/translations/lxqt-config-session_pl.desktop deleted file mode 100644 index ca23381..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_pl.desktop +++ /dev/null @@ -1,4 +0,0 @@ -# Translations -Comment[pl]=Ustawienia sesji LXQt -GenericName[pl]=Ustawienia sesji LXQt -Name[pl]=Ustawienia sesji LXQt diff --git a/lxqt-config-session/translations/lxqt-config-session_pl_PL.desktop b/lxqt-config-session/translations/lxqt-config-session_pl_PL.desktop deleted file mode 100644 index 11f00a3..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_pl_PL.desktop +++ /dev/null @@ -1,4 +0,0 @@ -# Translations -Comment[pl_PL]=Konfiguruj moduł sesji LXQt -GenericName[pl_PL]=Konfigurator sesji LXQt -Name[pl_PL]=Konfigurator sesji LXQt diff --git a/lxqt-config-session/translations/lxqt-config-session_pt.desktop b/lxqt-config-session/translations/lxqt-config-session_pt.desktop deleted file mode 100644 index 9d5a07e..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_pt.desktop +++ /dev/null @@ -1,5 +0,0 @@ -# Translations -Name[pt]=Definições da sessão -GenericName[pt]=Definições da sessão LXQt -Comment[pt]=Configuração das sessões do LXQt - diff --git a/lxqt-config-session/translations/lxqt-config-session_pt_BR.desktop b/lxqt-config-session/translations/lxqt-config-session_pt_BR.desktop deleted file mode 100644 index 5bcd338..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_pt_BR.desktop +++ /dev/null @@ -1,4 +0,0 @@ -# Translations -Comment[pt_BR]=Módulo de configurador de sessão do LXQt -GenericName[pt_BR]=Configurador de sessão do LXQt -Name[pt_BR]=Configurador de sessão do LXQt diff --git a/lxqt-config-session/translations/lxqt-config-session_ro_RO.desktop b/lxqt-config-session/translations/lxqt-config-session_ro_RO.desktop deleted file mode 100644 index 1568fb9..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_ro_RO.desktop +++ /dev/null @@ -1,4 +0,0 @@ -# Translations -Comment[ro_RO]=Configurează modulul sesiune LXQt -GenericName[ro_RO]=Configurare sesiune LXQt -Name[ro_RO]=Configurare sesiune LXQt diff --git a/lxqt-config-session/translations/lxqt-config-session_ru.desktop b/lxqt-config-session/translations/lxqt-config-session_ru.desktop deleted file mode 100644 index 33bbd93..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_ru.desktop +++ /dev/null @@ -1,4 +0,0 @@ -# Translations -Comment[ru]=Настройки для сеансов LXQt -GenericName[ru]=Настройки сеанса LXQt -Name[ru]=Настройки сеанса \ No newline at end of file diff --git a/lxqt-config-session/translations/lxqt-config-session_sk.desktop b/lxqt-config-session/translations/lxqt-config-session_sk.desktop deleted file mode 100644 index 83c7e6f..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_sk.desktop +++ /dev/null @@ -1,4 +0,0 @@ -# Translations -Comment[sk]=Nastavenie relácie prostredia LXQt -GenericName[sk]=Nastavenie relácie prostredia LXQt -Name[sk]=Nastavenie relácie diff --git a/lxqt-config-session/translations/lxqt-config-session_sl.desktop b/lxqt-config-session/translations/lxqt-config-session_sl.desktop deleted file mode 100644 index 01f0a80..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_sl.desktop +++ /dev/null @@ -1,4 +0,0 @@ -# Translations -Comment[sl]=Nastavite modul seje za LXQt -GenericName[sl]=Nastavitev seje -Name[sl]=Nastavitev seje diff --git a/lxqt-config-session/translations/lxqt-config-session_sr.desktop b/lxqt-config-session/translations/lxqt-config-session_sr.desktop deleted file mode 100644 index e187025..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_sr.desktop +++ /dev/null @@ -1,4 +0,0 @@ -# Translations -Comment[sr]=Подесите Рејзоров модул сесије -GenericName[sr]=Подешавање сесије -Name[sr]=Подешавање сесије Рејзора diff --git a/lxqt-config-session/translations/lxqt-config-session_sr@ijekavian.desktop b/lxqt-config-session/translations/lxqt-config-session_sr@ijekavian.desktop deleted file mode 100644 index 810eb9a..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_sr@ijekavian.desktop +++ /dev/null @@ -1,3 +0,0 @@ -Name[sr@ijekavian]=Подешавање сесије Рејзора -Comment[sr@ijekavian]=Подесите Рејзоров модул сесије -GenericName[sr@ijekavian]=Подешавање сесије diff --git a/lxqt-config-session/translations/lxqt-config-session_sr@ijekavianlatin.desktop b/lxqt-config-session/translations/lxqt-config-session_sr@ijekavianlatin.desktop deleted file mode 100644 index 2885405..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_sr@ijekavianlatin.desktop +++ /dev/null @@ -1,3 +0,0 @@ -Name[sr@ijekavianlatin]=Podešavanje sesije Rejzora -Comment[sr@ijekavianlatin]=Podesite Rejzorov modul sesije -GenericName[sr@ijekavianlatin]=Podešavanje sesije diff --git a/lxqt-config-session/translations/lxqt-config-session_sr@latin.desktop b/lxqt-config-session/translations/lxqt-config-session_sr@latin.desktop deleted file mode 100644 index 78fcd6a..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_sr@latin.desktop +++ /dev/null @@ -1,4 +0,0 @@ -# Translations -Comment[sr@latin]=Podesite Rejzorov modul sesije -GenericName[sr@latin]=Podešavanje sesije -Name[sr@latin]=Podešavanje sesije Rejzora diff --git a/lxqt-config-session/translations/lxqt-config-session_th_TH.desktop b/lxqt-config-session/translations/lxqt-config-session_th_TH.desktop deleted file mode 100644 index 71b643f..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_th_TH.desktop +++ /dev/null @@ -1,4 +0,0 @@ -# Translations -Comment[th_TH]=ตั้งค่ามอดูลวาระงาน LXQt -GenericName[th_TH]=ตัวตั้งค่าวาระงาน LXQt -Name[th_TH]=ตัวตั้งค่าวาระงาน LXQt diff --git a/lxqt-config-session/translations/lxqt-config-session_tr.desktop b/lxqt-config-session/translations/lxqt-config-session_tr.desktop deleted file mode 100644 index a56027d..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_tr.desktop +++ /dev/null @@ -1,4 +0,0 @@ -# Translations -Comment[tr]=LXQt oturum modülünü yapılandır -GenericName[tr]=LXQt Oturum Yapılandırıcı -Name[tr]=LXQt Oturum Yapılandırıcı diff --git a/lxqt-config-session/translations/lxqt-config-session_uk.desktop b/lxqt-config-session/translations/lxqt-config-session_uk.desktop deleted file mode 100644 index 117a689..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_uk.desktop +++ /dev/null @@ -1,4 +0,0 @@ -# Translations -Comment[uk]=Налаштувати модуль сеансу LXQt -GenericName[uk]=Налаштування сеансу LXQt -Name[uk]=Налаштування сеансу LXQt diff --git a/lxqt-config-session/translations/lxqt-config-session_zh_CN.GB2312.desktop b/lxqt-config-session/translations/lxqt-config-session_zh_CN.GB2312.desktop deleted file mode 100644 index 26b0d99..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_zh_CN.GB2312.desktop +++ /dev/null @@ -1 +0,0 @@ -# Translations diff --git a/lxqt-config-session/translations/lxqt-config-session_zh_CN.desktop b/lxqt-config-session/translations/lxqt-config-session_zh_CN.desktop deleted file mode 100644 index de094fc..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_zh_CN.desktop +++ /dev/null @@ -1,4 +0,0 @@ -# Translations -Comment[zh_CN]=配置 LXQt 会话模块 -GenericName[zh_CN]=LXQt 会话配置 -Name[zh_CN]=LXQt 会话配置 diff --git a/lxqt-config-session/translations/lxqt-config-session_zh_TW.desktop b/lxqt-config-session/translations/lxqt-config-session_zh_TW.desktop deleted file mode 100644 index ad564c0..0000000 --- a/lxqt-config-session/translations/lxqt-config-session_zh_TW.desktop +++ /dev/null @@ -1,4 +0,0 @@ -# Translations -Comment[zh_TW]=LXQt會話模組設定 -GenericName[zh_TW]=LXQt會話設定 -Name[zh_TW]=LXQt會話設定 diff --git a/lxqt-config-session/userlocationspage.cpp b/lxqt-config-session/userlocationspage.cpp deleted file mode 100644 index 5348807..0000000 --- a/lxqt-config-session/userlocationspage.cpp +++ /dev/null @@ -1,203 +0,0 @@ -/* - * This file is part of the LXQt project. - * Copyright (C) 2015 Luís Pereira - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public License - * along with this library; if not, write to the Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA - */ - -#include "userlocationspage.h" - -#include -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - - -class UserLocationsPagePrivate { -public: - - UserLocationsPagePrivate(); - static const QStringList locationsName; - static const QStringList locationsToolTips; - - QList initialLocations; - QList locations; - QSignalMapper *signalMapper; - - void getUserDirs(); - void populate(); -}; - -UserLocationsPagePrivate::UserLocationsPagePrivate() - : locations(), - signalMapper(0) -{ -} - -// This labels haveto match XdgDirs::UserDirectories -const QStringList UserLocationsPagePrivate::locationsName = QStringList() << - qApp->translate("UserLocationsPrivate", "Desktop") << - qApp->translate("UserLocationsPrivate", "Downloads") << - qApp->translate("UserLocationsPrivate", "Templates") << - qApp->translate("UserLocationsPrivate", "Public Share") << - qApp->translate("UserLocationsPrivate", "Documents") << - qApp->translate("UserLocationsPrivate", "Music") << - qApp->translate("UserLocationsPrivate", "Pictures") << - qApp->translate("UserLocationsPrivate", "Videos"); - -const QStringList UserLocationsPagePrivate::locationsToolTips = QStringList() << - qApp->translate("UserLocationsPrivate", "Contains all the files which you see on your desktop") << - qApp->translate("UserLocationsPrivate", "Default folder to save your downloaded files") << - qApp->translate("UserLocationsPrivate", "Default folder to load or save templates from or to") << - qApp->translate("UserLocationsPrivate", "Default folder to publicly share your files") << - qApp->translate("UserLocationsPrivate", "Default folder to load or save documents from or to") << - qApp->translate("UserLocationsPrivate", "Default foldet to load or save music from or to") << - qApp->translate("UserLocationsPrivate", "Default folder to load or save pictures from or to") << - qApp->translate("UserLocationsPrivate", "Default folder to load or save videos from or to"); - -void UserLocationsPagePrivate::getUserDirs() -{ - const int N = locationsName.count(); - for(int i = 0; i < N; ++i) { - const QString userDir = XdgDirs::userDir(static_cast (i)); - const QDir dir(userDir); - initialLocations.append(dir.canonicalPath()); - } -} - -void UserLocationsPagePrivate::populate() -{ - const int N = initialLocations.count(); - - Q_ASSERT(N == locationsName.count()); - - for (int i = 0; i < N; ++i) { - locations.at(i)->setText(initialLocations.at(i)); - } -} - - -UserLocationsPage::UserLocationsPage(QWidget *parent) - : QWidget(parent), - d(new UserLocationsPagePrivate()) -{ - d->signalMapper = new QSignalMapper(this); - QGridLayout *gridLayout = new QGridLayout(this); - - int row = 0; - - QLabel *description = new QLabel(tr("Locations for Personal Files"), this); - QFont font; - font.setBold(true); - description->setFont(font); - - gridLayout->addWidget(description, row++, 0, 1, -1); - - for (int i = 0; i < d->locationsName.size(); ++i, ++row) { - QLabel *label = new QLabel(d->locationsName.at(i), this); - - QLineEdit *edit = new QLineEdit(this); - d->locations.append(edit); - edit->setClearButtonEnabled(true); - edit->setToolTip(d->locationsToolTips.at(i)); - - QToolButton *button = new QToolButton(this); - button->setIcon(XdgIcon::fromTheme(QStringLiteral("folder"))); - connect(button, SIGNAL(clicked()), d->signalMapper, SLOT(map())); - d->signalMapper->setMapping(button, i); - - gridLayout->addWidget(label, row, 0); - gridLayout->addWidget(edit, row, 1); - gridLayout->addWidget(button, row, 2); - } - connect(d->signalMapper, SIGNAL(mapped(int)), - this, SLOT(clicked(int))); - - QSpacerItem *verticalSpacer = new QSpacerItem(20, 40, QSizePolicy::Minimum, - QSizePolicy::Expanding); - gridLayout->addItem(verticalSpacer, row++, 1, 1, 1); - setLayout(gridLayout); - - d->getUserDirs(); - d->populate(); -} - -UserLocationsPage::~UserLocationsPage() -{ - // It's fine to delete a null pointer. No need to check. - delete d; - d = 0; -} - -void UserLocationsPage::restoreSettings() -{ - d->populate(); -} - -void UserLocationsPage::save() -{ - bool restartWarn = false; - - const int N = d->locations.count(); - for (int i = 0; i < N; ++i) { - QString s; - const QString text = d->locations.at(i)->text(); - - if (text.isEmpty()) { - s = XdgDirs::userDirDefault(static_cast (i)); - } else { - const QDir dir(text); - s = dir.canonicalPath(); - } - - if (s != d->initialLocations.at(i)) { - const bool ok = XdgDirs::setUserDir( - static_cast (i), s, true); - if (!ok) { - const int ret = QMessageBox::warning(this, - tr("LXQt Session Settings - User Directories"), - tr("An error ocurred while applying the settings for the %1 location").arg(d->locationsName.at(i)), - QMessageBox::Ok); - Q_UNUSED(ret); - } - restartWarn = true; - } - } - - if (restartWarn) - emit needRestart(); -} - -void UserLocationsPage::clicked(int id) -{ - const QString& currentDir = d->locations.at(id)->text(); - const QString dir = QFileDialog::getExistingDirectory(this, - tr("Choose Location"), - currentDir, - QFileDialog::ShowDirsOnly | QFileDialog::DontResolveSymlinks); - if (!dir.isEmpty()) { - const QDir dd(dir); - d->locations.at(id)->setText(dd.canonicalPath()); - } -} diff --git a/lxqt-config-session/userlocationspage.h b/lxqt-config-session/userlocationspage.h deleted file mode 100644 index 16482a2..0000000 --- a/lxqt-config-session/userlocationspage.h +++ /dev/null @@ -1,48 +0,0 @@ -/* - * This file is part of the LXQt project. - * Copyright (C) 2015 Luís Pereira - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public License - * along with this library; if not, write to the Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA - */ - -#ifndef USERLOCATIONSPAGE_H -#define USERLOCATIONSPAGE_H - -#include - -class UserLocationsPagePrivate; - -class UserLocationsPage : public QWidget { - Q_OBJECT - -public: - explicit UserLocationsPage(QWidget *parent = 0); - ~UserLocationsPage(); - -Q_SIGNALS: - void needRestart(); - -public Q_SLOTS: - void restoreSettings(); - void save(); - -private Q_SLOTS: - void clicked(int id); - -private: - UserLocationsPagePrivate *d; -}; - -#endif // USERLOCATIONSPAGE_H diff --git a/lxqt-leave/CMakeLists.txt b/lxqt-leave/CMakeLists.txt deleted file mode 100644 index 12d2241..0000000 --- a/lxqt-leave/CMakeLists.txt +++ /dev/null @@ -1,81 +0,0 @@ -project(lxqt-leave) - -set(CPP_FILES - main.cpp - leavedialog.cpp - listwidget.cpp -) - -set(H_FILES - leavedialog.h - listwidget.h -) - -set(UI_FILES - leavedialog.ui -) - - -# Translations ********************************** -lxqt_translate_desktop(DESKTOP_FILES - SOURCES - resources/lxqt-leave.desktop.in - resources/lxqt-hibernate.desktop.in - resources/lxqt-lockscreen.desktop.in - resources/lxqt-logout.desktop.in - resources/lxqt-reboot.desktop.in - resources/lxqt-shutdown.desktop.in - resources/lxqt-suspend.desktop.in -) - -lxqt_translate_ts(lxqt-leave_QM_FILES - UPDATE_TRANSLATIONS - ${UPDATE_TRANSLATIONS} - SOURCES - ${CPP_FILES} - ${UI_FILES} - ${H_FILES} - INSTALL_DIR - "${LXQT_TRANSLATIONS_DIR}/${PROJECT_NAME}" - PULL_TRANSLATIONS - ${PULL_TRANSLATIONS} - CLEAN_TRANSLATIONS - ${CLEAN_TRANSLATIONS} - TRANSLATIONS_REPO - ${TRANSLATIONS_REPO} - TRANSLATIONS_REFSPEC - ${TRANSLATIONS_REFSPEC} - REPO_SUBDIR - "lxqt-session/${PROJECT_NAME}" -) - -lxqt_app_translation_loader(lxqt-leave_QM_LOADER ${PROJECT_NAME}) -#************************************************ - - -add_executable(lxqt-leave - ${CPP_FILES} - ${DESKTOP_FILES} - ${lxqt-leave_QM_LOADER} - ${lxqt-leave_QM_FILES} -) - -target_link_libraries(lxqt-leave - lxqt -) - -install(TARGETS - lxqt-leave - RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}" - COMPONENT Runtime -) -install(FILES - ${DESKTOP_FILES} DESTINATION - "${CMAKE_INSTALL_DATAROOTDIR}/applications" - COMPONENT Runtime -) -install(FILES - resources/lxqt-leave.1 - DESTINATION "${CMAKE_INSTALL_MANDIR}/man1" - COMPONENT Runtime -) diff --git a/lxqt-leave/leavedialog.cpp b/lxqt-leave/leavedialog.cpp deleted file mode 100644 index 073a880..0000000 --- a/lxqt-leave/leavedialog.cpp +++ /dev/null @@ -1,133 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXQt - a lightweight, Qt based, desktop toolset - * http://razor-qt.org, http://lxde.org/ - * - * Copyright: 2010-2015 LXQt team - * Authors: - * Paulo Lieuthier - * - * This program or library is free software; you can redistribute it - * and/or modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General - * Public License along with this library; if not, write to the - * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#include "leavedialog.h" -#include - -LeaveDialog::LeaveDialog(QWidget* parent) - : QDialog(parent, Qt::Dialog | Qt::WindowStaysOnTopHint | Qt::CustomizeWindowHint), - ui(new Ui::LeaveDialog), - mPower(new LXQt::Power(this)), - mPowerManager(new LXQt::PowerManager(this)), - mScreensaver(new LXQt::ScreenSaver(this)) -{ - ui->setupUi(this); - - /* This is a special dialog. We want to make it hard to ignore. - We make it: - * Undraggable - * Frameless - * Stays on top of all other windows - * Present in all desktops - */ - setWindowFlags((Qt::CustomizeWindowHint | Qt::FramelessWindowHint | - Qt::WindowStaysOnTopHint | Qt::X11BypassWindowManagerHint)); - - // populate the items - QListWidgetItem * item = new QListWidgetItem{QIcon::fromTheme(QStringLiteral("system-log-out")), tr("Logout")}; - item->setData(Qt::UserRole, LXQt::Power::PowerLogout); - if (!mPower->canAction(LXQt::Power::PowerLogout)) - item->setFlags(item->flags() & ~Qt::ItemIsEnabled); - ui->listWidget->addItem(item); - item = new QListWidgetItem{QIcon::fromTheme(QStringLiteral("system-shutdown")), tr("Shutdown")}; - item->setData(Qt::UserRole, LXQt::Power::PowerShutdown); - if (!mPower->canAction(LXQt::Power::PowerShutdown)) - item->setFlags(item->flags() & ~Qt::ItemIsEnabled); - ui->listWidget->addItem(item); - item = new QListWidgetItem{QIcon::fromTheme(QStringLiteral("system-suspend")), tr("Suspend")}; - item->setData(Qt::UserRole, LXQt::Power::PowerSuspend); - if (!mPower->canAction(LXQt::Power::PowerSuspend)) - item->setFlags(item->flags() & ~Qt::ItemIsEnabled); - ui->listWidget->addItem(item); - item = new QListWidgetItem{QIcon::fromTheme(QStringLiteral("system-lock-screen")), tr("Lock screen")}; - item->setData(Qt::UserRole, -1); - ui->listWidget->addItem(item); - item = new QListWidgetItem{QIcon::fromTheme(QStringLiteral("system-reboot")), tr("Reboot")}; - item->setData(Qt::UserRole, LXQt::Power::PowerReboot); - if (!mPower->canAction(LXQt::Power::PowerReboot)) - item->setFlags(item->flags() & ~Qt::ItemIsEnabled); - ui->listWidget->addItem(item); - item = new QListWidgetItem{QIcon::fromTheme(QStringLiteral("system-suspend-hibernate")), tr("Hibernate")}; - item->setData(Qt::UserRole, LXQt::Power::PowerHibernate); - if (!mPower->canAction(LXQt::Power::PowerHibernate)) - item->setFlags(item->flags() & ~Qt::ItemIsEnabled); - ui->listWidget->addItem(item); - - ui->listWidget->setRows(2); - ui->listWidget->setColumns(3); - - connect(ui->listWidget, &QAbstractItemView::activated, this, [this] (const QModelIndex & index) { - bool ok = false; - const int action = index.data(Qt::UserRole).toInt(&ok); - if (!ok) - { - qWarning("Invalid internal logic, no UserRole set!?"); - return; - } - close(); - switch (action) - { - case LXQt::Power::PowerLogout: - mPowerManager->logout(); - break; - case LXQt::Power::PowerShutdown: - mPowerManager->shutdown(); - break; - case LXQt::Power::PowerSuspend: - mPowerManager->suspend(); - break; - case -1: - { - QEventLoop loop; - connect(mScreensaver, &LXQt::ScreenSaver::done, &loop, &QEventLoop::quit); - mScreensaver->lockScreen(); - loop.exec(); - } - break; - case LXQt::Power::PowerReboot: - mPowerManager->reboot(); - break; - case LXQt::Power::PowerHibernate: - mPowerManager->hibernate(); - break; - } - }); - connect(ui->cancelButton, &QAbstractButton::clicked, this, [this] { close(); }); -} - -LeaveDialog::~LeaveDialog() -{ - delete ui; -} - -void LeaveDialog::resizeEvent(QResizeEvent* /*event*/) -{ - QRect screen = QApplication::desktop()->screenGeometry(); - move((screen.width() - this->width()) / 2, - (screen.height() - this->height()) / 2); - -} diff --git a/lxqt-leave/leavedialog.h b/lxqt-leave/leavedialog.h deleted file mode 100644 index 75b1f74..0000000 --- a/lxqt-leave/leavedialog.h +++ /dev/null @@ -1,65 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXQt - a lightweight, Qt based, desktop toolset - * http://razor-qt.org, http://lxde.org/ - * - * Copyright: 2010-2015 LXQt team - * Authors: - * Paulo Lieuthier - * - * This program or library is free software; you can redistribute it - * and/or modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General - * Public License along with this library; if not, write to the - * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#ifndef LEAVEDIALOG_H -#define LEAVEDIALOG_H - -#include "ui_leavedialog.h" - -#include -#include -#include -#include -#include - -namespace Ui { - class LeaveDialog; -} - -class LeaveDialog : public QDialog -{ - Q_OBJECT - -public: - explicit LeaveDialog(QWidget *parent = 0); - ~LeaveDialog(); - -protected: - virtual void resizeEvent(QResizeEvent* event) override; - -private: - Ui::LeaveDialog *ui; - // LXQt::Power is used to know if the actions are doable, while - // LXQt::PowerManager is used to trigger the actions, while - // obeying the user option to ask or not for confirmation - LXQt::Power *mPower; - LXQt::PowerManager *mPowerManager; - LXQt::ScreenSaver *mScreensaver; -}; - - -#endif diff --git a/lxqt-leave/leavedialog.ui b/lxqt-leave/leavedialog.ui deleted file mode 100644 index c418949..0000000 --- a/lxqt-leave/leavedialog.ui +++ /dev/null @@ -1,151 +0,0 @@ - - - LeaveDialog - - - - 0 - 0 - 456 - 372 - - - - - 0 - 0 - - - - Leave - - - - 9 - - - 0 - - - 18 - - - - - - - - Qt::Horizontal - - - - 170 - 20 - - - - - - - - Cancel - - - - .. - - - Qt::ToolButtonTextBesideIcon - - - - - - - - - - QFrame::NoFrame - - - <html><head/><body><p><span style=" font-size:12pt;">What do you want the computer to do?</span></p></body></html> - - - Qt::AutoText - - - Qt::AlignCenter - - - - - - - Qt::NoContextMenu - - - #listWidget { background-color: palette(window); } -QAbstractItemView { activate-on-singleclick: 1; } - - - QFrame::NoFrame - - - Qt::ScrollBarAlwaysOff - - - Qt::ScrollBarAlwaysOff - - - QAbstractScrollArea::AdjustToContents - - - false - - - QAbstractItemView::NoEditTriggers - - - true - - - QAbstractItemView::NoSelection - - - - 64 - 64 - - - - Qt::ElideNone - - - QListView::LeftToRight - - - true - - - 7 - - - true - - - - - label - listWidget - widget_2 - - - - ListWidget - QListWidget -
listwidget.h
-
-
- - -
diff --git a/lxqt-leave/listwidget.cpp b/lxqt-leave/listwidget.cpp deleted file mode 100644 index 84826ce..0000000 --- a/lxqt-leave/listwidget.cpp +++ /dev/null @@ -1,241 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXQt - a lightweight, Qt based, desktop toolset - * http://lxqt.org/ - * - * Copyright: 2017 LXQt team - * Authors: - * Palo Kisa - * - * This program or library is free software; you can redistribute it - * and/or modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General - * Public License along with this library; if not, write to the - * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#include "listwidget.h" -#include -#include -#include - -/*! - * This private delegate does: - * - returns unified sizeHint() -> maximum of all items in (list) model - * - cahes the sizeHint() to not iterate over all items and checking their size - * - overrides decoration position to Qt::Top - * - gives the items margins (increasing sizeHint()) ~~and mimics Button visual~~ - * - overrides painting the focus around the whole item (with the decoration) - * - * \note It is a single purpose delegate and expects, that the model - * never changes (cached sizeHint() is never invalidated). - */ -class ItemDelegate : public QItemDelegate -{ -public: - static constexpr QMargins MARGINS{5, 5, 5, 5}; -public: - using QItemDelegate::QItemDelegate; - virtual QSize sizeHint(const QStyleOptionViewItem &option, const QModelIndex &index) const override - { - if (mItemSize.isValid()) - return mItemSize; - - // compute maximum item size - QStyleOptionViewItem opt = option; - opt.decorationPosition = QStyleOptionViewItem::Top; - QAbstractListModel const * model = qobject_cast(index.model()); - for (QModelIndex i = model->index(0); i.isValid(); i = model->index(i.row() + 1)) - { - mItemSize = mItemSize.expandedTo(QItemDelegate::sizeHint(opt, i)); - } - mItemSize += {MARGINS.left() + MARGINS.right(), MARGINS.top() + MARGINS.bottom()}; // add some margins - return mItemSize; - } - - virtual void paint(QPainter *painter, const QStyleOptionViewItem &option, const QModelIndex &index) const override - { - /* - // mimic the button visual - QStyleOption button_option; - button_option.initFrom(option.widget); - button_option.rect = option.rect; - if (!(option.state & QStyle::State_HasFocus)) - button_option.state &= ~QStyle::State_HasFocus; - QStyle * style = option.widget->style() ? option.widget->style() : QApplication::style(); - style->drawPrimitive(QStyle::PE_PanelButtonTool, &button_option, painter, option.widget); - */ - QStyleOptionViewItem opt = option; - opt.decorationPosition = QStyleOptionViewItem::Top; - opt.displayAlignment = Qt::AlignHCenter | Qt::AlignTop; - return QItemDelegate::paint(painter, opt, index); - } - -protected: - // Note: We want to paint the focus rectangle around the whole (text+icon) - // (default in QItemDelegate is to draw the focus only in text rectangle) - virtual void drawFocus(QPainter *painter - , const QStyleOptionViewItem &option - , const QRect &/*rect*/) const override - { - // don't override the rectangle to the text-only - return QItemDelegate::drawFocus(painter, option, option.rect); - } - - virtual void drawDisplay(QPainter *painter - , const QStyleOptionViewItem &option - , const QRect &rect - , const QString &text) const override - { - // shrink (and move to bottom) the text rectangle - QRect r = rect.adjusted(0, MARGINS.top(), 0, 0); - return QItemDelegate::drawDisplay(painter, option, r, text); - } - - virtual void drawDecoration(QPainter *painter - , const QStyleOptionViewItem &option - , const QRect &rect - , const QPixmap &pixmap) const override - { - // move to bottom the pixmap rectangle - QRect r = rect.translated(0, MARGINS.top()); - return QItemDelegate::drawDecoration(painter, option, r, pixmap); - } -private: - mutable QSize mItemSize; //!< the cached (unified/max) item size -}; -constexpr QMargins ItemDelegate::MARGINS; - -ListWidget::ListWidget(QWidget * parent/* = nullptr*/) - : QListWidget{parent} - , mRows(3) - , mColumns(3) -{ - ItemDelegate * delegate = new ItemDelegate{this}; - { - QScopedPointer old_del{itemDelegate()}; - setItemDelegate(delegate); - } -} - -void ListWidget::setRows(int rows) -{ - mRows = rows; -} - -void ListWidget::setColumns(int columns) -{ - mColumns = columns; -} - -QSize ListWidget::viewportSizeHint() const -{ - QSize size = sizeHintForIndex(model()->index(0, 0)); - size.rwidth() = size.width() * mColumns + spacing() * mColumns * 2 + 1; - size.rheight() = size.height() * mRows + spacing() * mRows * 2 + 1; - return size; -} - -QModelIndex ListWidget::moveCursor(CursorAction cursorAction, Qt::KeyboardModifiers/* modifiers*/) -{ - QModelIndex index = currentIndex(); - int count = model()->rowCount(rootIndex()); - int current = 0; - if (index.isValid()) - { - current = index.row(); - index = QModelIndex{}; // setting to invalid to get inside the for loop (move the position) - } else - { - current = cursorAction == MovePrevious ? count - 1 : 0; - index = model()->index(current, 0, rootIndex()); - } - - // if not enabled, try to find any next enabled - for (int tries = 1; tries < count && 0 == (model()->flags(index) & Qt::ItemIsEnabled); ++tries) - { - int next; - switch (cursorAction) - { - case MoveUp: - case MovePageUp: - next = (current - mColumns) % count; - break; - case MoveDown: - case MovePageDown: - next = (current + mColumns) % count; - break; - case MoveLeft: - if (0 == (current % mColumns)) - current += mColumns; - // fall through - case MovePrevious: - if (current == 0) - return QModelIndex{}; - next = (current - 1) % count; - break; - case MoveRight: - if ((mColumns - 1) == (current % mColumns)) - current -= mColumns; - // fall through - case MoveNext: - if (current == count - 1) - return QModelIndex{}; - next = (current + 1) % count; - break; - case MoveHome: - next = 0; - break; - case MoveEnd: - next = count - 1; - break; - } - if (next < 0) - next += count; - - index = model()->index(next, 0, rootIndex()); - current = next; - } - return index; - -} - -void ListWidget::keyPressEvent(QKeyEvent * event) -{ - if (event->key() == Qt::Key_Space) - { - // mimic the "enter" to fire activated - QKeyEvent k{event->type(), Qt::Key_Enter, event->modifiers(), event->text(), event->isAutoRepeat(), static_cast(event->count())}; - QListWidget::keyPressEvent(&k); - event->setAccepted(k.isAccepted()); - return; - } - return QListWidget::keyPressEvent(event); -} - -void ListWidget::focusInEvent(QFocusEvent * event) -{ - switch (event->reason()) - { - case Qt::TabFocusReason: - setCurrentIndex(model()->index(0, 0, rootIndex())); - break; - case Qt::BacktabFocusReason: - setCurrentIndex(model()->index(model()->rowCount(rootIndex()) - 1, 0, rootIndex())); - break; - default: - break; - } - return QListWidget::focusInEvent(event); -} diff --git a/lxqt-leave/listwidget.h b/lxqt-leave/listwidget.h deleted file mode 100644 index 02d9c1e..0000000 --- a/lxqt-leave/listwidget.h +++ /dev/null @@ -1,52 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXQt - a lightweight, Qt based, desktop toolset - * http://lxqt.org/ - * - * Copyright: 2017 LXQt team - * Authors: - * Palo Kisa - * - * This program or library is free software; you can redistribute it - * and/or modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General - * Public License along with this library; if not, write to the - * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#include - -/*! - * Single purpose QListWidget with unified item sizes (based on the - * biggest item) and showing rows x columns items. - * - * \note It expects that items aren't ever changed after show(). - */ -class ListWidget : public QListWidget -{ -public: - ListWidget(QWidget * parent = nullptr); - void setRows(int rows); - void setColumns(int columns); - -protected: - virtual QSize viewportSizeHint() const override; - virtual QModelIndex moveCursor(CursorAction cursorAction, Qt::KeyboardModifiers modifiers) override; - virtual void keyPressEvent(QKeyEvent * event) override; - virtual void focusInEvent(QFocusEvent * event) override; - -private: - int mRows; - int mColumns; -}; diff --git a/lxqt-leave/main.cpp b/lxqt-leave/main.cpp deleted file mode 100644 index ebec59c..0000000 --- a/lxqt-leave/main.cpp +++ /dev/null @@ -1,118 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXDE-Qt - a lightweight, Qt based, desktop toolset - * http://razor-qt.org - * - * Copyright: 2010-2011 Razor team - * Authors: - * Petr Vanek - * - * This program or library is free software; you can redistribute it - * and/or modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - - * You should have received a copy of the GNU Lesser General - * Public License along with this library; if not, write to the - * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#include -#include -#include -#include -#include -#include -#include - -#include "leavedialog.h" - -int main(int argc, char *argv[]) -{ - LXQt::SingleApplication a(argc, argv); - a.setAttribute(Qt::AA_UseHighDpiPixmaps, true); - - LXQt::Translator::translateApplication(); - - LXQt::PowerManager powermanager(&a); - LXQt::ScreenSaver screensaver(&a); - - QCommandLineParser parser; - parser.setApplicationDescription(QStringLiteral("LXQt Leave")); - const QString VERINFO = QStringLiteral(LXQT_SESSION_VERSION - "\nliblxqt " LXQT_VERSION - "\nQt " QT_VERSION_STR); - a.setApplicationVersion(VERINFO); - - parser.addHelpOption(); - parser.addVersionOption(); - - QCommandLineOption logoutOption(QStringLiteral("logout"), QCoreApplication::translate("main", "Logout.")); - parser.addOption(logoutOption); - - QCommandLineOption lockscreenOption(QStringLiteral("lockscreen"), QCoreApplication::translate("main", "Lockscreen.")); - parser.addOption(lockscreenOption); - - QCommandLineOption suspendOption(QStringLiteral("suspend"), QCoreApplication::translate("main", "Suspend.")); - parser.addOption(suspendOption); - - QCommandLineOption hibernateOption(QStringLiteral("hibernate"), QCoreApplication::translate("main", "Hibernate.")); - parser.addOption(hibernateOption); - - QCommandLineOption shutdownOption(QStringLiteral("shutdown"), QCoreApplication::translate("main", "Shutdown.")); - parser.addOption(shutdownOption); - - QCommandLineOption rebootOption(QStringLiteral("reboot"), QCoreApplication::translate("main", "Reboot.")); - parser.addOption(rebootOption); - - parser.process(a); - - if (parser.isSet(logoutOption)) { - powermanager.logout(); - return 0; - } - - if (parser.isSet(lockscreenOption)) { - a.connect(&screensaver, &LXQt::ScreenSaver::done, &a, &LXQt::Application::quit); - screensaver.lockScreen(); - a.exec(); - return 0; - } - - if (parser.isSet(suspendOption)) { - powermanager.suspend(); - return 0; - } - - if (parser.isSet(hibernateOption)) { - powermanager.hibernate(); - return 0; - } - - if (parser.isSet(shutdownOption)) { - powermanager.shutdown(); - return 0; - } - - if (parser.isSet(rebootOption)) { - powermanager.reboot(); - return 0; - } - - LeaveDialog dialog; - a.setActivationWindow(&dialog); - dialog.setFixedSize(dialog.sizeHint()); - dialog.setGeometry(QStyle::alignedRect(Qt::LeftToRight, - Qt::AlignCenter, - dialog.sizeHint(), - qApp->desktop()->screenGeometry(QCursor::pos()))); - return dialog.exec(); -} diff --git a/lxqt-leave/resources/lxqt-hibernate.desktop.in b/lxqt-leave/resources/lxqt-hibernate.desktop.in deleted file mode 100644 index 923b2a2..0000000 --- a/lxqt-leave/resources/lxqt-hibernate.desktop.in +++ /dev/null @@ -1,11 +0,0 @@ -[Desktop Entry] -Type=Application -Name=Hibernate -GenericName=Hibernate -Comment=hibernate the machine -Exec=lxqt-leave --hibernate -Icon=system-suspend-hibernate -Categories=System;X-Leave; -OnlyShowIn=LXQt; - -#TRANSLATIONS_DIR=../translations diff --git a/lxqt-leave/resources/lxqt-leave.1 b/lxqt-leave/resources/lxqt-leave.1 deleted file mode 100644 index b38d829..0000000 --- a/lxqt-leave/resources/lxqt-leave.1 +++ /dev/null @@ -1,49 +0,0 @@ -.TH lxqt-leave 1 "2015-11-05" "LXQt 0.10.0" "LXQt Leave Session Module" -.SH NAME -\fBlxqt-leave\fR \- Dialog to easily select logout, reboot, shutdown, -suspend, hibernate, and lock screen -.SH SYNOPSIS -\fBlxqt-leave\fR [\fIargument\fR] -.SH DESCRIPTION -\fBlxqt-leave\fR is a graphical Qt tool for easily triggering leave session -actions: logout, reboot, shutdown, hibernate, and lock screen. If run with -an argument, the dialog is not shown and the action is executed directly. -.SH OPTIONS -.PP -The options which apply to the \fBlxqt-leave\fR command are: -.PP -\fB\-\-logout\fR -.RE -.PP -\fB\-\-lockscreen\fR -.RE -.PP -\fB\-\-suspend\fR -.RE -.PP -\fB\-\-hibernate\fR -.RE -.PP -\fB\-\-shutdown\fR -.RE -.PP -\fB\-\-reboot\fR -.RE -.PP -\fB\-\-help\fR -.RE -.SH "REPORTING BUGS" -Report bugs to https://github.com/lxde/lxqt/issues -.SH "SEE ALSO" -.\" any module must refer to the session application, for module overview and initiation -\fBstartlxqt.1\fR LXQt session initialization and launch script (e.g. in \fB.xinitrc\fR) -.P -\fBlxqt-session.1\fR LXQt \fIoverview\fR and complete session environment -.P -\fBlxqt-config-session.1\fR LXQt default and autostart applications settings, -plus environment settings -.P -\fBlxqt-config.1\fR LXQt settings Configuration Center interface -.P -.SH AUTHOR -This manual page was created by \fBPaulo Lieuthier\fR \fI\fR for the \fBLXQt\fR project. diff --git a/lxqt-leave/resources/lxqt-leave.desktop.in b/lxqt-leave/resources/lxqt-leave.desktop.in deleted file mode 100644 index db8a620..0000000 --- a/lxqt-leave/resources/lxqt-leave.desktop.in +++ /dev/null @@ -1,11 +0,0 @@ -[Desktop Entry] -Type=Application -Name=Leave -GenericName=Leave -Comment=Leave dialog -Exec=lxqt-leave -Icon=system-shutdown -Categories=System;X-Leave; -OnlyShowIn=LXQt; - -#TRANSLATIONS_DIR=../translations diff --git a/lxqt-leave/resources/lxqt-lockscreen.desktop.in b/lxqt-leave/resources/lxqt-lockscreen.desktop.in deleted file mode 100644 index 81dea85..0000000 --- a/lxqt-leave/resources/lxqt-lockscreen.desktop.in +++ /dev/null @@ -1,11 +0,0 @@ -[Desktop Entry] -Type=Application -Name=Lock Screen -GenericName=Lock Screen -Comment=Lock the current session -Exec=lxqt-leave --lockscreen -Icon=system-lock-screen -Categories=System;Screensaver; -OnlyShowIn=LXQt; - -#TRANSLATIONS_DIR=../translations diff --git a/lxqt-leave/resources/lxqt-logout.desktop.in b/lxqt-leave/resources/lxqt-logout.desktop.in deleted file mode 100644 index a4da833..0000000 --- a/lxqt-leave/resources/lxqt-logout.desktop.in +++ /dev/null @@ -1,11 +0,0 @@ -[Desktop Entry] -Type=Application -Name=Logout -GenericName=Logout -Comment=Logout from the current session -Exec=lxqt-leave --logout -Icon=system-log-out -Categories=System;X-Leave; -OnlyShowIn=LXQt; - -#TRANSLATIONS_DIR=../translations diff --git a/lxqt-leave/resources/lxqt-reboot.desktop.in b/lxqt-leave/resources/lxqt-reboot.desktop.in deleted file mode 100644 index bb10c4c..0000000 --- a/lxqt-leave/resources/lxqt-reboot.desktop.in +++ /dev/null @@ -1,11 +0,0 @@ -[Desktop Entry] -Type=Application -Name=Reboot -GenericName=Reboot -Comment=reboot the machine -Exec=lxqt-leave --reboot -Icon=system-reboot -Categories=System;X-Leave; -OnlyShowIn=LXQt; - -#TRANSLATIONS_DIR=../translations diff --git a/lxqt-leave/resources/lxqt-shutdown.desktop.in b/lxqt-leave/resources/lxqt-shutdown.desktop.in deleted file mode 100644 index a1f069d..0000000 --- a/lxqt-leave/resources/lxqt-shutdown.desktop.in +++ /dev/null @@ -1,11 +0,0 @@ -[Desktop Entry] -Type=Application -Name=Shutdown -GenericName=Shutdown -Comment=shutdown the machine -Exec=lxqt-leave --shutdown -Icon=system-shutdown -Categories=System;X-Leave; -OnlyShowIn=LXQt; - -#TRANSLATIONS_DIR=../translations diff --git a/lxqt-leave/resources/lxqt-suspend.desktop.in b/lxqt-leave/resources/lxqt-suspend.desktop.in deleted file mode 100644 index 44a0b87..0000000 --- a/lxqt-leave/resources/lxqt-suspend.desktop.in +++ /dev/null @@ -1,11 +0,0 @@ -[Desktop Entry] -Type=Application -Name=Suspend -GenericName=Suspend -Comment=suspend the machine -Exec=lxqt-leave --suspend -Icon=system-suspend -Categories=System;X-Leave; -OnlyShowIn=LXQt; - -#TRANSLATIONS_DIR=../translations diff --git a/lxqt-leave/translations/lxqt-hibernate_ar.desktop b/lxqt-leave/translations/lxqt-hibernate_ar.desktop deleted file mode 100644 index 3350526..0000000 --- a/lxqt-leave/translations/lxqt-hibernate_ar.desktop +++ /dev/null @@ -1,3 +0,0 @@ -Comment[ar]=أسبت الجهاز -Name[ar]=أسبت -GenericName[ar]=أسبت diff --git a/lxqt-leave/translations/lxqt-hibernate_ca.desktop b/lxqt-leave/translations/lxqt-hibernate_ca.desktop deleted file mode 100644 index fe94eb2..0000000 --- a/lxqt-leave/translations/lxqt-hibernate_ca.desktop +++ /dev/null @@ -1,4 +0,0 @@ -#Translations -Name[ca]=Hiberna -GenericName[ca]=Hiberna -Comment[ca]=Posa en hibernació la màquina diff --git a/lxqt-leave/translations/lxqt-hibernate_da.desktop b/lxqt-leave/translations/lxqt-hibernate_da.desktop deleted file mode 100644 index 92f206b..0000000 --- a/lxqt-leave/translations/lxqt-hibernate_da.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[da]=Dvale -Comment[da]=Sæt maskinen i dvale diff --git a/lxqt-leave/translations/lxqt-hibernate_de.desktop b/lxqt-leave/translations/lxqt-hibernate_de.desktop deleted file mode 100644 index ac367be..0000000 --- a/lxqt-leave/translations/lxqt-hibernate_de.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Comment[de]=Rechner in Tiefschlaf versetzen -Name[de]=Tiefschlaf diff --git a/lxqt-leave/translations/lxqt-hibernate_el.desktop b/lxqt-leave/translations/lxqt-hibernate_el.desktop deleted file mode 100644 index b96a374..0000000 --- a/lxqt-leave/translations/lxqt-hibernate_el.desktop +++ /dev/null @@ -1,4 +0,0 @@ -#Translations -Name[el]=Νάρκη -GenericName[el]=Νάρκη -Comment[el]=Nάρκωση του υπολογιστή diff --git a/lxqt-leave/translations/lxqt-hibernate_eu.desktop b/lxqt-leave/translations/lxqt-hibernate_eu.desktop deleted file mode 100644 index 973ea02..0000000 --- a/lxqt-leave/translations/lxqt-hibernate_eu.desktop +++ /dev/null @@ -1,4 +0,0 @@ -#Translations -Name[eu]=Hibernatu -GenericName[eu]=Hibernatu -Comment[eu]=Hibernatu ordenagailua diff --git a/lxqt-leave/translations/lxqt-hibernate_fr.desktop b/lxqt-leave/translations/lxqt-hibernate_fr.desktop deleted file mode 100644 index 83db6d5..0000000 --- a/lxqt-leave/translations/lxqt-hibernate_fr.desktop +++ /dev/null @@ -1,4 +0,0 @@ -#TRANSLATIONS -Name[fr]=Hivernation -GenericName[fr]=Hivernation -Comment[fr]=Hivernation de l'ordinateur diff --git a/lxqt-leave/translations/lxqt-hibernate_hu.desktop b/lxqt-leave/translations/lxqt-hibernate_hu.desktop deleted file mode 100644 index b5b20c5..0000000 --- a/lxqt-leave/translations/lxqt-hibernate_hu.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Comment[hu]=Mélykészenléti állapot -Name[hu]=Mélykészenlét diff --git a/lxqt-leave/translations/lxqt-hibernate_it.desktop b/lxqt-leave/translations/lxqt-hibernate_it.desktop deleted file mode 100644 index 1e715b2..0000000 --- a/lxqt-leave/translations/lxqt-hibernate_it.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Name[it]=Iberna -Comment[it]=Ibernare il computer diff --git a/lxqt-leave/translations/lxqt-hibernate_ja.desktop b/lxqt-leave/translations/lxqt-hibernate_ja.desktop deleted file mode 100644 index 80ea706..0000000 --- a/lxqt-leave/translations/lxqt-hibernate_ja.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Name[ja]=ハイバネート -Comment[ja]=PCをハイバネートします diff --git a/lxqt-leave/translations/lxqt-hibernate_lt.desktop b/lxqt-leave/translations/lxqt-hibernate_lt.desktop deleted file mode 100644 index 00c83f1..0000000 --- a/lxqt-leave/translations/lxqt-hibernate_lt.desktop +++ /dev/null @@ -1,3 +0,0 @@ -Name[lt]=Užmigdyti -GenericName[lt]=Užmigdyti -Comment[lt]=Užmigdyti kompiuterį diff --git a/lxqt-leave/translations/lxqt-hibernate_pl.desktop b/lxqt-leave/translations/lxqt-hibernate_pl.desktop deleted file mode 100644 index ccd0307..0000000 --- a/lxqt-leave/translations/lxqt-hibernate_pl.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Name[pl]=Hibernuj -Comment[pl]=Hibernuj komputer diff --git a/lxqt-leave/translations/lxqt-hibernate_pt.desktop b/lxqt-leave/translations/lxqt-hibernate_pt.desktop deleted file mode 100644 index 99f17a4..0000000 --- a/lxqt-leave/translations/lxqt-hibernate_pt.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Name[pt]=Hibernar -Comment[pt]=Hibernar o computador diff --git a/lxqt-leave/translations/lxqt-hibernate_ru.desktop b/lxqt-leave/translations/lxqt-hibernate_ru.desktop deleted file mode 100644 index 16a7338..0000000 --- a/lxqt-leave/translations/lxqt-hibernate_ru.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Name[ru]=Спящий режим -Comment[ru]=Перевести компьютер в спящий режим diff --git a/lxqt-leave/translations/lxqt-leave_ar.desktop b/lxqt-leave/translations/lxqt-leave_ar.desktop deleted file mode 100644 index c1c4a09..0000000 --- a/lxqt-leave/translations/lxqt-leave_ar.desktop +++ /dev/null @@ -1,3 +0,0 @@ -Name[ar]=اترك -GenericName[ar]=اترك -Comment[ar]=حواريّ التّرك diff --git a/lxqt-leave/translations/lxqt-leave_ca.desktop b/lxqt-leave/translations/lxqt-leave_ca.desktop deleted file mode 100644 index 690544f..0000000 --- a/lxqt-leave/translations/lxqt-leave_ca.desktop +++ /dev/null @@ -1,4 +0,0 @@ -#Translation -Name[ca]=Sortida -GenericName[ca]=Sortida -Comment[ca]=Diàleg de sortida diff --git a/lxqt-leave/translations/lxqt-leave_da.desktop b/lxqt-leave/translations/lxqt-leave_da.desktop deleted file mode 100644 index 480eb6e..0000000 --- a/lxqt-leave/translations/lxqt-leave_da.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[da]=Afslut -Comment[da]=Afslut-dialog diff --git a/lxqt-leave/translations/lxqt-leave_de.desktop b/lxqt-leave/translations/lxqt-leave_de.desktop deleted file mode 100644 index 285fb05..0000000 --- a/lxqt-leave/translations/lxqt-leave_de.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Name[de]=Verlassen -Comment[de]=Beenden-Dialog diff --git a/lxqt-leave/translations/lxqt-leave_el.desktop b/lxqt-leave/translations/lxqt-leave_el.desktop deleted file mode 100644 index 8e2c262..0000000 --- a/lxqt-leave/translations/lxqt-leave_el.desktop +++ /dev/null @@ -1,4 +0,0 @@ -#Translation -Name[el]=Εγκατάλειψη -GenericName[el]=Εγκατάλειψη -Comment[el]=Διάλογος εγκατάλειψης diff --git a/lxqt-leave/translations/lxqt-leave_eu.desktop b/lxqt-leave/translations/lxqt-leave_eu.desktop deleted file mode 100644 index 920e90a..0000000 --- a/lxqt-leave/translations/lxqt-leave_eu.desktop +++ /dev/null @@ -1,4 +0,0 @@ -#Translation -Name[eu]=Utzi -GenericName[eu]=Utzi -Comment[eu]=Utzi elkarrizketa-koadroa diff --git a/lxqt-leave/translations/lxqt-leave_fr.desktop b/lxqt-leave/translations/lxqt-leave_fr.desktop deleted file mode 100644 index b885e09..0000000 --- a/lxqt-leave/translations/lxqt-leave_fr.desktop +++ /dev/null @@ -1,4 +0,0 @@ -#TRANSLATIONS -Name[fr]=Quitter -GenericName[fr]=Quitter -Comment[fr]=Dialogue pour quitter diff --git a/lxqt-leave/translations/lxqt-leave_hu.desktop b/lxqt-leave/translations/lxqt-leave_hu.desktop deleted file mode 100644 index c517e17..0000000 --- a/lxqt-leave/translations/lxqt-leave_hu.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Name[hu]=Kiléptetés -Comment[hu]=Kiléptető párbeszédablak \ No newline at end of file diff --git a/lxqt-leave/translations/lxqt-leave_it.desktop b/lxqt-leave/translations/lxqt-leave_it.desktop deleted file mode 100644 index 0527e47..0000000 --- a/lxqt-leave/translations/lxqt-leave_it.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Name[it]=Esci -Comment[it]=Opzioni di uscita diff --git a/lxqt-leave/translations/lxqt-leave_ja.desktop b/lxqt-leave/translations/lxqt-leave_ja.desktop deleted file mode 100644 index 3c1eb46..0000000 --- a/lxqt-leave/translations/lxqt-leave_ja.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Name[ja]=終了 -Comment[ja]=終了ダイアログを表示します diff --git a/lxqt-leave/translations/lxqt-leave_lt.desktop b/lxqt-leave/translations/lxqt-leave_lt.desktop deleted file mode 100644 index e7beaee..0000000 --- a/lxqt-leave/translations/lxqt-leave_lt.desktop +++ /dev/null @@ -1,3 +0,0 @@ -Name[lt]=Išeiti -GenericName[lt]=Išeiti -Comment[lt]=Išėjimo dialogas diff --git a/lxqt-leave/translations/lxqt-leave_pl.desktop b/lxqt-leave/translations/lxqt-leave_pl.desktop deleted file mode 100644 index e3cf922..0000000 --- a/lxqt-leave/translations/lxqt-leave_pl.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Name[pl]=Wyjdź -Comment[pl]=Ekran wyjścia diff --git a/lxqt-leave/translations/lxqt-leave_ru.desktop b/lxqt-leave/translations/lxqt-leave_ru.desktop deleted file mode 100644 index b4acf0b..0000000 --- a/lxqt-leave/translations/lxqt-leave_ru.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Name[ru]=Выйти -Comment[ru]=Меню выхода \ No newline at end of file diff --git a/lxqt-leave/translations/lxqt-lockscreen_ar.desktop b/lxqt-leave/translations/lxqt-lockscreen_ar.desktop deleted file mode 100644 index f226a03..0000000 --- a/lxqt-leave/translations/lxqt-lockscreen_ar.desktop +++ /dev/null @@ -1,3 +0,0 @@ -Comment[ar]=اقفل الجلسة الحاليّة -Name[ar]=اقفل الشّاشة -GenericName[ar]=اقفل الشّاشة diff --git a/lxqt-leave/translations/lxqt-lockscreen_ca.desktop b/lxqt-leave/translations/lxqt-lockscreen_ca.desktop deleted file mode 100644 index ea55660..0000000 --- a/lxqt-leave/translations/lxqt-lockscreen_ca.desktop +++ /dev/null @@ -1,4 +0,0 @@ -#Translation -Name[ca]=Bloqueja la pantalla -GenericName[ca]=Bloqueja la pantalla -Comment[ca]=Bloqueja la sessió actual diff --git a/lxqt-leave/translations/lxqt-lockscreen_da.desktop b/lxqt-leave/translations/lxqt-lockscreen_da.desktop deleted file mode 100644 index 362e7f5..0000000 --- a/lxqt-leave/translations/lxqt-lockscreen_da.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[da]=Lås skærmen -Comment[da]=Lås den aktuelle session diff --git a/lxqt-leave/translations/lxqt-lockscreen_de.desktop b/lxqt-leave/translations/lxqt-lockscreen_de.desktop deleted file mode 100644 index f4d041d..0000000 --- a/lxqt-leave/translations/lxqt-lockscreen_de.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Comment[de]=aktuelle Sitzung sperren -Name[de]=Bildschirm sperren diff --git a/lxqt-leave/translations/lxqt-lockscreen_el.desktop b/lxqt-leave/translations/lxqt-lockscreen_el.desktop deleted file mode 100644 index 2fa3664..0000000 --- a/lxqt-leave/translations/lxqt-lockscreen_el.desktop +++ /dev/null @@ -1,4 +0,0 @@ -#Translation -Name[el]=Κλείδωμα οθόνης -GenericName[el]=Κλείδωμα οθόνης -Comment[el]=Κλείδωμα της τρέχουσας συνεδρίας diff --git a/lxqt-leave/translations/lxqt-lockscreen_eu.desktop b/lxqt-leave/translations/lxqt-lockscreen_eu.desktop deleted file mode 100644 index 3f9d72a..0000000 --- a/lxqt-leave/translations/lxqt-lockscreen_eu.desktop +++ /dev/null @@ -1,4 +0,0 @@ -#Translation -Name[eu]=Blokeatu pantaila -GenericName[eu]=Blokeatu pantaila -Comment[eu]=Blokeatu uneko saioa diff --git a/lxqt-leave/translations/lxqt-lockscreen_fr.desktop b/lxqt-leave/translations/lxqt-lockscreen_fr.desktop deleted file mode 100644 index 3da323c..0000000 --- a/lxqt-leave/translations/lxqt-lockscreen_fr.desktop +++ /dev/null @@ -1,3 +0,0 @@ -Comment[fr]=Verrouillage de la session courante -GenericName[fr]=Verrouiller l’écran -Name[fr]=Verrouiller l’écran diff --git a/lxqt-leave/translations/lxqt-lockscreen_hu.desktop b/lxqt-leave/translations/lxqt-lockscreen_hu.desktop deleted file mode 100644 index 2d75b7e..0000000 --- a/lxqt-leave/translations/lxqt-lockscreen_hu.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Comment[hu]=A gép zárolása -Name[hu]=Képernyőzár diff --git a/lxqt-leave/translations/lxqt-lockscreen_it.desktop b/lxqt-leave/translations/lxqt-lockscreen_it.desktop deleted file mode 100644 index d1a5f58..0000000 --- a/lxqt-leave/translations/lxqt-lockscreen_it.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Name[it]=Blocca schermo -Comment[it]=Blocca la sessione attuale diff --git a/lxqt-leave/translations/lxqt-lockscreen_ja.desktop b/lxqt-leave/translations/lxqt-lockscreen_ja.desktop deleted file mode 100644 index 36f0fba..0000000 --- a/lxqt-leave/translations/lxqt-lockscreen_ja.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Name[ja]=画面のロック -Comment[ja]=画面をロックします diff --git a/lxqt-leave/translations/lxqt-lockscreen_lt.desktop b/lxqt-leave/translations/lxqt-lockscreen_lt.desktop deleted file mode 100644 index 56441b7..0000000 --- a/lxqt-leave/translations/lxqt-lockscreen_lt.desktop +++ /dev/null @@ -1,3 +0,0 @@ -Name[lt]=Užrakinti ekraną -GenericName[lt]=Užrakinti ekraną -Comment[lt]=Užrakinti esamą seansą diff --git a/lxqt-leave/translations/lxqt-lockscreen_pl.desktop b/lxqt-leave/translations/lxqt-lockscreen_pl.desktop deleted file mode 100644 index 336c397..0000000 --- a/lxqt-leave/translations/lxqt-lockscreen_pl.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Name[pl]=Zablokuj ekran -Comment[pl]=Zablokuj bieżącą sesję diff --git a/lxqt-leave/translations/lxqt-lockscreen_pt.desktop b/lxqt-leave/translations/lxqt-lockscreen_pt.desktop deleted file mode 100644 index c75dd18..0000000 --- a/lxqt-leave/translations/lxqt-lockscreen_pt.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Name[pt]=Bloquear -Comment[pt]=Bloquear a sessão atual diff --git a/lxqt-leave/translations/lxqt-lockscreen_ru.desktop b/lxqt-leave/translations/lxqt-lockscreen_ru.desktop deleted file mode 100644 index fe5268a..0000000 --- a/lxqt-leave/translations/lxqt-lockscreen_ru.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Name[ru]=Заблокировать экран -Comment[ru]=Заблокировать текущий сеанс diff --git a/lxqt-leave/translations/lxqt-logout_ar.desktop b/lxqt-leave/translations/lxqt-logout_ar.desktop deleted file mode 100644 index d79e2c6..0000000 --- a/lxqt-leave/translations/lxqt-logout_ar.desktop +++ /dev/null @@ -1,3 +0,0 @@ -Comment[ar]=اخرج من الجلسة الحاليّة -Name[ar]=اخرج -GenericName[ar]=اخرج diff --git a/lxqt-leave/translations/lxqt-logout_ca.desktop b/lxqt-leave/translations/lxqt-logout_ca.desktop deleted file mode 100644 index 5d3eda3..0000000 --- a/lxqt-leave/translations/lxqt-logout_ca.desktop +++ /dev/null @@ -1,4 +0,0 @@ -#Translation -Name[ca]=Tanca la sessió -GenericName[ca]=Tanca la sessió -Comment[ca]=Tancament de la sessió actual diff --git a/lxqt-leave/translations/lxqt-logout_da.desktop b/lxqt-leave/translations/lxqt-logout_da.desktop deleted file mode 100644 index 0c12dda..0000000 --- a/lxqt-leave/translations/lxqt-logout_da.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[da]=Log ud -Comment[da]=Log ud fra den aktuelle session diff --git a/lxqt-leave/translations/lxqt-logout_de.desktop b/lxqt-leave/translations/lxqt-logout_de.desktop deleted file mode 100644 index eea2cd6..0000000 --- a/lxqt-leave/translations/lxqt-logout_de.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Comment[de]=Sitzung beenden -Name[de]=Abmelden diff --git a/lxqt-leave/translations/lxqt-logout_el.desktop b/lxqt-leave/translations/lxqt-logout_el.desktop deleted file mode 100644 index ad34b50..0000000 --- a/lxqt-leave/translations/lxqt-logout_el.desktop +++ /dev/null @@ -1,4 +0,0 @@ -#Translation -Name[el]=Αποσύνδεση -GenericName[el]=Αποσύνδεση -Comment[el]=Αποσύνδεση από την τρέχουσα συνεδρία diff --git a/lxqt-leave/translations/lxqt-logout_eu.desktop b/lxqt-leave/translations/lxqt-logout_eu.desktop deleted file mode 100644 index 3dbcd21..0000000 --- a/lxqt-leave/translations/lxqt-logout_eu.desktop +++ /dev/null @@ -1,4 +0,0 @@ -#Translation -Name[eu]=Itxi saioa -GenericName[eu]=Itxi saioa -Comment[eu]=Itxi uneko saioa diff --git a/lxqt-leave/translations/lxqt-logout_fr.desktop b/lxqt-leave/translations/lxqt-logout_fr.desktop deleted file mode 100644 index 5d253b9..0000000 --- a/lxqt-leave/translations/lxqt-logout_fr.desktop +++ /dev/null @@ -1,4 +0,0 @@ -#TRANSLATIONS -Name[fr]=Déconnecter -GenericName[fr]=Déconnecter -Comment[fr]=Déconnecter de cette session diff --git a/lxqt-leave/translations/lxqt-logout_hu.desktop b/lxqt-leave/translations/lxqt-logout_hu.desktop deleted file mode 100644 index 999555c..0000000 --- a/lxqt-leave/translations/lxqt-logout_hu.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Comment[hu]=LXQt munkamenet vége -Name[hu]=Kilépés diff --git a/lxqt-leave/translations/lxqt-logout_it.desktop b/lxqt-leave/translations/lxqt-logout_it.desktop deleted file mode 100644 index 4eb083d..0000000 --- a/lxqt-leave/translations/lxqt-logout_it.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Name[it]=Chiudi sessione -Comment[it]=Chiudere la sessione attuale diff --git a/lxqt-leave/translations/lxqt-logout_ja.desktop b/lxqt-leave/translations/lxqt-logout_ja.desktop deleted file mode 100644 index 067ae6a..0000000 --- a/lxqt-leave/translations/lxqt-logout_ja.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Name[ja]=ログアウト -Comment[ja]=セッションからログアウトします diff --git a/lxqt-leave/translations/lxqt-logout_lt.desktop b/lxqt-leave/translations/lxqt-logout_lt.desktop deleted file mode 100644 index 21621cc..0000000 --- a/lxqt-leave/translations/lxqt-logout_lt.desktop +++ /dev/null @@ -1,4 +0,0 @@ -#Translation -Name[lt]=Atsijungti -GenericName[lt]=Atsijungti -Comment[lt]=Atsijungti iš esamo seanso diff --git a/lxqt-leave/translations/lxqt-logout_pl.desktop b/lxqt-leave/translations/lxqt-logout_pl.desktop deleted file mode 100644 index 3c71735..0000000 --- a/lxqt-leave/translations/lxqt-logout_pl.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Name[pl]=Wyloguj -Comment[pl]=Zakończ bieżącą sesję diff --git a/lxqt-leave/translations/lxqt-logout_pt.desktop b/lxqt-leave/translations/lxqt-logout_pt.desktop deleted file mode 100644 index 45b8637..0000000 --- a/lxqt-leave/translations/lxqt-logout_pt.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Name[pt]=Sair -Comment[pt]=Sair da sessão diff --git a/lxqt-leave/translations/lxqt-logout_ru.desktop b/lxqt-leave/translations/lxqt-logout_ru.desktop deleted file mode 100644 index 105e3b7..0000000 --- a/lxqt-leave/translations/lxqt-logout_ru.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Name[ru]=Выйти из системы -Comment[ru]=Выйти из текущего сеанса diff --git a/lxqt-leave/translations/lxqt-reboot_ar.desktop b/lxqt-leave/translations/lxqt-reboot_ar.desktop deleted file mode 100644 index f5718be..0000000 --- a/lxqt-leave/translations/lxqt-reboot_ar.desktop +++ /dev/null @@ -1,3 +0,0 @@ -Comment[ar]=أعد إقلاع الجهاز -Name[ar]=أعد الإقلاع -GenericName[ar]=أعد الإقلاع diff --git a/lxqt-leave/translations/lxqt-reboot_ca.desktop b/lxqt-leave/translations/lxqt-reboot_ca.desktop deleted file mode 100644 index c69f236..0000000 --- a/lxqt-leave/translations/lxqt-reboot_ca.desktop +++ /dev/null @@ -1,4 +0,0 @@ -#Translation -Name[ca]=Reinicia -GenericName[ca]=Reinicia -Comment[ca]=Reinicia la màquina diff --git a/lxqt-leave/translations/lxqt-reboot_da.desktop b/lxqt-leave/translations/lxqt-reboot_da.desktop deleted file mode 100644 index dd007ab..0000000 --- a/lxqt-leave/translations/lxqt-reboot_da.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[da]=Genstart -Comment[da]=Genstart maskinen diff --git a/lxqt-leave/translations/lxqt-reboot_de.desktop b/lxqt-leave/translations/lxqt-reboot_de.desktop deleted file mode 100644 index 964102a..0000000 --- a/lxqt-leave/translations/lxqt-reboot_de.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Comment[de]=Rechner neustarten -Name[de]=Neustart diff --git a/lxqt-leave/translations/lxqt-reboot_el.desktop b/lxqt-leave/translations/lxqt-reboot_el.desktop deleted file mode 100644 index b3c6272..0000000 --- a/lxqt-leave/translations/lxqt-reboot_el.desktop +++ /dev/null @@ -1,4 +0,0 @@ -#Translation -Name[el]=Επανεκκίνηση -GenericName[el]=Επανεκκίνηση -Comment[el]=Επανεκκίνηση του μηχανήματος diff --git a/lxqt-leave/translations/lxqt-reboot_eu.desktop b/lxqt-leave/translations/lxqt-reboot_eu.desktop deleted file mode 100644 index ddf2595..0000000 --- a/lxqt-leave/translations/lxqt-reboot_eu.desktop +++ /dev/null @@ -1,4 +0,0 @@ -#Translation -Name[eu]=Berrabiarazi -GenericName[eu]=Berrabiarazi -Comment[eu]=Berrabiarazi ordenagailua diff --git a/lxqt-leave/translations/lxqt-reboot_fr.desktop b/lxqt-leave/translations/lxqt-reboot_fr.desktop deleted file mode 100644 index 825fc5f..0000000 --- a/lxqt-leave/translations/lxqt-reboot_fr.desktop +++ /dev/null @@ -1,4 +0,0 @@ -#TRANSLATIONS -Name[fr]=Redémarrer -GenericName[fr]=Redémarrer -Comment[fr]=Redémarrer l'ordinateur diff --git a/lxqt-leave/translations/lxqt-reboot_hu.desktop b/lxqt-leave/translations/lxqt-reboot_hu.desktop deleted file mode 100644 index b31f773..0000000 --- a/lxqt-leave/translations/lxqt-reboot_hu.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Comment[hu]=A gép újraindítása -Name[hu]=Újraindítás diff --git a/lxqt-leave/translations/lxqt-reboot_it.desktop b/lxqt-leave/translations/lxqt-reboot_it.desktop deleted file mode 100644 index 5012aa8..0000000 --- a/lxqt-leave/translations/lxqt-reboot_it.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Name[it]=Riavvia -Comment[it]=Riavviare il computer diff --git a/lxqt-leave/translations/lxqt-reboot_ja.desktop b/lxqt-leave/translations/lxqt-reboot_ja.desktop deleted file mode 100644 index 4b4cbc2..0000000 --- a/lxqt-leave/translations/lxqt-reboot_ja.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Name[ja]=再起動 -Comment[ja]=PCを再起動します diff --git a/lxqt-leave/translations/lxqt-reboot_lt.desktop b/lxqt-leave/translations/lxqt-reboot_lt.desktop deleted file mode 100644 index 902e807..0000000 --- a/lxqt-leave/translations/lxqt-reboot_lt.desktop +++ /dev/null @@ -1,4 +0,0 @@ -#Translation -Name[lt]=Paleisti iš naujo -GenericName[lt]=Paleisti iš naujo -Comment[lt]=Paleisti kompiuterį iš naujo diff --git a/lxqt-leave/translations/lxqt-reboot_pl.desktop b/lxqt-leave/translations/lxqt-reboot_pl.desktop deleted file mode 100644 index 6b37bdc..0000000 --- a/lxqt-leave/translations/lxqt-reboot_pl.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Name[pl]=Uruchom ponownie -Comment[pl]=Ponowne uruchomienie komputera diff --git a/lxqt-leave/translations/lxqt-reboot_pt.desktop b/lxqt-leave/translations/lxqt-reboot_pt.desktop deleted file mode 100644 index 57ea2da..0000000 --- a/lxqt-leave/translations/lxqt-reboot_pt.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Name[pt]=Reiniciar -Comment[pt]=Reiniciar o computador diff --git a/lxqt-leave/translations/lxqt-reboot_ru.desktop b/lxqt-leave/translations/lxqt-reboot_ru.desktop deleted file mode 100644 index 187a4b7..0000000 --- a/lxqt-leave/translations/lxqt-reboot_ru.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Name[ru]=Перезагрузка -Comment[ru]=Перезагрузить компьютер diff --git a/lxqt-leave/translations/lxqt-shutdown_ar.desktop b/lxqt-leave/translations/lxqt-shutdown_ar.desktop deleted file mode 100644 index 1b10a91..0000000 --- a/lxqt-leave/translations/lxqt-shutdown_ar.desktop +++ /dev/null @@ -1,3 +0,0 @@ -Comment[ar]=أطفئ الجهاز -Name[ar]=أطفئ -GenericName[ar]=أطفئ diff --git a/lxqt-leave/translations/lxqt-shutdown_ca.desktop b/lxqt-leave/translations/lxqt-shutdown_ca.desktop deleted file mode 100644 index 216a580..0000000 --- a/lxqt-leave/translations/lxqt-shutdown_ca.desktop +++ /dev/null @@ -1,4 +0,0 @@ -#Translation -Name[ca]=Atura -GenericName[ca]=Atura -Comment[ca]=Atura la màquina diff --git a/lxqt-leave/translations/lxqt-shutdown_da.desktop b/lxqt-leave/translations/lxqt-shutdown_da.desktop deleted file mode 100644 index 1bc9906..0000000 --- a/lxqt-leave/translations/lxqt-shutdown_da.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[da]=Luk ned -Comment[da]=Luk maskinen diff --git a/lxqt-leave/translations/lxqt-shutdown_de.desktop b/lxqt-leave/translations/lxqt-shutdown_de.desktop deleted file mode 100644 index 3654fec..0000000 --- a/lxqt-leave/translations/lxqt-shutdown_de.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Comment[de]=Rechner herunterfahren -Name[de]=Herunterfahren diff --git a/lxqt-leave/translations/lxqt-shutdown_el.desktop b/lxqt-leave/translations/lxqt-shutdown_el.desktop deleted file mode 100644 index 9e85bdd..0000000 --- a/lxqt-leave/translations/lxqt-shutdown_el.desktop +++ /dev/null @@ -1,4 +0,0 @@ -#Translation -Name[el]=Τερματισμός -GenericName[el]=Τερματισμός -Comment[el]=Τερματισμός του μηχανήματος diff --git a/lxqt-leave/translations/lxqt-shutdown_eu.desktop b/lxqt-leave/translations/lxqt-shutdown_eu.desktop deleted file mode 100644 index ce0f878..0000000 --- a/lxqt-leave/translations/lxqt-shutdown_eu.desktop +++ /dev/null @@ -1,4 +0,0 @@ -#Translation -Name[eu]=Itzali -GenericName[eu]=Itzali -Comment[eu]=Itzali ordenagailua diff --git a/lxqt-leave/translations/lxqt-shutdown_fr.desktop b/lxqt-leave/translations/lxqt-shutdown_fr.desktop deleted file mode 100644 index 7f23391..0000000 --- a/lxqt-leave/translations/lxqt-shutdown_fr.desktop +++ /dev/null @@ -1,4 +0,0 @@ -#TRANSLATIONS -Name[fr]=Arrêter -GenericName[fr]=Arrêter -Comment[fr]=Arrêter l'ordinateur diff --git a/lxqt-leave/translations/lxqt-shutdown_hu.desktop b/lxqt-leave/translations/lxqt-shutdown_hu.desktop deleted file mode 100644 index 2e4dc99..0000000 --- a/lxqt-leave/translations/lxqt-shutdown_hu.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Comment[hu]=A számítógép kikapcsolása -Name[hu]=Kikapcsolás diff --git a/lxqt-leave/translations/lxqt-shutdown_it.desktop b/lxqt-leave/translations/lxqt-shutdown_it.desktop deleted file mode 100644 index c6f548b..0000000 --- a/lxqt-leave/translations/lxqt-shutdown_it.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Name[it]=Arresta -Comment[it]=Spegnere il computer diff --git a/lxqt-leave/translations/lxqt-shutdown_ja.desktop b/lxqt-leave/translations/lxqt-shutdown_ja.desktop deleted file mode 100644 index 60cfb7f..0000000 --- a/lxqt-leave/translations/lxqt-shutdown_ja.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Name[ja]=シャットダウン -Comment[ja]=PCをシャットダウンします diff --git a/lxqt-leave/translations/lxqt-shutdown_lt.desktop b/lxqt-leave/translations/lxqt-shutdown_lt.desktop deleted file mode 100644 index 5051308..0000000 --- a/lxqt-leave/translations/lxqt-shutdown_lt.desktop +++ /dev/null @@ -1,4 +0,0 @@ -#Translation -Name[lt]=Išjungti -GenericName[lt]=Išjungti -Comment[lt]=Išjungti kompiuterį diff --git a/lxqt-leave/translations/lxqt-shutdown_pl.desktop b/lxqt-leave/translations/lxqt-shutdown_pl.desktop deleted file mode 100644 index 1db998b..0000000 --- a/lxqt-leave/translations/lxqt-shutdown_pl.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Name[pl]=Wyłącz -Comment[pl]=Wyłącz komputer diff --git a/lxqt-leave/translations/lxqt-shutdown_pt.desktop b/lxqt-leave/translations/lxqt-shutdown_pt.desktop deleted file mode 100644 index 20f06af..0000000 --- a/lxqt-leave/translations/lxqt-shutdown_pt.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Name[pt]=Desligar -Comment[pt]=Desligar o computador diff --git a/lxqt-leave/translations/lxqt-shutdown_ru.desktop b/lxqt-leave/translations/lxqt-shutdown_ru.desktop deleted file mode 100644 index d982e9a..0000000 --- a/lxqt-leave/translations/lxqt-shutdown_ru.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Name[ru]=Выключение -Comment[ru]=Выключить компьютер diff --git a/lxqt-leave/translations/lxqt-suspend_ar.desktop b/lxqt-leave/translations/lxqt-suspend_ar.desktop deleted file mode 100644 index eabbfa3..0000000 --- a/lxqt-leave/translations/lxqt-suspend_ar.desktop +++ /dev/null @@ -1,3 +0,0 @@ -Comment[ar]=علّق الجهاز -Name[ar]=علّق -GenericName[ar]=علّق diff --git a/lxqt-leave/translations/lxqt-suspend_ca.desktop b/lxqt-leave/translations/lxqt-suspend_ca.desktop deleted file mode 100644 index aa20690..0000000 --- a/lxqt-leave/translations/lxqt-suspend_ca.desktop +++ /dev/null @@ -1,4 +0,0 @@ -#Translation -Name[ca]=Suspèn -GenericName[ca]=Suspèn -Comment[ca]=Suspèn la màquina diff --git a/lxqt-leave/translations/lxqt-suspend_da.desktop b/lxqt-leave/translations/lxqt-suspend_da.desktop deleted file mode 100644 index ca3d6c4..0000000 --- a/lxqt-leave/translations/lxqt-suspend_da.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[da]=Hvile -Comment[da]=Sæt maskinen i hvile diff --git a/lxqt-leave/translations/lxqt-suspend_de.desktop b/lxqt-leave/translations/lxqt-suspend_de.desktop deleted file mode 100644 index 3ac6a6d..0000000 --- a/lxqt-leave/translations/lxqt-suspend_de.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Comment[de]=Rechner in Bereitschaftsmodus versetzen -Name[de]=Bereitschaft diff --git a/lxqt-leave/translations/lxqt-suspend_el.desktop b/lxqt-leave/translations/lxqt-suspend_el.desktop deleted file mode 100644 index 058725b..0000000 --- a/lxqt-leave/translations/lxqt-suspend_el.desktop +++ /dev/null @@ -1,4 +0,0 @@ -#Translation -Name[el]=Αναστολή -GenericName[el]=Αναστολή -Comment[el]=Αναστολή του μηχανήματος diff --git a/lxqt-leave/translations/lxqt-suspend_eu.desktop b/lxqt-leave/translations/lxqt-suspend_eu.desktop deleted file mode 100644 index fd550cc..0000000 --- a/lxqt-leave/translations/lxqt-suspend_eu.desktop +++ /dev/null @@ -1,4 +0,0 @@ -#Translation -Name[eu]=Eseki -GenericName[eu]=Eseki -Comment[eu]=Eseki ordenagailua diff --git a/lxqt-leave/translations/lxqt-suspend_fr.desktop b/lxqt-leave/translations/lxqt-suspend_fr.desktop deleted file mode 100644 index 167c862..0000000 --- a/lxqt-leave/translations/lxqt-suspend_fr.desktop +++ /dev/null @@ -1,4 +0,0 @@ -#TRANSLATIONS -Name[fr]=Suspendre -GenericName[fr]=Suspendre -Comment[fr]=Suspendre l'ordinateur diff --git a/lxqt-leave/translations/lxqt-suspend_hu.desktop b/lxqt-leave/translations/lxqt-suspend_hu.desktop deleted file mode 100644 index edd82d8..0000000 --- a/lxqt-leave/translations/lxqt-suspend_hu.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Comment[hu]=A számítógép készenléti állapotba helyezése -Name[hu]=Készenlét diff --git a/lxqt-leave/translations/lxqt-suspend_it.desktop b/lxqt-leave/translations/lxqt-suspend_it.desktop deleted file mode 100644 index 9d49081..0000000 --- a/lxqt-leave/translations/lxqt-suspend_it.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Name[it]=Sospensione -Comment[it]=Sospendere il computer diff --git a/lxqt-leave/translations/lxqt-suspend_ja.desktop b/lxqt-leave/translations/lxqt-suspend_ja.desktop deleted file mode 100644 index b4426b8..0000000 --- a/lxqt-leave/translations/lxqt-suspend_ja.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Name[ja]=サスペンド -Comment[ja]=PCをサスペンドします diff --git a/lxqt-leave/translations/lxqt-suspend_lt.desktop b/lxqt-leave/translations/lxqt-suspend_lt.desktop deleted file mode 100644 index b79502f..0000000 --- a/lxqt-leave/translations/lxqt-suspend_lt.desktop +++ /dev/null @@ -1,4 +0,0 @@ -#Translation -Name[lt]=Pristabdyti -GenericName[lt]=Pristabdyti -Comment[lt]=Pristabdyti kompiuterį diff --git a/lxqt-leave/translations/lxqt-suspend_pl.desktop b/lxqt-leave/translations/lxqt-suspend_pl.desktop deleted file mode 100644 index c25c14d..0000000 --- a/lxqt-leave/translations/lxqt-suspend_pl.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Name[pl]=Uśpij -Comment[pl]=Uśpij komputer diff --git a/lxqt-leave/translations/lxqt-suspend_pt.desktop b/lxqt-leave/translations/lxqt-suspend_pt.desktop deleted file mode 100644 index 9823ce5..0000000 --- a/lxqt-leave/translations/lxqt-suspend_pt.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Name[pt]=Suspender -Comment[pt]=Suspender o computador diff --git a/lxqt-leave/translations/lxqt-suspend_ru.desktop b/lxqt-leave/translations/lxqt-suspend_ru.desktop deleted file mode 100644 index f3fe543..0000000 --- a/lxqt-leave/translations/lxqt-suspend_ru.desktop +++ /dev/null @@ -1,2 +0,0 @@ -Name[ru]=Ждущий режим -Comment[ru]=Перевести компьютер в ждущий режим diff --git a/lxqt-session/CMakeLists.txt b/lxqt-session/CMakeLists.txt deleted file mode 100644 index bca34e0..0000000 --- a/lxqt-session/CMakeLists.txt +++ /dev/null @@ -1,93 +0,0 @@ -cmake_minimum_required(VERSION 3.0.2 FATAL_ERROR) -project(lxqt-session) - -if(NOT CMAKE_BUILD_TYPE) - set(CMAKE_BUILD_TYPE Release) -endif() - -if (WITH_LIBUDEV) - find_package(UDev REQUIRED) - include_directories(${LIBUDEV_INCLUDE_DIR}) - add_definitions(-DWITH_LIBUDEV_MONITOR) -endif() - -include_directories( - ${X11_INCLUDE_DIR} -) - -set(lxqt-session_HDRS "") - -set(lxqt-session_SRCS - src/main.cpp - src/lxqtmodman.cpp - src/wmselectdialog.cpp - src/windowmanager.cpp - src/sessionapplication.cpp - src/sessiondbusadaptor.h - src/lockscreenmanager.cpp - src/lockscreenmanager.h - src/numlock.cpp - src/numlock.h - src/log.cpp -) -if (WITH_LIBUDEV) - list(APPEND lxqt-session_SRCS src/UdevNotifier.cpp) -endif() - -set(lxqt-session_UI - src/wmselectdialog.ui -) - -# Translations -lxqt_translate_ts(lxqt-session_QM_FILES - UPDATE_TRANSLATIONS - ${UPDATE_TRANSLATIONS} - SOURCES - ${lxqt-session_HDRS} - ${lxqt-session_SRCS} - ${lxqt-session_UI} - INSTALL_DIR - "${LXQT_TRANSLATIONS_DIR}/${PROJECT_NAME}" - PULL_TRANSLATIONS - ${PULL_TRANSLATIONS} - CLEAN_TRANSLATIONS - ${CLEAN_TRANSLATIONS} - TRANSLATIONS_REPO - ${TRANSLATIONS_REPO} - TRANSLATIONS_REFSPEC - ${TRANSLATIONS_REFSPEC} - REPO_SUBDIR - "lxqt-session/${PROJECT_NAME}" -) -lxqt_app_translation_loader(lxqt-session_QM_LOADER ${PROJECT_NAME}) - -add_executable(lxqt-session - ${lxqt-session_SRCS} - ${RSCS} - ${lxqt-session_QM_FILES} - ${lxqt-session_QM_LOADER} -) - -target_link_libraries(lxqt-session - Qt5::Widgets - Qt5::DBus - Qt5::X11Extras - lxqt - ${X11_LIBRARIES} - KF5::WindowSystem -) - -if (WITH_LIBUDEV) - target_link_libraries(lxqt-session ${UDEV_LIBS}) -endif() - -INSTALL(TARGETS - lxqt-session - RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}" - COMPONENT Runtime -) -install(FILES - man/lxqt-session.1 - DESTINATION "${CMAKE_INSTALL_MANDIR}/man1" - COMPONENT Runtime -) diff --git a/lxqt-session/man/lxqt-session.1 b/lxqt-session/man/lxqt-session.1 deleted file mode 100644 index 559aefe..0000000 --- a/lxqt-session/man/lxqt-session.1 +++ /dev/null @@ -1,65 +0,0 @@ -.TH lxqt-session "1" "2015-11-05" "LXQt 0.10.0" "LXQt Session Module" -.SH NAME -\fBlxqt-session\fR \- Session manager of \fBLXQt\fR: The Lightweight Qt Desktop -Environment -.SH SYNOPSIS -.B lxqt-session -.br -.SH DESCRIPTION -This module handles session autostart application over \fBLXQt\fR desktop -environment startup. -.P -The \fBLXQt modules\fR are desktop independent tools, and operate as daemons -for the local user on desktop specific operations. -.P -\fBLXQt\fR is an advanced, easy-to-use, and fast desktop environment based on -the Qt framework. It has been tailored for users who value simplicity, speed, -and an intuitive interface, with minimal resource requirements. It comprises -several optional desktop components: -.P - * Session module (\fIthis\fR, normally invoked with \fBstartlxqt\fR) - * Settings configuration center - * Application launcher - * Desktop - * Panel with optional plugins - * Polkit authorization agent - * SSH password access - * Display manager module - * Power management module - * Sudo/su module (privilege elevation) -.P -These components perform similar actions to those available in other desktop -environments, and their name is self-descriptive. They are usually launched -automatically, when choosing a \fBLXQt\fR session in the Display Manager. -.SH BEHAVIOR -This application manages the \fBLXQt\fR session desktop behavior, module -loading, and related startup programs prior loading the user workspace. -By default this module loads the panel, desktop, and power management -modules, thus it is important for a working \fBLXQt\fR session. -.SH AUTOSTART -The modules are only shown by default in the \fBLXQt\fR desktop environment, but -an autostart action can be created for other preferred desktop environments. -.SH "REPORTING BUGS" -Report bugs to https://github.com/LXDE/LXQt/issues -.SH "SEE ALSO" -.\" any module must refer to the session application, for module overview and initiation -\fBstartlxqt.1\fR LXQt session initialization and launch script (e.g. in \fB.xinitrc\fR) -.P -\fBlxqt-config-session.1\fR LXQt default and autostart applications settings, -plus environment settings -.P -\fBlxqt-config.1\fR LXQt settings Configuration Center interface -.P -\fBlxqt-leave.1\fR LXQt session logout, reboot, shutdown, suspend, hibernate -and lock screen -.P -\fBlxqt-openssh-askpass.1\fR LXQt password access over ssh cryptography toolkit -.P -\fBlxqt-panel.1\fR LXQt desktop panel with optional plugins -.P -\fBlxqt-policykit-agent.1\fR LXQt polkit authorization agent -.P -\fBlxqt-runner.1\fR LXQt application launcher by keyboard shortcut -.P -\fBlxqt-sudo.1\fR LXQt sudo/su GUI for application privilege elevation -.P diff --git a/lxqt-session/src/UdevNotifier.cpp b/lxqt-session/src/UdevNotifier.cpp deleted file mode 100644 index 3b87f87..0000000 --- a/lxqt-session/src/UdevNotifier.cpp +++ /dev/null @@ -1,99 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXQt - a lightweight, Qt based, desktop toolset - * http://lxqt.org - * - * Copyright: 2015 LXQt team - * Authors: - * Palo Kisa - * - * This program or library is free software; you can redistribute it - * and/or modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General - * Public License along with this library; if not, write to the - * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#include "UdevNotifier.h" -#include "log.h" -#include -#include - - -class UdevNotifier::Impl -{ -public: - struct udev * udev; - struct udev_monitor * monitor; - QScopedPointer notifier; -}; - - -UdevNotifier::UdevNotifier(QString const & subsystem, QObject * parent/* = nullptr*/) - : QObject(parent) - , d(new Impl) -{ - d->udev = udev_new(); - d->monitor = udev_monitor_new_from_netlink(d->udev, "udev"); - if (nullptr == d->monitor) - { - qCWarning(SESSION) << QStringLiteral("UdevNotifier: unable to initialize udev_monitor, monitoring will be disabled"); - return; - } - - int ret = udev_monitor_filter_add_match_subsystem_devtype(d->monitor, subsystem.toLatin1().constData(), nullptr); - if (0 != ret) - qCWarning(SESSION) << QStringLiteral("UdevNotifier: unable to add match subsystem, monitor will receive all devices"); - - ret = udev_monitor_enable_receiving(d->monitor); - if (0 != ret) - { - qCWarning(SESSION) << QStringLiteral("UdevNotifier: unable to enable receiving(%1), monitoring will be disabled").arg(ret); - return; - } - - d->notifier.reset(new QSocketNotifier(udev_monitor_get_fd(d->monitor), QSocketNotifier::Read)); - connect(d->notifier.data(), &QSocketNotifier::activated, this, &UdevNotifier::eventReady); - d->notifier->setEnabled(true); -} - -UdevNotifier::~UdevNotifier() -{ - if (d->monitor) - udev_monitor_unref(d->monitor); - udev_unref(d->udev); -} - -void UdevNotifier::eventReady(int /*socket*/) -{ - struct udev_device * dev; - while (nullptr != (dev = udev_monitor_receive_device(d->monitor))) - { - QString const action = udev_device_get_action(dev); - QString const device = udev_device_get_devpath(dev); - - if (QStringLiteral("add") == action) - emit deviceAdded(std::move(device)); - else if (QStringLiteral("remove") == action) - emit deviceRemoved(std::move(device)); - else if (QStringLiteral("change") == action) - emit deviceChanged(std::move(device)); - else if (QStringLiteral("online") == action) - emit deviceOnline(std::move(device)); - else if (QStringLiteral("offline") == action) - emit deviceOffline(std::move(device)); - - udev_device_unref(dev); - } -} diff --git a/lxqt-session/src/UdevNotifier.h b/lxqt-session/src/UdevNotifier.h deleted file mode 100644 index 645aef1..0000000 --- a/lxqt-session/src/UdevNotifier.h +++ /dev/null @@ -1,59 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXQt - a lightweight, Qt based, desktop toolset - * http://lxqt.org - * - * Copyright: 2015 LXQt team - * Authors: - * Palo Kisa - * - * This program or library is free software; you can redistribute it - * and/or modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General - * Public License along with this library; if not, write to the - * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#if !defined(UdevNotifier_h) -#define UdevNotifier_h -#if defined(WITH_LIBUDEV_MONITOR) - -#include -#include - -class UdevNotifier : public QObject -{ - Q_OBJECT -public: - UdevNotifier(QString const & subsystem, QObject * parent = nullptr); - ~UdevNotifier(); - -signals: - void deviceAdded(QString path); - void deviceRemoved(QString path); - void deviceChanged(QString path); - void deviceOnline(QString path); - void deviceOffline(QString path); - -private slots: - void eventReady(int socket); - -private: - class Impl; - - QScopedPointer d; -}; - -#endif //WITH_LIBUDEV_MONITOR -#endif //UdevNotifier_h diff --git a/lxqt-session/src/lockscreenmanager.cpp b/lxqt-session/src/lockscreenmanager.cpp deleted file mode 100644 index ab436ff..0000000 --- a/lxqt-session/src/lockscreenmanager.cpp +++ /dev/null @@ -1,260 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXQt - a lightweight, Qt based, desktop toolset - * http://lxqt.org/ - * - * Copyright: 2016 LXQt team - * Authors: - * Paulo Lieuthier - * - * This program or library is free software; you can redistribute it - * and/or modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - - * You should have received a copy of the GNU Lesser General - * Public License along with this library; if not, write to the - * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#include "lockscreenmanager.h" -#include "log.h" -#include -#include -#include -#include - -LockScreenManager::LockScreenManager(QObject *parent) : - QObject(parent) - , mProvider{nullptr} -{ -} - -LockScreenManager::~LockScreenManager() -{ - delete mProvider; -} - -bool LockScreenManager::startup(bool lockBeforeSleep) -{ - mProvider = new LogindProvider; - if (!mProvider->isValid()) - { - mProvider->deleteLater(); - mProvider = new ConsoleKit2Provider; - if (!mProvider->isValid()) - { - mProvider->deleteLater(); - mProvider = nullptr; - } - } - - if (!mProvider) - { - qCDebug(SESSION) << "LockScreenManager: no valid provider"; - return false; - } - - qCDebug(SESSION) << "LockScreenManager:" - << mProvider->metaObject()->className() - << "will be used"; - - connect(&mScreenSaver, &LXQt::ScreenSaver::done, &mLoop, &QEventLoop::quit); - - connect(mProvider, &LockScreenProvider::lockRequested, [this] { - mScreenSaver.lockScreen(); - mLoop.exec(); - }); - - if (lockBeforeSleep) - { - connect(mProvider, - &LockScreenProvider::aboutToSleep, - [this] (bool beforeSleep) - { - if (beforeSleep) - { - qCDebug(SESSION) << "LockScreenManager: system is about to sleep"; - - mScreenSaver.lockScreen(); - mLoop.exec(); - mProvider->release(); - } - else - mProvider->inhibit(); - }); - - if (!mProvider->inhibit()) - qCDebug(SESSION) << "LockScreenManager:" - << "could not inhibit session provider"; - } - - return true; -} - -/* - * Logind Provider - */ - -LogindProvider::LogindProvider() : - mInterface(QStringLiteral("org.freedesktop.login1"), - QStringLiteral("/org/freedesktop/login1"), - QStringLiteral("org.freedesktop.login1.Manager"), - QDBusConnection::systemBus()) -{ - if (mInterface.isValid()) - { - connect(&mInterface, SIGNAL(PrepareForSleep(bool)), - this, SIGNAL(aboutToSleep(bool))); - - QString sessionId = QDBusInterface( - QStringLiteral("org.freedesktop.login1"), - QStringLiteral("/org/freedesktop/login1/session/self"), - QStringLiteral("org.freedesktop.login1.Session"), - QDBusConnection::systemBus()) - .property("Id").toString(); - - // listen to Lock signal as well - mInterface.connection().connect( - QStringLiteral("org.freedesktop.login1"), - QStringLiteral("/org/freedesktop/login1/session/") + sessionId, - QStringLiteral("org.freedesktop.login1.Session"), - QStringLiteral("Lock"), - this, - SIGNAL(lockRequested())); - } -} - -LogindProvider::~LogindProvider() -{ - release(); -} - -bool LogindProvider::isValid() -{ - return mInterface.isValid(); -} - -bool LogindProvider::inhibit() -{ - if (mFileDescriptor.isValid()) - return false; - - QDBusReply reply = mInterface.call( - QStringLiteral("Inhibit"), - QStringLiteral("sleep"), - QStringLiteral("LXQt Session"), - QStringLiteral("Start screen locker before sleep."), - QStringLiteral("delay")); - - if (!reply.isValid()) - { - qCDebug(SESSION) << "LockScreenManager: " << reply.error(); - return false; - } - - mFileDescriptor = reply.value(); - return true; -} - -void LogindProvider::release() -{ - if (mFileDescriptor.isValid()) - { - ::close(mFileDescriptor.fileDescriptor()); - mFileDescriptor.setFileDescriptor(-1); - } -} - -/* - * ConsoleKit2 provider - */ - -ConsoleKit2Provider::ConsoleKit2Provider() : - mInterface(QStringLiteral("org.freedesktop.ConsoleKit"), - QStringLiteral("/org/freedesktop/ConsoleKit/Manager"), - QStringLiteral("org.freedesktop.ConsoleKit.Manager"), - QDBusConnection::systemBus()), - mMethodInhibitPresent(false) - -{ - // validate interface, look for melhod Inhibit - if (mInterface.isValid()) - { - // this is needed to differentiate ConsoleKit2 from ConsoleKit - QDBusReply reply = QDBusInterface( - QStringLiteral("org.freedesktop.ConsoleKit"), - QStringLiteral("/org/freedesktop/ConsoleKit/Manager"), - QStringLiteral("org.freedesktop.DBus.Introspectable"), - QDBusConnection::systemBus()) - .call(QStringLiteral("Introspect")); - mMethodInhibitPresent = reply.value().contains("Inhibit"); - - if (mMethodInhibitPresent) - { - connect(&mInterface, SIGNAL(PrepareForSleep(bool)), - this, SIGNAL(aboutToSleep(bool))); - - QDBusReply sessionObjectPath = mInterface - .call("GetCurrentSession"); - - // listen to Lock signal as well - mInterface.connection().connect( - QStringLiteral("org.freedesktop.ConsoleKit"), - sessionObjectPath.value().path(), - QStringLiteral("org.freedesktop.ConsoleKit.Session"), - QStringLiteral("Lock"), - this, - SIGNAL(lockRequested())); - } - } -} - -ConsoleKit2Provider::~ConsoleKit2Provider() -{ - release(); -} - -bool ConsoleKit2Provider::isValid() -{ - return mInterface.isValid() && mMethodInhibitPresent; -} - -bool ConsoleKit2Provider::inhibit() -{ - if (mFileDescriptor.isValid()) - return false; - - QDBusReply reply = mInterface.call( - QStringLiteral("Inhibit"), - QStringLiteral("sleep"), - QStringLiteral("LXQt Power Management"), - QStringLiteral("Start screen locker before sleep."), - QStringLiteral("delay")); - - if (!reply.isValid()) - { - qCDebug(SESSION) << "LockScreenWatcher: " << reply.error(); - return false; - } - - mFileDescriptor = reply.value(); - return true; -} - -void ConsoleKit2Provider::release() -{ - if (mFileDescriptor.isValid()) - { - ::close(mFileDescriptor.fileDescriptor()); - mFileDescriptor.setFileDescriptor(-1); - } -} diff --git a/lxqt-session/src/lockscreenmanager.h b/lxqt-session/src/lockscreenmanager.h deleted file mode 100644 index 35bc50f..0000000 --- a/lxqt-session/src/lockscreenmanager.h +++ /dev/null @@ -1,106 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXQt - a lightweight, Qt based, desktop toolset - * http://lxqt.org/ - * - * Copyright: 2016 LXQt team - * Authors: - * Paulo Lieuthier - * - * This program or library is free software; you can redistribute it - * and/or modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - - * You should have received a copy of the GNU Lesser General - * Public License along with this library; if not, write to the - * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#ifndef LOCKSCREENMANAGER_H -#define LOCKSCREENMANAGER_H - -#include -#include -#include -#include -#include - -class LockScreenProvider : public QObject -{ - Q_OBJECT - -public: - virtual ~LockScreenProvider() {} - - virtual bool isValid() = 0; - virtual bool inhibit() = 0; - virtual void release() = 0; - -signals: - void aboutToSleep(bool beforeSleep); - void lockRequested(); -}; - -class LogindProvider : public LockScreenProvider -{ - Q_OBJECT - -public: - explicit LogindProvider(); - virtual ~LogindProvider(); - - bool isValid() override; - bool inhibit() override; - void release() override; - -private: - QDBusInterface mInterface; - QDBusUnixFileDescriptor mFileDescriptor; -}; - -class ConsoleKit2Provider : public LockScreenProvider -{ - Q_OBJECT - -public: - explicit ConsoleKit2Provider(); - virtual ~ConsoleKit2Provider(); - - bool isValid() override; - bool inhibit() override; - void release() override; - -private: - QDBusInterface mInterface; - bool mMethodInhibitPresent; - QDBusUnixFileDescriptor mFileDescriptor; -}; - -class LockScreenManager : public QObject -{ - Q_OBJECT - -public: - explicit LockScreenManager(QObject *parent = nullptr); - virtual ~LockScreenManager(); - - bool startup(bool lockBeforeSleep); - -private: - LockScreenProvider *mProvider; - - // screensaver - LXQt::ScreenSaver mScreenSaver; - QEventLoop mLoop; -}; - -#endif diff --git a/lxqt-session/src/log.cpp b/lxqt-session/src/log.cpp deleted file mode 100644 index a20f0e8..0000000 --- a/lxqt-session/src/log.cpp +++ /dev/null @@ -1,36 +0,0 @@ - -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXQt - a lightweight, Qt based, desktop toolset - * http://lxqt.org - * - * Copyright: 2016 LXQt team - * Authors: - * Palo Kisa - * - * This program or library is free software; you can redistribute it - * and/or modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General - * Public License along with this library; if not, write to the - * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#include "log.h" -#include - -#if defined(NDEBUG) -Q_LOGGING_CATEGORY(SESSION, "lxqt-session", QtInfoMsg) -#else -Q_LOGGING_CATEGORY(SESSION, "lxqt-session") -#endif diff --git a/lxqt-session/src/log.h b/lxqt-session/src/log.h deleted file mode 100644 index cad06c3..0000000 --- a/lxqt-session/src/log.h +++ /dev/null @@ -1,35 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXQt - a lightweight, Qt based, desktop toolset - * http://lxqt.org - * - * Copyright: 2016 LXQt team - * Authors: - * Palo Kisa - * - * This program or library is free software; you can redistribute it - * and/or modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General - * Public License along with this library; if not, write to the - * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#if !defined(log_h) -#define log_h - -#include - -Q_DECLARE_LOGGING_CATEGORY(SESSION) - -#endif //log_h diff --git a/lxqt-session/src/lxqtmodman.cpp b/lxqt-session/src/lxqtmodman.cpp deleted file mode 100644 index d2954cd..0000000 --- a/lxqt-session/src/lxqtmodman.cpp +++ /dev/null @@ -1,494 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXQt - a lightweight, Qt based, desktop toolset - * http://razor-qt.org, http://lxde.org/ - * - * Copyright: 2010-2011 LXQt team - * Authors: - * Petr Vanek - * Hong Jen Yee (PCMan) - * - * This program or library is free software; you can redistribute it - * and/or modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - - * You should have received a copy of the GNU Lesser General - * Public License along with this library; if not, write to the - * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#include "lxqtmodman.h" -#include -#include -#include -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include "wmselectdialog.h" -#include "windowmanager.h" -#include -#include "log.h" - -#include -#include - -#include - -#define MAX_CRASHES_PER_APP 5 - -using namespace LXQt; - -/** - * @brief the constructor, needs a valid modules.conf - */ -LXQtModuleManager::LXQtModuleManager(QObject* parent) - : QObject(parent), - mWmProcess(new QProcess(this)), - mThemeWatcher(new QFileSystemWatcher(this)), - mWmStarted(false), - mTrayStarted(false), - mWaitLoop(NULL) -{ - connect(mThemeWatcher, SIGNAL(directoryChanged(QString)), SLOT(themeFolderChanged(QString))); - connect(LXQt::Settings::globalSettings(), SIGNAL(lxqtThemeChanged()), SLOT(themeChanged())); - - qApp->installNativeEventFilter(this); -} - -void LXQtModuleManager::setWindowManager(const QString & windowManager) -{ - mWindowManager = windowManager; -} - -void LXQtModuleManager::startup(LXQt::Settings& s) -{ - // The lxqt-confupdate can update the settings of the WM, so run it first. - startConfUpdate(); - - // Start window manager - startWm(&s); - - startAutostartApps(); - - QStringList paths; - paths << XdgDirs::dataHome(false); - paths << XdgDirs::dataDirs(); - - foreach(const QString &path, paths) - { - QFileInfo fi(QString("%1/lxqt/themes").arg(path)); - if (fi.exists()) - mThemeWatcher->addPath(fi.absoluteFilePath()); - } - - themeChanged(); -} - -void LXQtModuleManager::startAutostartApps() -{ - // XDG autostart - XdgDesktopFileList fileList = XdgAutoStart::desktopFileList(); - QList trayApps; - for (XdgDesktopFileList::iterator i = fileList.begin(); i != fileList.end(); ++i) - { - if (i->value("X-LXQt-Need-Tray", false).toBool()) - trayApps.append(&(*i)); - else - { - startProcess(*i); - qCDebug(SESSION) << "start" << i->fileName(); - } - } - - if (!trayApps.isEmpty()) - { - mTrayStarted = QSystemTrayIcon::isSystemTrayAvailable(); - if(!mTrayStarted) - { - QEventLoop waitLoop; - mWaitLoop = &waitLoop; - // add a timeout to avoid infinite blocking if a WM fail to execute. - QTimer::singleShot(60 * 1000, &waitLoop, SLOT(quit())); - waitLoop.exec(); - mWaitLoop = NULL; - } - foreach (XdgDesktopFile* f, trayApps) - { - qCDebug(SESSION) << "start tray app" << f->fileName(); - startProcess(*f); - } - } -} - -void LXQtModuleManager::themeFolderChanged(const QString& /*path*/) -{ - QString newTheme; - if (!QFileInfo(mCurrentThemePath).exists()) - { - const QList &allThemes = lxqtTheme.allThemes(); - if (!allThemes.isEmpty()) - newTheme = allThemes[0].name(); - else - return; - } - else - newTheme = lxqtTheme.currentTheme().name(); - - LXQt::Settings settings("lxqt"); - if (newTheme == settings.value("theme")) - { - // force the same theme to be updated - settings.setValue("__theme_updated__", QDateTime::currentMSecsSinceEpoch()); - } - else - settings.setValue("theme", newTheme); - - sync(); -} - -void LXQtModuleManager::themeChanged() -{ - if (!mCurrentThemePath.isEmpty()) - mThemeWatcher->removePath(mCurrentThemePath); - - if (lxqtTheme.currentTheme().isValid()) - { - mCurrentThemePath = lxqtTheme.currentTheme().path(); - mThemeWatcher->addPath(mCurrentThemePath); - } -} - -void LXQtModuleManager::startWm(LXQt::Settings *settings) -{ - // if the WM is active do not run WM. - // all window managers must set their name according to the spec - if (!QString(NETRootInfo(QX11Info::connection(), NET::SupportingWMCheck).wmName()).isEmpty()) - { - mWmStarted = true; - return; - } - - if (mWindowManager.isEmpty()) - { - mWindowManager = settings->value("window_manager").toString(); - } - - // If previuos WM was removed, we show dialog. - if (mWindowManager.isEmpty() || ! findProgram(mWindowManager.split(' ')[0])) - { - mWindowManager = showWmSelectDialog(); - settings->setValue("window_manager", mWindowManager); - settings->sync(); - } - - if (QFileInfo(mWindowManager).baseName() == "openbox") - { - // Default settings of openbox are copied by lxqt-common/startlxqt.in - QString openboxSettingsPath = XdgDirs::configHome() + "/openbox/lxqt-rc.xml"; - QStringList args; - if(QFileInfo::exists(openboxSettingsPath)) - args << "--config-file" << openboxSettingsPath; - mWmProcess->start(mWindowManager, args); - } - else - mWmProcess->start(mWindowManager); - - // other autostart apps will be handled after the WM becomes available - - // Wait until the WM loads - QEventLoop waitLoop; - mWaitLoop = &waitLoop; - // add a timeout to avoid infinite blocking if a WM fail to execute. - QTimer::singleShot(30 * 1000, &waitLoop, SLOT(quit())); - waitLoop.exec(); - mWaitLoop = NULL; - // FIXME: blocking is a bad idea. We need to start as many apps as possible and - // only wait for the start of WM when it's absolutely needed. - // Maybe we can add a X-Wait-WM=true key in the desktop entry file? -} - -void LXQtModuleManager::startProcess(const XdgDesktopFile& file) -{ - if (!file.value("X-LXQt-Module", false).toBool()) - { - file.startDetached(); - return; - } - QStringList args = file.expandExecString(); - if (args.isEmpty()) - { - qCWarning(SESSION) << "Wrong desktop file" << file.fileName(); - return; - } - LXQtModule* proc = new LXQtModule(file, this); - connect(proc, SIGNAL(moduleStateChanged(QString,bool)), this, SIGNAL(moduleStateChanged(QString,bool))); - proc->start(); - - QString name = QFileInfo(file.fileName()).fileName(); - mNameMap[name] = proc; - - connect(proc, SIGNAL(finished(int, QProcess::ExitStatus)), - this, SLOT(restartModules(int, QProcess::ExitStatus))); -} - -void LXQtModuleManager::startProcess(const QString& name) -{ - if (!mNameMap.contains(name)) - { - foreach (const XdgDesktopFile& file, XdgAutoStart::desktopFileList(false)) - { - if (QFileInfo(file.fileName()).fileName() == name) - { - startProcess(file); - return; - } - } - } -} - -void LXQtModuleManager::stopProcess(const QString& name) -{ - if (mNameMap.contains(name)) - mNameMap[name]->terminate(); -} - -QStringList LXQtModuleManager::listModules() const -{ - return QStringList(mNameMap.keys()); -} - -void LXQtModuleManager::startConfUpdate() -{ - XdgDesktopFile desktop(XdgDesktopFile::ApplicationType, ":lxqt-confupdate", "lxqt-confupdate --watch"); - desktop.setValue("Name", "LXQt config updater"); - desktop.setValue("X-LXQt-Module", true); - startProcess(desktop); -} - -void LXQtModuleManager::restartModules(int /*exitCode*/, QProcess::ExitStatus exitStatus) -{ - LXQtModule* proc = qobject_cast(sender()); - if (nullptr == proc) { - qCWarning(SESSION) << "Got an invalid (null) module to restart. Ignoring it"; - return; - } - - if (!proc->isTerminating()) - { - QString procName = proc->file.name(); - switch (exitStatus) - { - case QProcess::NormalExit: - qCDebug(SESSION) << "Process" << procName << "(" << proc << ") exited correctly."; - break; - case QProcess::CrashExit: - { - qCDebug(SESSION) << "Process" << procName << "(" << proc << ") has to be restarted"; - time_t now = time(NULL); - mCrashReport[proc].prepend(now); - while (now - mCrashReport[proc].back() > 60) - mCrashReport[proc].pop_back(); - if (mCrashReport[proc].length() >= MAX_CRASHES_PER_APP) - { - QMessageBox::warning(0, tr("Crash Report"), - tr("%1 crashed too many times. Its autorestart has been disabled until next login.").arg(procName)); - } - else - { - proc->start(); - return; - } - break; - } - } - } - mNameMap.remove(proc->fileName); - proc->deleteLater(); -} - - -LXQtModuleManager::~LXQtModuleManager() -{ - qApp->removeNativeEventFilter(this); - - // We disconnect the finished signal before deleting the process. We do - // this to prevent a crash that results from a state change signal being - // emmited while deleting a crashing module. - // If the module is still connect restartModules will be called with a - // invalid sender. - - ModulesMapIterator i(mNameMap); - while (i.hasNext()) - { - i.next(); - - auto p = i.value(); - disconnect(p, SIGNAL(finished(int, QProcess::ExitStatus)), 0, 0); - - delete p; - mNameMap[i.key()] = nullptr; - } - - delete mWmProcess; -} - -/** -* @brief this logs us out by terminating our session -**/ -void LXQtModuleManager::logout(bool doExit) -{ - // modules - ModulesMapIterator i(mNameMap); - while (i.hasNext()) - { - i.next(); - qCDebug(SESSION) << "Module logout" << i.key(); - LXQtModule* p = i.value(); - p->terminate(); - } - i.toFront(); - while (i.hasNext()) - { - i.next(); - LXQtModule* p = i.value(); - if (p->state() != QProcess::NotRunning && !p->waitForFinished(2000)) - { - qCWarning(SESSION) << QString("Module '%1' won't terminate ... killing.").arg(i.key()); - p->kill(); - } - } - - mWmProcess->terminate(); - if (mWmProcess->state() != QProcess::NotRunning && !mWmProcess->waitForFinished(2000)) - { - qCWarning(SESSION) << QString("Window Manager won't terminate ... killing."); - mWmProcess->kill(); - } - - if (doExit) - QCoreApplication::exit(0); -} - -QString LXQtModuleManager::showWmSelectDialog() -{ - WindowManagerList availableWM = getWindowManagerList(true); - if (availableWM.count() == 1) - return availableWM.at(0).command; - - WmSelectDialog dlg(availableWM); - dlg.exec(); - return dlg.windowManager(); -} - -void LXQtModuleManager::resetCrashReport() -{ - mCrashReport.clear(); -} - -bool LXQtModuleManager::nativeEventFilter(const QByteArray & eventType, void * /*message*/, long * /*result*/) -{ - if (eventType != "xcb_generic_event_t") // We only want to handle XCB events - return false; - - if(!mWmStarted && mWaitLoop) - { - // all window managers must set their name according to the spec - if (!QString(NETRootInfo(QX11Info::connection(), NET::SupportingWMCheck).wmName()).isEmpty()) - { - qCDebug(SESSION) << "Window Manager started"; - mWmStarted = true; - if (mWaitLoop->isRunning()) - mWaitLoop->exit(); - } - } - - if (!mTrayStarted && QSystemTrayIcon::isSystemTrayAvailable() && mWaitLoop) - { - qCDebug(SESSION) << "System Tray started"; - mTrayStarted = true; - if (mWaitLoop->isRunning()) - mWaitLoop->exit(); - - // window manager and system tray have started - qApp->removeNativeEventFilter(this); - } - - return false; -} - -void lxqt_setenv(const char *env, const QByteArray &value) -{ - wordexp_t p; - wordexp(value, &p, 0); - if (p.we_wordc == 1) - { - - qCDebug(SESSION) << "Environment variable" << env << "=" << p.we_wordv[0]; - qputenv(env, p.we_wordv[0]); - } - else - { - qCWarning(SESSION) << "Error expanding environment variable" << env << "=" << value; - qputenv(env, value); - } - wordfree(&p); -} - -void lxqt_setenv_prepend(const char *env, const QByteArray &value, const QByteArray &separator) -{ - QByteArray orig(qgetenv(env)); - orig = orig.prepend(separator); - orig = orig.prepend(value); - qCDebug(SESSION) << "Setting special" << env << " variable:" << orig; - lxqt_setenv(env, orig); -} - -LXQtModule::LXQtModule(const XdgDesktopFile& file, QObject* parent) : - QProcess(parent), - file(file), - fileName(QFileInfo(file.fileName()).fileName()), - mIsTerminating(false) -{ - connect(this, SIGNAL(stateChanged(QProcess::ProcessState)), SLOT(updateState(QProcess::ProcessState))); -} - -void LXQtModule::start() -{ - mIsTerminating = false; - QStringList args = file.expandExecString(); - QString command = args.takeFirst(); - QProcess::start(command, args); -} - -void LXQtModule::terminate() -{ - mIsTerminating = true; - QProcess::terminate(); -} - -bool LXQtModule::isTerminating() -{ - return mIsTerminating; -} - -void LXQtModule::updateState(QProcess::ProcessState newState) -{ - if (newState != QProcess::Starting) - emit moduleStateChanged(fileName, (newState == QProcess::Running)); -} diff --git a/lxqt-session/src/lxqtmodman.h b/lxqt-session/src/lxqtmodman.h deleted file mode 100644 index fbebc15..0000000 --- a/lxqt-session/src/lxqtmodman.h +++ /dev/null @@ -1,211 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXQt - a lightweight, Qt based, deskop environment - * http://razor-qt.org, http://lxqt.org/ - * - * Copyright: 2010-2011 LXQt team - * Authors: - * Petr Vanek - * - * This program or library is free software; you can redistribute it - * and/or modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - - * You should have received a copy of the GNU Lesser General - * Public License along with this library; if not, write to the - * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#ifndef LXQTMODMAN_H -#define LXQTMODMAN_H - -#include -#include -#include -#include -#include -#include -#include -#include - -class LXQtModule; -namespace LXQt { -class Settings; -} -class QFileSystemWatcher; - -typedef QMap ModulesMap; -typedef QMapIterator ModulesMapIterator; -typedef QList ModuleCrashReport; -typedef QMap ModulesCrashReport; - -/*! \brief LXQtModuleManager manages the processes of the session -and which modules of lxqt are about to load. - -LXQtModuleManager handles the session management (logout/restart/shutdown) -as well. - -Also it watches the current theme to react if it was removed or modified. - -Processes in LXQtModuleManager are started as follows: - - run lxqt-confupdate - - start the window manager and wait until it's active - - start all normal autostart items (including LXQt modules) - - if there are any applications that need a system tray, wait until a system tray - implementation becomes active, and then start those - -Potential process recovering is done in \see restartModules() -*/ - -class LXQtModuleManager : public QObject, public QAbstractNativeEventFilter -{ - Q_OBJECT - -public: - //! \brief Construct LXQtModuleManager - LXQtModuleManager(QObject* parent = 0); - virtual ~LXQtModuleManager(); - - //! \brief Set the window manager (e.g. "/usr/bin/openbox") - void setWindowManager(const QString & windowManager); - - //! \brief Start a module given its file name (e.g. "lxqt-panel.desktop") - void startProcess(const QString& name); - - //! \brief Stop a running module - void stopProcess(const QString& name); - - //! \brief List the running modules, identified by their file names - QStringList listModules() const; - - //! \brief Read configuration and start processes - void startup(LXQt::Settings& s); - - // Qt5 uses native event filter - virtual bool nativeEventFilter(const QByteArray & eventType, void * message, long * result); - -public slots: - /*! \brief Exit LXQt session. - It tries to terminate processes from procMap and autostartList - gracefully (to kill it if it is not possible). Then the session - exits - it returns to the kdm/gdm in most cases. - */ - void logout(bool doExit); - -signals: - void moduleStateChanged(QString moduleName, bool state); - -private: - //! \brief Start Window Manager - void startWm(LXQt::Settings *settings); - void wmStarted(); - - void startAutostartApps(); - - //! \brief Show Window Manager select dialog - QString showWmSelectDialog(); - - //! \brief Start a process described in a desktop file - void startProcess(const XdgDesktopFile &file); - - //! \brief Start the lxqt-confupdate. - void startConfUpdate(); - - //! \brief Window manager command - QString mWindowManager; - - //! \brief map file names to module processes - ModulesMap mNameMap; - - //! \brief the window manager - QProcess* mWmProcess; - - /*! \brief Keep creashes for given process to raise a message in the - case of repeating crashes - */ - ModulesCrashReport mCrashReport; - - //! \brief file system watcher to react on theme modifications - QFileSystemWatcher *mThemeWatcher; - QString mCurrentThemePath; - - bool mWmStarted; - bool mTrayStarted; - QEventLoop* mWaitLoop; - -private slots: - - /*! \brief this slot is called by the QProcesses if they end. - \warning The slot *has* to be called as a slot only due sender() cast. - - There are 2 types of handling in this slot. - - If the process has ended correctly (no crash or kill) nothing happens - except when the process is *not* specified with doespower in the - configuration. If there is no "doespower" (window manager mainly) - entire session performs logout. (Handling of the window manager 3rd - party "logout") - - If the process crashed and is set as "doespower" it's tried to - be restarted automatically. - */ - void restartModules(int exitCode, QProcess::ExitStatus exitStatus); - - /*! Clear m_crashReport after some amount of time - */ - void resetCrashReport(); - - void themeFolderChanged(const QString&); - - void themeChanged(); -}; - - -/*! \brief platform independent way how to set up an environment variable. -It sets env variable for all lxqt-session childs. -\param env a raw string variable name (PATH, TERM, ...) -\param value a QByteArray with the value. Variable will use this new value only - - no appending/prepending is performed. -See lxqt_setenv_prepend. -*/ -void lxqt_setenv(const char *env, const QByteArray &value); -/*! \brief Set up a environment variable with original value with new value prepending. -\param env a raw string with variable name -\param value a QByteArray value to be pre-pend to original content of the variable -\param separator an optional string with separator character. Eg. ":" for PATH. -See lxqt_setenv. -*/ -void lxqt_setenv_prepend(const char *env, const QByteArray &value, const QByteArray &separator=":"); - -class LXQtModule : public QProcess -{ - Q_OBJECT -public: - LXQtModule(const XdgDesktopFile& file, QObject *parent = 0); - void start(); - void terminate(); - bool isTerminating(); - - const XdgDesktopFile file; - const QString fileName; - -signals: - void moduleStateChanged(QString name, bool state); - -private slots: - void updateState(QProcess::ProcessState newState); - -private: - bool mIsTerminating; -}; - -#endif diff --git a/lxqt-session/src/main.cpp b/lxqt-session/src/main.cpp deleted file mode 100644 index 435660b..0000000 --- a/lxqt-session/src/main.cpp +++ /dev/null @@ -1,71 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXQt - a lightweight, Qt based, desktop toolset - * http://razor-qt.org, http://lxde.org/ - * - * Copyright: 2010-2011 LXQt team - * Authors: - * Petr Vanek - * - * This program or library is free software; you can redistribute it - * and/or modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - - * You should have received a copy of the GNU Lesser General - * Public License along with this library; if not, write to the - * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#include "sessionapplication.h" -#include - -/** -* @file main.cpp -* @author Christopher "VdoP" Regali -* @brief just starts the sub-apps and in future maybe saves the windowstates - -lxqt-session can be called as is (without any argument) - it will start -"failback" session (sessionf.conf). When there will be used -c foo argument -lxqt-session -c foo -it will use foo.conf. Currently there are launchers for windowmanagers: -session-openbox.conf -session-eggwm.conf -*/ - - -/** -* @brief our main function doing the loading -*/ -int main(int argc, char **argv) -{ - SessionApplication app(argc, argv); - //qDebug() << "LXQt Session start"; - QCommandLineParser parser; - parser.setApplicationDescription(QStringLiteral("LXQt Session")); - const QString VERINFO = QStringLiteral(LXQT_SESSION_VERSION - "\nliblxqt " LXQT_VERSION - "\nQt " QT_VERSION_STR); - app.setApplicationVersion(VERINFO); - const QCommandLineOption config_opt{{"c", "config"}, SessionApplication::tr("Configuration file path."), SessionApplication::tr("file")}; - const QCommandLineOption wm_opt{{"w", "window-manager"}, SessionApplication::tr("Window manager to use."), SessionApplication::tr("file")}; - const auto version_opt = parser.addVersionOption(); - const auto help_opt = parser.addHelpOption(); - parser.addOptions({config_opt, wm_opt}); - parser.process(app); - - app.setConfigName(parser.value(config_opt)); - app.setWindowManager(parser.value(wm_opt)); - - app.setQuitOnLastWindowClosed(false); - return app.exec(); -} - diff --git a/lxqt-session/src/numlock.cpp b/lxqt-session/src/numlock.cpp deleted file mode 100644 index 18fd20e..0000000 --- a/lxqt-session/src/numlock.cpp +++ /dev/null @@ -1,83 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LxQt - a lightweight, Qt based, desktop toolset - * http://razor-qt.org, http://lxde.org/ - * - * Copyright: 2010-2011 LxQt team - * Authors: - * Hong Jen Yee (PCMan) - * - * This program or library is free software; you can redistribute it - * and/or modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - - * You should have received a copy of the GNU Lesser General - * Public License along with this library; if not, write to the - * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -// the following XKB code is taken from numlockx which is licensed under MIT. -// Copyright (C) 2000-2001 Lubos Lunak -// Copyright (C) 2001 Oswald Buddenhagen - -#include -#include -#include -#include -#include -#include - -/* the XKB stuff is based on code created by Oswald Buddenhagen */ - -static unsigned int xkb_mask_modifier(Display* /*dpy*/, XkbDescPtr xkb, const char *name ) -{ - int i; - if( !xkb || !xkb->names ) - return 0; - for( i = 0; i < XkbNumVirtualMods; i++ ) { - char* modStr = XGetAtomName( xkb->dpy, xkb->names->vmods[i] ); - if( modStr != NULL && strcmp(name, modStr) == 0 ) { - unsigned int mask; - XkbVirtualModsToReal( xkb, 1 << i, &mask ); - return mask; - } - } - return 0; -} - -static unsigned int xkb_numlock_mask(Display* dpy) -{ - XkbDescPtr xkb; - if(( xkb = XkbGetKeyboard( dpy, XkbAllComponentsMask, XkbUseCoreKbd )) != NULL ) { - unsigned int mask = xkb_mask_modifier( dpy, xkb, "NumLock" ); - XkbFreeKeyboard( xkb, 0, True ); - return mask; - } - return 0; -} - -static int xkb_set_on(Display* dpy) -{ - unsigned int mask; - mask = xkb_numlock_mask(dpy); - if( mask == 0 ) - return 0; - XkbLockModifiers ( dpy, XkbUseCoreKbd, mask, mask); - return 1; -} - -void enableNumlock() -{ - // this currently only works for X11 - if(QX11Info::isPlatformX11()) - xkb_set_on(QX11Info::display()); -} diff --git a/lxqt-session/src/numlock.h b/lxqt-session/src/numlock.h deleted file mode 100644 index b9b347d..0000000 --- a/lxqt-session/src/numlock.h +++ /dev/null @@ -1,33 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LxQt - a lightweight, Qt based, desktop toolset - * http://razor-qt.org, http://lxde.org/ - * - * Copyright: 2010-2011 LxQt team - * Authors: - * Hong Jen Yee (PCMan) - * - * This program or library is free software; you can redistribute it - * and/or modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - - * You should have received a copy of the GNU Lesser General - * Public License along with this library; if not, write to the - * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#ifndef _NUMLOCK_H_ -#define _NUMLOCK_H_ - -void enableNumlock(); - -#endif diff --git a/lxqt-session/src/sessionapplication.cpp b/lxqt-session/src/sessionapplication.cpp deleted file mode 100644 index 570558b..0000000 --- a/lxqt-session/src/sessionapplication.cpp +++ /dev/null @@ -1,312 +0,0 @@ -/* - * Copyright (C) 2014 Hong Jen Yee (PCMan) - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA - * - */ - -#include "sessionapplication.h" -#include "sessiondbusadaptor.h" -#include "lxqtmodman.h" -#include "UdevNotifier.h" -#include "numlock.h" -#include "lockscreenmanager.h" -#include -#include -#include -#include -#include "log.h" - -#include -// XKB, this should be disabled in Wayland? -#include - -SessionApplication::SessionApplication(int& argc, char** argv) : - LXQt::Application(argc, argv), - lockScreenManager(new LockScreenManager(this)) -{ - listenToUnixSignals({SIGINT, SIGTERM, SIGQUIT, SIGHUP}); - - modman = new LXQtModuleManager; - connect(this, &LXQt::Application::unixSignal, modman, [this] { modman->logout(true); }); - new SessionDBusAdaptor(modman); - // connect to D-Bus and register as an object: - QDBusConnection::sessionBus().registerService("org.lxqt.session"); - QDBusConnection::sessionBus().registerObject("/LXQtSession", modman); - - // Wait until the event loop starts - QTimer::singleShot(0, this, SLOT(startup())); -} - -SessionApplication::~SessionApplication() -{ - delete modman; -} - -void SessionApplication::setWindowManager(const QString& windowManager) -{ - modman->setWindowManager(windowManager); -} - -void SessionApplication::setConfigName(const QString& configName) -{ - if(configName.isEmpty()) - this->configName = "session"; - - // tell the world which config file we're using. - qputenv("LXQT_SESSION_CONFIG", this->configName.toLocal8Bit()); -} - -bool SessionApplication::startup() -{ - LXQt::Settings settings(configName); - qCDebug(SESSION) << __FILE__ << ":" << __LINE__ << "Session" << configName << "about to launch (default 'session')"; - - loadEnvironmentSettings(settings); - // loadFontSettings(settings); - loadKeyboardSettings(settings); - loadMouseSettings(settings); - -#if defined(WITH_LIBUDEV_MONITOR) - UdevNotifier * dev_notifier = new UdevNotifier{QStringLiteral("input"), this}; //will be released upon our destruction - QTimer * dev_timer = new QTimer{this}; //will be released upon our destruction - dev_timer->setSingleShot(true); - dev_timer->setInterval(500); //give some time to xorg... we need to reset keyboard afterwards - connect(dev_timer, &QTimer::timeout, [this] - { - //XXX: is this a race? (because settings can be currently changed by lxqt-config-input) - // but with such a little probablity we can live... - LXQt::Settings settings(configName); - loadKeyboardSettings(settings); - }); - connect(dev_notifier, &UdevNotifier::deviceAdded, [this, dev_timer] (QString device) - { - qCWarning(SESSION) << QStringLiteral("Session '%1', new input device '%2', keyboard setting will be (optionaly) reloaded...").arg(configName).arg(device); - dev_timer->start(); - }); -#endif - - bool lockBeforeSleep = settings.value(QLatin1String("lock_screen_before_power_actions"), true).toBool(); - if (lockScreenManager->startup(lockBeforeSleep)) - qCDebug(SESSION) << "LockScreenManager started successfully"; - else - qCWarning(SESSION) << "LockScreenManager couldn't start"; - - // launch module manager and autostart apps - modman->startup(settings); - - return true; -} - -void SessionApplication::mergeXrdb(const char* content, int len) -{ - qCDebug(SESSION) << "xrdb:" << content; - QProcess xrdb; - xrdb.start("xrdb -merge -"); - xrdb.write(content, len); - xrdb.closeWriteChannel(); - xrdb.waitForFinished(); -} - -void SessionApplication::loadEnvironmentSettings(LXQt::Settings& settings) -{ - // first - set some user defined environment variables (like TERM...) - settings.beginGroup("Environment"); - QByteArray envVal; - Q_FOREACH (QString i, settings.childKeys()) - { - envVal = settings.value(i).toByteArray(); - lxqt_setenv(i.toLocal8Bit().constData(), envVal); - } - settings.endGroup(); -} - -// FIXME: how to set keyboard layout in Wayland? -void SessionApplication::setxkbmap(QString layout, QString variant, QString model, QStringList options) { - QStringList args; - if(!model.isEmpty()) { - args << QStringLiteral("-model"); - args << model; - } - if(!layout.isEmpty()) { - args << QStringLiteral("-layout"); - args << layout; - - if(!variant.isEmpty()) { - args << QStringLiteral("-variant"); - args << variant; - } - } - if(!options.isEmpty()) { - Q_FOREACH(const QString& option, options) { - args << QStringLiteral("-option"); - args << option; - } - } - // execute the command line - if (!args.isEmpty()) - QProcess::startDetached(QStringLiteral("setxkbmap"), args); -} - -void SessionApplication::loadKeyboardSettings(LXQt::Settings& settings) -{ - qCDebug(SESSION) << settings.fileName(); - settings.beginGroup("Keyboard"); - XKeyboardControl values; - /* Keyboard settings */ - unsigned int delay, interval; - if(XkbGetAutoRepeatRate(QX11Info::display(), XkbUseCoreKbd, (unsigned int*) &delay, (unsigned int*) &interval)) - { - delay = settings.value("delay", delay).toUInt(); - interval = settings.value("interval", interval).toUInt(); - XkbSetAutoRepeatRate(QX11Info::display(), XkbUseCoreKbd, delay, interval); - } - - // turn on/off keyboard beep - bool beep = settings.value("beep").toBool(); - values.bell_percent = beep ? -1 : 0; - XChangeKeyboardControl(QX11Info::display(), KBBellPercent, &values); - - // turn on numlock as needed - if(settings.value("numlock").toBool()) - enableNumlock(); - - // keyboard layout support using setxkbmap - QString layout = settings.value("layout").toString(); - QString variant = settings.value("variant").toString(); - QString model = settings.value("model").toString(); - QStringList options = settings.value("options").toStringList(); - setxkbmap(layout, variant, model, options); - - settings.endGroup(); -} - -void SessionApplication::loadMouseSettings(LXQt::Settings& settings) -{ - settings.beginGroup("Mouse"); - - // mouse cursor (does this work?) - QString cursorTheme = settings.value("cursor_theme").toString(); - int cursorSize = settings.value("cursor_size").toInt(); - QByteArray buf; - if(!cursorTheme.isEmpty()) { - buf += "Xcursor.theme:"; - buf += cursorTheme; - buf += '\n'; - } - if(cursorSize > 0) { - buf += "Xcursor.size:"; - buf += QString("%1").arg(cursorSize); - buf += '\n'; - } - if(!buf.isEmpty()) { - buf += "Xcursor.theme_core:true\n"; - mergeXrdb(buf.constData(), buf.length()); - } - - // other mouse settings - int accel_factor = settings.value("accel_factor").toInt(); - int accel_threshold = settings.value("accel_threshold").toInt(); - if(accel_factor || accel_threshold) - XChangePointerControl(QX11Info::display(), accel_factor != 0, accel_threshold != 0, accel_factor, 10, accel_threshold); - - // left handed mouse? - bool left_handed = settings.value("left_handed", false).toBool(); - setLeftHandedMouse(left_handed); - - settings.endGroup(); -} - -# if 0 -// already deprecated by direct fontconfig support of lxqt-config - -void SessionApplication::loadFontSettings(LXQt::Settings& settings) -{ - // set some Xft config values, such as antialiasing & subpixel - // may call mergeXrdb() to do it. (will this work?) - // font settings of gtk+ programs are controlled by gtkrc and settings.ini files. - settings.beginGroup("Font"); - QByteArray buf; - bool antialias = settings.value("antialias", true).toBool(); - buf += "Xft.antialias:"; - buf += antialias ? "true" : "false"; - buf += '\n'; - - buf += "Xft.rgba:"; - buf += settings.value("subpixel", "none").toByteArray(); - buf += '\n'; - - bool hinting = settings.value("hinting", true).toBool(); - buf += "Xft.hinting:"; - buf += hinting ? "true" : "false"; - buf += '\n'; - - buf += "Xft.hintstyle:hint"; - buf += settings.value("hint_style", "none").toByteArray(); - buf += '\n'; - - int dpi = settings.value("dpi", 96).toInt(); - buf += "Xft.dpi:"; - buf += QString("%1").arg(dpi); - buf += '\n'; - - mergeXrdb(buf.constData(), buf.length()); - settings.endGroup(); -} -#endif - -/* This function is taken from Gnome's control-center 2.6.0.3 (gnome-settings-mouse.c) and was modified*/ -#define DEFAULT_PTR_MAP_SIZE 128 -void SessionApplication::setLeftHandedMouse(bool mouse_left_handed) -{ - unsigned char *buttons, *more_buttons; - int n_buttons, i; - int idx_1 = 0, idx_3 = 1; - - buttons = (unsigned char*)malloc(DEFAULT_PTR_MAP_SIZE); - if (!buttons) - { - return; - } - n_buttons = XGetPointerMapping(QX11Info::display(), buttons, DEFAULT_PTR_MAP_SIZE); - if (n_buttons > DEFAULT_PTR_MAP_SIZE) - { - more_buttons = (unsigned char*)realloc(buttons, n_buttons); - if (!more_buttons) - { - free(buttons); - return; - } - buttons = more_buttons; - n_buttons = XGetPointerMapping(QX11Info::display(), buttons, n_buttons); - } - - for (i = 0; i < n_buttons; i++) - { - if (buttons[i] == 1) - idx_1 = i; - else if (buttons[i] == ((n_buttons < 3) ? 2 : 3)) - idx_3 = i; - } - - if ((mouse_left_handed && idx_1 < idx_3) || - (!mouse_left_handed && idx_1 > idx_3)) - { - buttons[idx_1] = ((n_buttons < 3) ? 2 : 3); - buttons[idx_3] = 1; - XSetPointerMapping(QX11Info::display(), buttons, n_buttons); - } - free(buttons); -} diff --git a/lxqt-session/src/sessionapplication.h b/lxqt-session/src/sessionapplication.h deleted file mode 100644 index 421f705..0000000 --- a/lxqt-session/src/sessionapplication.h +++ /dev/null @@ -1,57 +0,0 @@ -/* - * Copyright (C) 2014 Hong Jen Yee (PCMan) - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA - * - */ - -#ifndef SESSIONAPPLICATION_H -#define SESSIONAPPLICATION_H - -#include -#include - -class LXQtModuleManager; -class LockScreenManager; - -class SessionApplication : public LXQt::Application -{ - Q_OBJECT -public: - SessionApplication(int& argc, char** argv); - ~SessionApplication(); - void setWindowManager(const QString & windowManager); - void setConfigName(const QString & configName); - -private Q_SLOTS: - bool startup(); - -private: - void loadEnvironmentSettings(LXQt::Settings& settings); - void loadKeyboardSettings(LXQt::Settings& settings); - void loadMouseSettings(LXQt::Settings& settings); - // void loadFontSettings(LXQt::Settings& settings); - - void setxkbmap(QString layout, QString variant, QString model, QStringList options); - - void mergeXrdb(const char* content, int len); - void setLeftHandedMouse(bool mouse_left_handed); -private: - LXQtModuleManager* modman; - LockScreenManager *lockScreenManager; - QString configName; -}; - -#endif // SESSIONAPPLICATION_H diff --git a/lxqt-session/src/sessiondbusadaptor.h b/lxqt-session/src/sessiondbusadaptor.h deleted file mode 100644 index ecb1f3f..0000000 --- a/lxqt-session/src/sessiondbusadaptor.h +++ /dev/null @@ -1,117 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXQt - a lightweight, Qt based, desktop toolset - * http://razor-qt.org, http://lxde.org/ - * - * Copyright: 2010-2011 LXQt team - * Authors: - * Petr Vanek - * - * This program or library is free software; you can redistribute it - * and/or modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - - * You should have received a copy of the GNU Lesser General - * Public License along with this library; if not, write to the - * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#ifndef SESSIONDBUS_H -#define SESSIONDBUS_H - -#include -#include - -#include "lxqtmodman.h" - - -/*! \brief Simple DBus adaptor for LXQtSession. -It allows 3rd party apps/lxqt modules to logout from session. -It's a part of "LXQt Power Management" - see liblxqt. -\author Petr Vanek -*/ -class SessionDBusAdaptor : public QDBusAbstractAdaptor -{ - Q_OBJECT - Q_CLASSINFO("D-Bus Interface", "org.lxqt.session") - -public: - SessionDBusAdaptor(LXQtModuleManager * manager) - : QDBusAbstractAdaptor(manager), - m_manager(manager), - m_power(false/*don't use ourself, just all other power providers*/) - { - connect(m_manager, SIGNAL(moduleStateChanged(QString,bool)), SIGNAL(moduleStateChanged(QString,bool))); - } - -signals: - void moduleStateChanged(QString moduleName, bool state); - -public slots: - - // there can be a situation when is the session asked for availability. - // And the lxqt-session is not always required to be started... - bool canLogout() - { - return true; - } - - bool canReboot() - { - return m_power.canReboot(); - } - - bool canPowerOff() - { - return m_power.canShutdown(); - } - - Q_NOREPLY void logout() - { - m_manager->logout(true); - } - - Q_NOREPLY void reboot() - { - m_manager->logout(false); - m_power.reboot(); - QCoreApplication::exit(0); - } - - Q_NOREPLY void powerOff() - { - m_manager->logout(false); - m_power.shutdown(); - QCoreApplication::exit(0); - } - - QDBusVariant listModules() - { - return QDBusVariant(m_manager->listModules()); - } - - Q_NOREPLY void startModule(const QString& name) - { - m_manager->startProcess(name); - } - - Q_NOREPLY void stopModule(const QString& name) - { - m_manager->stopProcess(name); - } - -private: - LXQtModuleManager * m_manager; - LXQt::Power m_power; -}; - -#endif diff --git a/lxqt-session/src/windowmanager.cpp b/lxqt-session/src/windowmanager.cpp deleted file mode 100644 index 53cb951..0000000 --- a/lxqt-session/src/windowmanager.cpp +++ /dev/null @@ -1,79 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXQt - a lightweight, Qt based, desktop toolset - * http://razor-qt.org, http://lxde.org/ - * - * Copyright: 2010-2011 LXQt team - * Authors: - * Petr Vanek - * - * This program or library is free software; you can redistribute it - * and/or modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - - * You should have received a copy of the GNU Lesser General - * Public License along with this library; if not, write to the - * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#include "windowmanager.h" - -#include -#include -#include -#include -#include -#include - - -bool findProgram(const QString &program) -{ - QFileInfo fi(program); - if (fi.isExecutable()) - return true; - - QString path = qgetenv("PATH"); - foreach(const QString &dir, path.split(":")) - { - QFileInfo fi= QFileInfo(dir + QDir::separator() + program); - if (fi.isExecutable() ) - return true; - } - return false; -} - -WindowManagerList getWindowManagerList(bool onlyAvailable) -{ - LXQt::Settings cfg("windowmanagers"); - cfg.beginGroup("KnownManagers"); - QStringList names = cfg.childGroups(); - - WindowManagerList ret; - - foreach (const QString &name, names) - { - bool exists = findProgram(name); - if (!onlyAvailable || exists) - { - cfg.beginGroup(name); - WindowManager wm; - wm.command = name; - wm.name = cfg.localizedValue("Name", wm.command).toString(); - wm.comment = cfg.localizedValue("Comment").toString(); - wm.exists = exists; - ret << wm; - cfg.endGroup(); - } - } - - return ret; -} diff --git a/lxqt-session/src/windowmanager.h b/lxqt-session/src/windowmanager.h deleted file mode 100644 index a1dbc05..0000000 --- a/lxqt-session/src/windowmanager.h +++ /dev/null @@ -1,49 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXQt - a lightweight, Qt based, desktop toolset - * http://razor-qt.org, http://lxde.org/ - * - * Copyright: 2010-2011 LXQt team - * Authors: - * Petr Vanek - * - * This program or library is free software; you can redistribute it - * and/or modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - - * You should have received a copy of the GNU Lesser General - * Public License along with this library; if not, write to the - * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#ifndef WINDOWMANAGER_H -#define WINDOWMANAGER_H - -#include -#include - -struct WindowManager -{ - QString name; - QString command; - QString comment; - bool exists; -}; - -typedef QList WindowManagerList; - -/*! Helper functions for window manager detection */ -WindowManagerList getWindowManagerList(bool onlyAvailable=true); - -bool findProgram(const QString &program); - -#endif diff --git a/lxqt-session/src/wmselectdialog.cpp b/lxqt-session/src/wmselectdialog.cpp deleted file mode 100644 index 7292c05..0000000 --- a/lxqt-session/src/wmselectdialog.cpp +++ /dev/null @@ -1,137 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXQt - a lightweight, Qt based, desktop toolset - * http://razor-qt.org, http://lxde.org/ - * - * Copyright: 2010-2011 LXQt team - * Authors: - * Alexander Sokoloff - * - * This program or library is free software; you can redistribute it - * and/or modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - - * You should have received a copy of the GNU Lesser General - * Public License along with this library; if not, write to the - * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - - -#include "wmselectdialog.h" -#include "ui_wmselectdialog.h" -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#define TYPE_ROLE Qt::UserRole + 1 -#define SELECT_DLG_TYPE 12345 - -WmSelectDialog::WmSelectDialog(const WindowManagerList &availableWindowManagers, QWidget *parent) : - QDialog(parent), - ui(new Ui::WmSelectDialog) -{ - qApp->setStyle("plastique"); - ui->setupUi(this); - setModal(true); - connect(ui->wmList, SIGNAL(doubleClicked(QModelIndex)), this, SLOT(accept())); - connect(ui->wmList, SIGNAL(clicked(QModelIndex)), this, SLOT(selectFileDialog(QModelIndex))); - connect(ui->wmList, SIGNAL(activated(QModelIndex)), this, SLOT(changeBtnStatus(QModelIndex))); - - foreach (const WindowManager &wm, availableWindowManagers) - { - addWindowManager(wm); - } - - - QTreeWidgetItem *item = new QTreeWidgetItem(); - item->setText(0, tr("Other ...")); - item->setText(1, tr("Choose your favorite one.")); - item->setData(1, TYPE_ROLE, SELECT_DLG_TYPE); - - ui->wmList->setCurrentItem(ui->wmList->topLevelItem(0)); - ui->wmList->addTopLevelItem(item); -} - - -WmSelectDialog::~WmSelectDialog() -{ - delete ui; -} - - -void WmSelectDialog::done( int r ) -{ - QString wm = windowManager(); - if (r==1 && !wm.isEmpty() && findProgram(wm)) - { - QDialog::done( r ); - close(); - } -} - - -QString WmSelectDialog::windowManager() const -{ - QTreeWidgetItem *item = ui->wmList->currentItem(); - if (item) - return item->data(0, Qt::UserRole).toString(); - - return QString(); -} - - -void WmSelectDialog::addWindowManager(const WindowManager &wm) -{ - QTreeWidgetItem *item = new QTreeWidgetItem(); - - item->setText(0, wm.name); - item->setText(1, wm.comment); - item->setData(0, Qt::UserRole, wm.command); - - ui->wmList->addTopLevelItem(item); -} - - -void WmSelectDialog::selectFileDialog(const QModelIndex &/*index*/) -{ - QTreeWidget *wmList = ui->wmList; - QTreeWidgetItem *item = wmList->currentItem(); - if (item->data(1, TYPE_ROLE) != SELECT_DLG_TYPE) - return; - - QString fname = QFileDialog::getOpenFileName(this, "", "/usr/bin/"); - if (fname.isEmpty()) - return; - - QFileInfo fi(fname); - if (!fi.exists() || !fi.isExecutable()) - return; - - QTreeWidgetItem *wmItem = new QTreeWidgetItem(); - - wmItem->setText(0, fi.baseName()); - wmItem->setData(0, Qt::UserRole, fi.absoluteFilePath()); - wmList->insertTopLevelItem(wmList->topLevelItemCount() -1, wmItem); - ui->wmList->setCurrentItem(wmItem); -} - -void WmSelectDialog::changeBtnStatus(const QModelIndex &/*index*/) -{ - QString wm = windowManager(); - ui->buttonBox->setEnabled(!wm.isEmpty() && findProgram(wm)); -} diff --git a/lxqt-session/src/wmselectdialog.h b/lxqt-session/src/wmselectdialog.h deleted file mode 100644 index 36f9968..0000000 --- a/lxqt-session/src/wmselectdialog.h +++ /dev/null @@ -1,62 +0,0 @@ -/* BEGIN_COMMON_COPYRIGHT_HEADER - * (c)LGPL2+ - * - * LXQt - a lightweight, Qt based, desktop toolset - * http://razor-qt.org, http://lxde.org/ - * - * Copyright: 2010-2011 LXQt team - * Authors: - * Alexander Sokoloff - * - * This program or library is free software; you can redistribute it - * and/or modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - - * You should have received a copy of the GNU Lesser General - * Public License along with this library; if not, write to the - * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, - * Boston, MA 02110-1301 USA - * - * END_COMMON_COPYRIGHT_HEADER */ - -#ifndef WMSELECTDIALOG_H -#define WMSELECTDIALOG_H - -#include -#include "windowmanager.h" -class QModelIndex; - -namespace Ui { - class WmSelectDialog; -} - -class WmSelectDialog : public QDialog -{ - Q_OBJECT - -public: - explicit WmSelectDialog(const WindowManagerList &availableWindowManagers, - QWidget *parent = 0); - ~WmSelectDialog(); - QString windowManager() const; - -public slots: - void done(int); - -private slots: - void selectFileDialog(const QModelIndex &index); - void changeBtnStatus(const QModelIndex &index); - -private: - Ui::WmSelectDialog *ui; - - void addWindowManager(const WindowManager &wm); -}; - -#endif // WMSELECTDIALOG_H diff --git a/lxqt-session/src/wmselectdialog.ui b/lxqt-session/src/wmselectdialog.ui deleted file mode 100644 index 63d9c75..0000000 --- a/lxqt-session/src/wmselectdialog.ui +++ /dev/null @@ -1,125 +0,0 @@ - - - WmSelectDialog - - - - 0 - 0 - 352 - 276 - - - - Welcome to LXQt - - - - - - <html><head/><body><p><span style=" font-weight:600;">Welcome to LXQt</span></p><p>Please select your default Window Manager.</p></body></html> - - - true - - - - - - - - 50 - false - - - - QAbstractItemView::NoEditTriggers - - - true - - - false - - - true - - - true - - - 2 - - - false - - - - 1 - - - - - 2 - - - - - - - - You will be able to change this at any time through Preferences -> Session Settings -> Basic Settings. - - - true - - - - - - - Qt::Horizontal - - - QDialogButtonBox::Ok - - - - - - - - - buttonBox - accepted() - WmSelectDialog - accept() - - - 248 - 254 - - - 157 - 274 - - - - - buttonBox - rejected() - WmSelectDialog - reject() - - - 316 - 260 - - - 286 - 274 - - - - - diff --git a/startlxqt.1 b/startlxqt.1 deleted file mode 100644 index 9eaba03..0000000 --- a/startlxqt.1 +++ /dev/null @@ -1,48 +0,0 @@ -.TH STARTLXQT 1 2015-11-03 "LXQt 0.10.0" "LXQt session management" -.SH NAME -startlxqt \- script to initialize and launch LXQt sessions -.SH SYNOPSIS -.B startlxqt -.SH DESCRIPTION -\fBstartlxqt\fR is a shell script meant to initialize and launch LXQt sessions. -It is as such similar to counterparts of other desktop environments like startlxde in -LXDE or startkde in KDE. -.P -It's main tasks are exporting environment variables, partly after performing -corresponding checks, and launching \fBlxqt-session\fR, the LXQt session manager. -.P -It is not meant to be run by users. -Rather, it is invoked as backend, e. g. by script \fBstartx\fR on virtual terminals or display -managers like SDDM or LightDM, see section \fIEXAMPLE\fR. -.SH FILES -.I $XDG_DATA_DIRS/xsessions/lxqt.desktop -.RS 5 -Desktop entry file stating startlxqt as binary needed to start LXQt sessions. Sourced e. g. -by display managers. -.RE -.SH BUGS -None at the time of this writing. Bugs can be reported on https://github.com/lxde/lxqt/issues. -.SH EXAMPLE -To start an LXQt session from a virtual terminal (virtual console) add a line -.P -.RS 5 -exec startlxqt -.RE -.P -to file \fI~/.xinitrc\fR. An LXQt session will then be launched by running \fBstartx\fR. -.P -Display managers are making use of scripts like \fBstartlxqt\fR automatically. Information about -available desktop environments is provided by files \fI$XDG_DATA_DIRS/xsessions/*.desktop\fR, typically -\fI/usr/share/xessions/*.desktop\fR. -.br -File \fIlxqt.desktop\fR provided by LXQt is stating \fBstartlxqt\fR in key \fIExec\fR while making sure the session -manager \fBlxqt-session\fR does exist by stating it in key \fITryExec\fR. -.SH SEE ALSO -.BR lxqt-session (1) -.BR startx (1) -.BR sddm (1) -.P -.B http://www.freedesktop.org/wiki/Specifications/desktop-entry-spec/ -.RS 5 -Desktop Entry Specification defining desktop entry files (*.desktop). -.RE diff --git a/startlxqt.in b/startlxqt.in deleted file mode 100755 index 02ef0c2..0000000 --- a/startlxqt.in +++ /dev/null @@ -1,99 +0,0 @@ -#!/bin/sh - -contains() -{ - local str="$1" substr="$2" - [ "$str" = "$substr" -o -z "${str##$substr:*}" -o -z "${str##*:$substr:*}" -o -z "${str%%*:$substr}" ] -} - -if [ -z "$XDG_DATA_HOME" ]; then - export XDG_DATA_HOME="$HOME/.local/share" -fi - -if [ -z "$XDG_CONFIG_HOME" ]; then - export XDG_CONFIG_HOME="$HOME/.config" -fi - -if [ -z "$XDG_DATA_DIRS" ]; then - XDG_DATA_DIRS="@PREDEF_XDG_DATA_DIRS@" -else - if ! contains "$XDG_DATA_DIRS" "@LXQT_DATA_DIR@"; then - XDG_DATA_DIRS="$XDG_DATA_DIRS:@LXQT_DATA_DIR@" - fi -fi -export XDG_DATA_DIRS - -if [ -z "$XDG_CONFIG_DIRS" ]; then - export XDG_CONFIG_DIRS="@LXQT_ETC_XDG_DIR@" -else - if ! contains "$XDG_CONFIG_DIRS" '@LXQT_ETC_XDG_DIR@'; then - XDG_CONFIG_DIRS="$XDG_CONFIG_DIRS:@LXQT_ETC_XDG_DIR@" - fi -fi - -if [ -z "$XDG_CACHE_HOME" ]; then - export XDG_CACHE_HOME="$HOME/.cache" -fi - -# Ensure the existance of the 'Desktop' folder -if [ -e "$XDG_CONFIG_HOME/user-dirs.dirs" ]; then - . "$XDG_CONFIG_HOME/user-dirs.dirs" -else - XDG_DESKTOP_DIR="$HOME/Desktop" -fi -mkdir -p "$XDG_DESKTOP_DIR" - -# Clean up after GDM (GDM sets the number of desktops to one) -xprop -root -remove _NET_NUMBER_OF_DESKTOPS -remove _NET_DESKTOP_NAMES -remove _NET_CURRENT_DESKTOP 2> /dev/null - -# Enable Qt integration for OpenOffice.org, if available. -if [ -z "$SAL_USE_VCLPLUGIN" ]; then - export SAL_USE_VCLPLUGIN=kde4 -fi - -# Launch DBus if needed -if [ -z "$DBUS_SESSION_BUS_ADDRESS" ]; then - if [ -z "$XDG_RUNTIME_DIR" ] || ! [ -S "$XDG_RUNTIME_DIR/bus" ] || ! [ -O "$XDG_RUNTIME_DIR/bus" ]; then - eval "$(dbus-launch --sh-syntax --exit-with-session)" || echo "startlxqt: error executing dbus-launch" >&2 - fi -fi - -# Copy default settings of openbox -if [ ! -e "$XDG_CONFIG_HOME/openbox/lxqt-rc.xml" ] ; then - ob_config_copied=0 - for considered_file in 'lxde-rc.xml' 'rc.xml'; do - if [ -e "$XDG_CONFIG_HOME/openbox/$considered_file" ]; then - #copy existing configuration of openbox - cp "$XDG_CONFIG_HOME/openbox/$considered_file" "$XDG_CONFIG_HOME/openbox/lxqt-rc.xml" - message="Your existing configuration for openbox '$XDG_CONFIG_HOME/openbox/$considered_file' was used to -fill the LXQt's openbox configuration '$XDG_CONFIG_HOME/openbox/lxqt-rc.xml'. -If you want to use the predefined LXQt's openbox configuration, run: - cp '@LXQT_ETC_XDG_DIR@/openbox/lxqt-rc.xml' '$XDG_CONFIG_HOME/openbox'" - echo "$message" >&2 - xmessage -center -title "LXQt Openbox configuration" "$message" & - ob_config_copied=1 - break - fi - done - if [ 0 -eq "$ob_config_copied" ]; then - #copy predefined configuration - mkdir -p "$XDG_CONFIG_HOME/openbox" - #user/distribution can change the default configuration via LXQT_DEFAULT_OPENBOX_CONFIG - [ -r "$LXQT_DEFAULT_OPENBOX_CONFIG" ] || LXQT_DEFAULT_OPENBOX_CONFIG='@LXQT_ETC_XDG_DIR@/openbox/lxqt-rc.xml' - cp "$LXQT_DEFAULT_OPENBOX_CONFIG" "$XDG_CONFIG_HOME/openbox" - fi -fi - -# Qt4 platform plugin -export QT_PLATFORM_PLUGIN=lxqt - -# Qt5 platform plugin -export QT_QPA_PLATFORMTHEME=lxqt - -# use lxqt-applications.menu for main app menu -export XDG_MENU_PREFIX="lxqt-" - -export XDG_CURRENT_DESKTOP="LXQt" - -# Start the LXQt session -exec lxqt-session diff --git a/xsession/CMakeLists.txt b/xsession/CMakeLists.txt deleted file mode 100644 index 00b94ab..0000000 --- a/xsession/CMakeLists.txt +++ /dev/null @@ -1,29 +0,0 @@ -# TODO/FIXME: install kdm/gdm files too -# this file should be enough but it needs testing... -file(GLOB SESSION_FILES_IN *.desktop.in) - -# Translations ********************************** -lxqt_translate_desktop(SESSION_FILES - SOURCES - ${SESSION_FILES_IN} -) -add_custom_target(xsession_desktop_files ALL DEPENDS ${SESSION_FILES}) -#************************************************ - -MACRO(INSTALL_SESSION_FILES directory) -# if(EXISTS ${directory}) - install(FILES - ${SESSION_FILES} - DESTINATION "${directory}" - COMPONENT Runtime - ) -# endif() -ENDMACRO(INSTALL_SESSION_FILES) - -#INSTALL_SESSION_FILES("/etc/X11/sessions") -#INSTALL_SESSION_FILES("/usr/share/sessions") -INSTALL_SESSION_FILES("${CMAKE_INSTALL_DATAROOTDIR}/xsessions") -INSTALL_SESSION_FILES("${CMAKE_INSTALL_DATAROOTDIR}/kdm/sessions") -#INSTALL_SESSION_FILES("/usr/local/share/apps/kdm/sessions") -#INSTALL_SESSION_FILES("/usr/share/config/kdm/sessions") -#INSTALL_SESSION_FILES("/usr/local/share/config/kdm/sessions") diff --git a/xsession/lxqt.desktop.in b/xsession/lxqt.desktop.in deleted file mode 100644 index 42fa78f..0000000 --- a/xsession/lxqt.desktop.in +++ /dev/null @@ -1,8 +0,0 @@ -[Desktop Entry] -Type=Application -Exec=startlxqt -TryExec=lxqt-session -Name=LXQt Desktop -Comment=Lightweight Qt Desktop - -#TRANSLATIONS_DIR=translations diff --git a/xsession/translations/lxqt_ar.desktop b/xsession/translations/lxqt_ar.desktop deleted file mode 100644 index 59dd8c3..0000000 --- a/xsession/translations/lxqt_ar.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[ar]=سطح المكتب ريزر -Comment[ar]=سطح المكتب كيوت٤ diff --git a/xsession/translations/lxqt_cs.desktop b/xsession/translations/lxqt_cs.desktop deleted file mode 100644 index 01c0039..0000000 --- a/xsession/translations/lxqt_cs.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[cs]=Plocha LXQt -Comment[cs]=Pracovní plocha na Qt diff --git a/xsession/translations/lxqt_cs_CZ.desktop b/xsession/translations/lxqt_cs_CZ.desktop deleted file mode 100644 index e22341a..0000000 --- a/xsession/translations/lxqt_cs_CZ.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[cs_CZ]=Pracovní plocha LXQt -Comment[cs_CZ]=Pracovní plocha Qt diff --git a/xsession/translations/lxqt_da.desktop b/xsession/translations/lxqt_da.desktop deleted file mode 100644 index 7786f96..0000000 --- a/xsession/translations/lxqt_da.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[da]=LXQt-skrivebord -Comment[da]=Letvægts Qt-skrivebord diff --git a/xsession/translations/lxqt_de.desktop b/xsession/translations/lxqt_de.desktop deleted file mode 100644 index 1805817..0000000 --- a/xsession/translations/lxqt_de.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[de]=LXQt Arbeitsumgebung -Comment[de]=Leichtgewichtige Qt Arbeitsumgebung diff --git a/xsession/translations/lxqt_el.desktop b/xsession/translations/lxqt_el.desktop deleted file mode 100644 index d5d0205..0000000 --- a/xsession/translations/lxqt_el.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[el]=Επιφάνεια εργασίας LXQt -Comment[el]=Ελαφριά επιφάνεια εργασίας Qt diff --git a/xsession/translations/lxqt_eo.desktop b/xsession/translations/lxqt_eo.desktop deleted file mode 100644 index c82a81d..0000000 --- a/xsession/translations/lxqt_eo.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[eo]=LXQta labortablo -Comment[eo]=Qt-labortablo diff --git a/xsession/translations/lxqt_es.desktop b/xsession/translations/lxqt_es.desktop deleted file mode 100644 index ca698b2..0000000 --- a/xsession/translations/lxqt_es.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[es]=Escritorio LXQt -Comment[es]=Escritorio Qt diff --git a/xsession/translations/lxqt_es_VE.desktop b/xsession/translations/lxqt_es_VE.desktop deleted file mode 100644 index 428daa9..0000000 --- a/xsession/translations/lxqt_es_VE.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[es_VE]=Escritorio LXQt -Comment[es_VE]=Escritorio Qt diff --git a/xsession/translations/lxqt_eu.desktop b/xsession/translations/lxqt_eu.desktop deleted file mode 100644 index 2da53be..0000000 --- a/xsession/translations/lxqt_eu.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[eu]=LXQt mahaigaina -Comment[eu]=Qt mahaigaina diff --git a/xsession/translations/lxqt_fi.desktop b/xsession/translations/lxqt_fi.desktop deleted file mode 100644 index 29bc2c4..0000000 --- a/xsession/translations/lxqt_fi.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[fi]=LXQt-työpöytä -Comment[fi]=Qt-työpöytä diff --git a/xsession/translations/lxqt_fr.desktop b/xsession/translations/lxqt_fr.desktop deleted file mode 100644 index 2d8006a..0000000 --- a/xsession/translations/lxqt_fr.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[fr]=Bureau LXQt -Comment[fr]=Bureau léger pour Qt diff --git a/xsession/translations/lxqt_hu.desktop b/xsession/translations/lxqt_hu.desktop deleted file mode 100644 index 91da4e9..0000000 --- a/xsession/translations/lxqt_hu.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[hu]=LXQt asztal -Comment[hu]=Qt asztali környezet diff --git a/xsession/translations/lxqt_ia.desktop b/xsession/translations/lxqt_ia.desktop deleted file mode 100644 index 26b0d99..0000000 --- a/xsession/translations/lxqt_ia.desktop +++ /dev/null @@ -1 +0,0 @@ -# Translations diff --git a/xsession/translations/lxqt_id_ID.desktop b/xsession/translations/lxqt_id_ID.desktop deleted file mode 100644 index 26b0d99..0000000 --- a/xsession/translations/lxqt_id_ID.desktop +++ /dev/null @@ -1 +0,0 @@ -# Translations diff --git a/xsession/translations/lxqt_it_IT.desktop b/xsession/translations/lxqt_it_IT.desktop deleted file mode 100644 index e9157c1..0000000 --- a/xsession/translations/lxqt_it_IT.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[it_IT]=Desktop LXQt -Comment[it_IT]=Desktop Qt diff --git a/xsession/translations/lxqt_ja.desktop b/xsession/translations/lxqt_ja.desktop deleted file mode 100644 index 0e4e77b..0000000 --- a/xsession/translations/lxqt_ja.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[ja]=LXQt デスクトップ -Comment[ja]=Qt デスクトップ diff --git a/xsession/translations/lxqt_ko.desktop b/xsession/translations/lxqt_ko.desktop deleted file mode 100644 index 26b0d99..0000000 --- a/xsession/translations/lxqt_ko.desktop +++ /dev/null @@ -1 +0,0 @@ -# Translations diff --git a/xsession/translations/lxqt_lt.desktop b/xsession/translations/lxqt_lt.desktop deleted file mode 100644 index 22bd113..0000000 --- a/xsession/translations/lxqt_lt.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[lt]=LXQt darbalaukis -Comment[lt]=Supaprastintas Qt darbalaukis diff --git a/xsession/translations/lxqt_nl.desktop b/xsession/translations/lxqt_nl.desktop deleted file mode 100644 index f02be27..0000000 --- a/xsession/translations/lxqt_nl.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[nl]=LXQt Bureaublad -Comment[nl]=Qt Bureaublad diff --git a/xsession/translations/lxqt_pl.desktop b/xsession/translations/lxqt_pl.desktop deleted file mode 100644 index 9f49161..0000000 --- a/xsession/translations/lxqt_pl.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[pl]=Pulpit LXQt -Comment[pl]=Pulpit Qt diff --git a/xsession/translations/lxqt_pl_PL.desktop b/xsession/translations/lxqt_pl_PL.desktop deleted file mode 100644 index 746f5fb..0000000 --- a/xsession/translations/lxqt_pl_PL.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[pl_PL]=Pulpit LXQt -Comment[pl_PL]=Środowisko graficzne Qt diff --git a/xsession/translations/lxqt_pt.desktop b/xsession/translations/lxqt_pt.desktop deleted file mode 100644 index 3a601b5..0000000 --- a/xsession/translations/lxqt_pt.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[pt]=Ambiente de trabalho LXQt -Comment[pt]=Ambiente de trabalho em Qt diff --git a/xsession/translations/lxqt_pt_BR.desktop b/xsession/translations/lxqt_pt_BR.desktop deleted file mode 100644 index 1b9ef6a..0000000 --- a/xsession/translations/lxqt_pt_BR.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[pt_BR]=Área de trabalho LXQt -Comment[pt_BR]=Área de trabalho Qt diff --git a/xsession/translations/lxqt_ro_RO.desktop b/xsession/translations/lxqt_ro_RO.desktop deleted file mode 100644 index d427c49..0000000 --- a/xsession/translations/lxqt_ro_RO.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[ro_RO]=Desktop LXQt -Comment[ro_RO]=Desktop Qt diff --git a/xsession/translations/lxqt_ru.desktop b/xsession/translations/lxqt_ru.desktop deleted file mode 100644 index 89612a1..0000000 --- a/xsession/translations/lxqt_ru.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[ru]=Рабочий стол LXQt -Comment[ru]=Рабочий стол на Qt diff --git a/xsession/translations/lxqt_ru_RU.desktop b/xsession/translations/lxqt_ru_RU.desktop deleted file mode 100644 index bbe6fa2..0000000 --- a/xsession/translations/lxqt_ru_RU.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[ru_RU]=Рабочий стол LXQt -Comment[ru_RU]=Среда рабочего стола, использующая Qt diff --git a/xsession/translations/lxqt_sk.desktop b/xsession/translations/lxqt_sk.desktop deleted file mode 100644 index 7997dd5..0000000 --- a/xsession/translations/lxqt_sk.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[sk]=Prostredie LXQt -Comment[sk]=Pracovné prostredie v Qt diff --git a/xsession/translations/lxqt_sl.desktop b/xsession/translations/lxqt_sl.desktop deleted file mode 100644 index 5390fd9..0000000 --- a/xsession/translations/lxqt_sl.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[sl]=Namizje LXQt -Comment[sl]=Namizje, ustvarjeno s Qt diff --git a/xsession/translations/lxqt_sr.desktop b/xsession/translations/lxqt_sr.desktop deleted file mode 100644 index 1edb09b..0000000 --- a/xsession/translations/lxqt_sr.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[sr]=Рејзорова радна површ -Comment[sr]=Кјут4 радна површ diff --git a/xsession/translations/lxqt_sr@latin.desktop b/xsession/translations/lxqt_sr@latin.desktop deleted file mode 100644 index e8437df..0000000 --- a/xsession/translations/lxqt_sr@latin.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[sr@latin]=Rejzorova radna površ -Comment[sr@latin]=Qt radna površ diff --git a/xsession/translations/lxqt_th_TH.desktop b/xsession/translations/lxqt_th_TH.desktop deleted file mode 100644 index b10e310..0000000 --- a/xsession/translations/lxqt_th_TH.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[th_TH]=เดสก์ท็อป LXQt -Comment[th_TH]=เดสก์ท็อป Qt diff --git a/xsession/translations/lxqt_tr.desktop b/xsession/translations/lxqt_tr.desktop deleted file mode 100644 index 7fdd7e0..0000000 --- a/xsession/translations/lxqt_tr.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[tr]=LXQt Masaüstü -Comment[tr]=Qt Masaüstü diff --git a/xsession/translations/lxqt_uk.desktop b/xsession/translations/lxqt_uk.desktop deleted file mode 100644 index de7f29b..0000000 --- a/xsession/translations/lxqt_uk.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[uk]=Стільниця LXQt -Comment[uk]=Стільниця Qt diff --git a/xsession/translations/lxqt_zh_CN.GB2312.desktop b/xsession/translations/lxqt_zh_CN.GB2312.desktop deleted file mode 100644 index 26b0d99..0000000 --- a/xsession/translations/lxqt_zh_CN.GB2312.desktop +++ /dev/null @@ -1 +0,0 @@ -# Translations diff --git a/xsession/translations/lxqt_zh_CN.desktop b/xsession/translations/lxqt_zh_CN.desktop deleted file mode 100644 index c6b47fe..0000000 --- a/xsession/translations/lxqt_zh_CN.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[zh_CN]=LXQt 桌面 -Comment[zh_CN]=Qt 桌面 diff --git a/xsession/translations/lxqt_zh_TW.desktop b/xsession/translations/lxqt_zh_TW.desktop deleted file mode 100644 index 758283c..0000000 --- a/xsession/translations/lxqt_zh_TW.desktop +++ /dev/null @@ -1,3 +0,0 @@ -# Translations -Name[zh_TW]=LXQt桌面 -Comment[zh_TW]=輕量級Qt桌面環境