summaryrefslogtreecommitdiffstats
path: root/src/corelib/io/qstandardpaths_win.cpp
Commit message (Collapse)AuthorAgeFilesLines
* QtCore: Remove Windows CE.Friedemann Kleint2016-03-301-39/+3
| | | | | | | | | Remove QSysInfo::WV_CE_5/6 enumeration values, #ifdef sections for Q_OS_WINCE and wince .pro file clauses in library, examples and tests. Task-number: QTBUG-51673 Change-Id: Ib63463445f3a26e04d018b193e4655030002f5f9 Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
* Merge remote-tracking branch 'origin/5.6' into 5.7Liang Qi2016-03-211-0/+22
|\ | | | | | | | | | | | | | | | | Conflicts: src/widgets/styles/qgtkstyle_p.cpp tests/auto/corelib/io/qtextstream/test/test.pro tests/auto/corelib/plugin/plugin.pro Change-Id: I512bc1b36acf3933ed2b96c00f476ee3819c1f4b
| * Introduce separate mapping of QStandardPaths's CLSIDs for Windows CE.Friedemann Kleint2016-03-171-0/+22
| | | | | | | | | | | | | | | | | | | | CSIDL_APPDATA should be used instead of CSIDL_LOCAL_APPDATA on Windows CE. Amends 910f719bd111813f37278b67d07f9d12cb03a4ff . Task-number: QTBUG-50570 Change-Id: I0cc310ef5fe3fbaefae9c84dd9db8cf48ff48499 Reviewed-by: Tobias Koenig <tobias.koenig@kdab.com> Reviewed-by: Andreas Holzammer <andreas.holzammer@kdab.com>
* | Merge remote-tracking branch 'origin/5.6' into devLiang Qi2016-02-021-115/+143
|\| | | | | | | | | | | | | | | | | Conflicts: config.tests/unix/compile.test src/plugins/platforms/cocoa/qcocoahelpers.mm src/tools/qlalr/cppgenerator.cpp Change-Id: I0103ca076a9aca7118b2fd99f0fdaf81055998c3
| * Refactor QStandardPaths for Desktop Windows.Friedemann Kleint2016-01-281-115/+143
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Replace the large switch in QStandardPaths::writableLocation() by a function mapping QStandardPaths::StandardLocation to the int clsid required by SHGetSpecialFolderPath(). Warn if SHGetSpecialFolderPath() fails for config location and append prefixes (cache/application name/organization) only on success. Change the logic in QStandardPaths::standardLocations() to append the writable location first, avoiding the prepend(). Task-number: QTBUG-50570 Change-Id: I9d80e83d1ca7af3ea8d3ac2c720ee981b1b2c32a Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
* | Updated license headersJani Heikkinen2016-01-151-14/+20
|/ | | | | | | | | | | From Qt 5.7 -> LGPL v2.1 isn't an option anymore, see http://blog.qt.io/blog/2016/01/13/new-agreement-with-the-kde-free-qt-foundation/ Updated license headers to use new LGPL header instead of LGPL21 one (in those files which will be under LGPL v3) Change-Id: I046ec3e47b1876cd7b4b0353a576b352e3a946d9 Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
* Merge remote-tracking branch 'origin/5.5' into 5.6Liang Qi2015-10-021-1/+1
|\ | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: qmake/doc/src/qmake-manual.qdoc src/corelib/tools/qstring.h src/gui/image/qimagereader.cpp src/network/access/qnetworkaccessmanager.cpp src/tools/qdoc/doc/examples/examples.qdoc src/widgets/accessible/qaccessiblewidgetfactory_p.h src/widgets/doc/qtwidgets.qdocconf Change-Id: I8fae62283aebefe24e5ca4b4abd97386560c0fcb
| * Fix regression with QStandardPaths::standardLocations on WindowsJoni Poikelin2015-09-171-1/+1
| | | | | | | | | | | | | | | | | | | | Commit f3bc9f5c5cee9dac8a7815c2861a9945b5341390 broke standardLocations by replacing them with same paths as writeable locations would return. Task-number: QTBUG-46279 Change-Id: I43150e3af13320a707c7882dd0f0cdcb2c6e8a70 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com> Reviewed-by: David Faure <david.faure@kdab.com>
* | QStandardPaths: on Windows, add APPDIR and APPDIR/data for GenericDataLocationDavid Faure2015-08-131-4/+2
|/ | | | | | | | | | This allows multiple applications installed into the same directory, to share data files without polluting a more global directory like C:/ProgramData. Change-Id: Id5f4f9bc9d2ccb7ec677babcc08c1c5a641178f6 Reviewed-by: Samuel Gaist <samuel.gaist@edeltech.ch> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Update copyright headersJani Heikkinen2015-02-111-7/+7
| | | | | | | | | | | | | | | | | | Qt copyrights are now in The Qt Company, so we could update the source code headers accordingly. In the same go we should also fix the links to point to qt.io. Outdated header.LGPL removed (use header.LGPL21 instead) Old header.LGPL3 renamed to header.LGPL3-COMM to match actual licensing combination. New header.LGPL-COMM taken in the use file which were using old header.LGPL3 (src/plugins/platforms/android/extract.cpp) Added new header.LGPL3 containing Commercial + LGPLv3 + GPLv2 license combination Change-Id: I6f49b819a8a20cc4f88b794a8f6726d975e8ffbe Reviewed-by: Matti Paaso <matti.paaso@theqtcompany.com>
* QStandardPaths: add AppConfigLocation.David Faure2015-01-091-0/+2
| | | | | | | | | | | | | | | | | | | ConfigLocation was erroneously inconsistent, by adding the org name and app name on Windows (unintentionally) and not on Unix (while having subdirs in ~/.config is actually common practice for some XDG desktops) Therefore this adds AppConfigLocation, which always has the org name and app name (while GenericConfigLocation never does). [ChangeLog][QtCore][QStandardPaths] Added QStandardPaths::AppConfigLocation, for application-specific configuration directory. ConfigLocation was inconsistent. Task-number: QTBUG-38872 Task-number: QTBUG-38845 Change-Id: I80fb98f296436261f3996c9df87571c29b06ab35 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com> Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Update license headers and add new license filesMatti Paaso2014-09-241-19/+11
| | | | | | | | | - Renamed LICENSE.LGPL to LICENSE.LGPLv21 - Added LICENSE.LGPLv3 - Removed LICENSE.GPL Change-Id: Iec3406e3eb3f133be549092015cefe33d259a3f2 Reviewed-by: Iikka Eklund <iikka.eklund@digia.com>
* Add locations AppDataLocation, AppLocalDataLocation to QStandardPaths.Friedemann Kleint2014-04-291-12/+22
| | | | | | | | | | | | | | | | | | | On Windows, DataLocation currently returns the value obtained by passing CSIDL_COMMON_APPDATA to SHGetSpecialFolderPath(). This is the local non-roaming path. For actually storing settings, the roaming path should be used (CSIDL_APPDATA). Introduce new AppDataLocation to return that path and AppLocalDataLocation for the local path and deprecate DataLocation. [ChangeLog][QtCore][QStandardPaths] QStandardPaths now has new enumeration values AppDataLocation, AppLocalDataLocation to be able to differentiate between roaming and local paths on the Windows operating system. DataLocation is deprecated in favor of AppDataLocation. Task-number: QTBUG-38483 Change-Id: Ib1de8c7031a863ed5eac10c747de6f7ff1a090c7 Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com> Reviewed-by: David Faure <david.faure@kdab.com>
* Fix build on [older] MinGWKonstantin Ritt2014-03-291-1/+1
| | | | | | | | | | | | | | | > error: 'REFKNOWNFOLDERID' does not name a type > error: 'GetKnownFolderPath' does not name a type > error: 'SHGetKnownFolderPath' was not declared in this scope REFKNOWNFOLDERID is a typedef for `const KNOWNFOLDERID &` and KNOWNFOLDERID is a typedef for `GUID`. Change-Id: I2371f49aba6e20b0bd44aad423dd822e5ee152d4 Reviewed-by: Samuel Gaist <samuel.gaist@edeltech.ch> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com> Reviewed-by: Jan Arve Sæther <jan-arve.saether@digia.com>
* Implement DownloadLocation retrieving using SHGetKnownFolderPathSamuel Gaist2014-03-251-1/+24
| | | | | | | | | | | | This patch implements the TODO concerning the retrieval of DownloadLocation using SHGetKnownFolderPath [ChangeLog][QtCore][Windows] Now QStandardPaths::DownloadLocation returns the proper path for Windows Vista and up Task-number: QTBUG-35194 Change-Id: Ifc7686e23de76dbfd7826a75e4bf99aa5b9268b0 Reviewed-by: Jan Arve Sæther <jan-arve.saether@digia.com>
* Windows/Windows CE: Do not dynamically load shell32/coredll.Friedemann Kleint2014-01-071-21/+1
| | | | | | | | | Those libraries are contained in QMAKE_LIBS_CORE and GetSpecialFolderPath() is present in all supported versions. Change-Id: Iae40714e0f234625b063aeb50e29fc79c4aaa6ea Reviewed-by: Björn Breitmeyer <bjoern.breitmeyer@kdab.com> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
* Add Asset Locations to QStandardPaths::DataLocationAlan Alpert2013-12-101-0/+6
| | | | | | | | | | | | | The locations of UI assets are deployed to is being added as a read-only location under DataLocation. As such a path is located differently on certain mobile platforms, such as Android and BlackBerry, having an entry in StandardPaths will make it easier to write cross-platform code. Change-Id: I4533c90ed7157725a8604591595b350c7f616723 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: David Faure <david.faure@kdab.com>
* QStandardPaths: add GenericConfigLocationDavid Faure2013-11-051-4/+6
| | | | | | | | | | | | | | | | This is what ConfigLocation was meant to be. A directory shared by all applications. Unfortunately when I wrote the fallback on Windows, I picked DataLocation (which is app-specific) instead of GenericDataLocation (which is shared between apps). This makes it impossible to have config files shared between apps, e.g. for libraries. It also makes ConfigLocation quite inconsistent (on Windows one cannot use it to load another app's config file, while it works everywhere else). All this is fixed by GenericConfigLocation, which is shared between apps. Change-Id: I23a755131061d4fea01e13dd1038fbd8ef333a5d Reviewed-by: Alex Richardson <arichardson.kde@googlemail.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QStandardPaths: Use forward slash consistently.Friedemann Kleint2013-02-271-2/+2
| | | | | | | | Task-number: QTBUG-29249 Change-Id: I027f9ae18544dc47e1378214244487c8a5ae704c Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Update copyright year in Digia's license headersSergio Ahumada2013-01-181-1/+1
| | | | | Change-Id: Ic804938fc352291d011800d21e549c10acac66fb Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* Allow QStandardPaths (Mac, Windows, Unix) to be bootstrappedThiago Macieira2012-11-021-0/+7
| | | | | | | | | | | | | This allows using QStandardPaths in one of the bootstrapped tools, if required for a future need. The Blackberry version appears to be usable in bootstrapped mode already. Change-Id: Ia4e9b9564395d2e151f8ac229ac2a2aa2982e92f Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com> Reviewed-by: David Faure (KDE) <faure@kde.org> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
* Change copyrights from Nokia to DigiaIikka Eklund2012-09-221-24/+24
| | | | | | | | Change copyrights and license headers from Nokia to Digia Change-Id: If1cc974286d29fd01ec6c19dd4719a67f4c3f00e Reviewed-by: Lars Knoll <lars.knoll@digia.com> Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com>
* Revert "Use true and false in preference to TRUE and FALSE"Sergio Ahumada2012-09-071-10/+10
| | | | | | | | | | | Even though I really think the change was the right thing to do, it seems like Windows people don't like this change because of some Windows Data Types specific rules. This reverts parts of the commit 56d5c909af6473be64a1ae487b45bd444a9a8553. Change-Id: I2c67d9b1bab36fc63937ef386aef56d2a4472a04 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* Use true and false in preference to TRUE and FALSESergio Ahumada2012-09-051-10/+10
| | | | | | | | The TRUE and FALSE macros are obsolete and should be replaced with true and false (all lower case) respectively. Change-Id: Iee352e8173500683e6319be0abbf5bacf29016e0 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Remove code duplication in QStandardPaths implementationsDavid Faure2012-08-091-13/+1
| | | | | | | | Using the new getter to access the "test mode" setting. Change-Id: Id26a350cd3fab4bf2e5f58ba67bc7323f99c9cc3 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
* Add bool QStandardPaths::isTestModeEnabled()David Faure2012-08-091-0/+5
| | | | | | | | | Library code might need to know this, e.g. when calling an external process, to give it the right configuration. (For instance when ksycoca code calls kbuildsycoca to recreate the DB at the right place). Change-Id: I343ddefff816586f9d391973c08ff1e1ad86bf0e Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Use QtCore instead of QtGui for the standardpaths comments to be correctLaszlo Papp2012-08-011-1/+1
| | | | | | | Change-Id: I98004fed565ac9653947ec70a3197b0372abcf2b Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com> Reviewed-by: David Faure <faure@kde.org>
* Allow auto tests to stay away from the user's configuration.David Faure2012-03-281-0/+9
| | | | | | | | | | | | | | | QStandardPaths now knows a "test mode" which changes writable locations to point to test directories, in order to prevent auto tests from reading from or writing to the current user's configuration. This affects the locations into which test programs might write files: GenericDataLocation, DataLocation, ConfigLocation, GenericCacheLocation, CacheLocation. Other locations are not affected. Change-Id: I29606c2e74714360edd871a8c387a5c1ef7d1f54 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Jason McDonald <jason.mcdonald@nokia.com>
* QStandardPaths: implement displayName() on all platforms.David Faure2012-03-221-6/+0
| | | | | | | | It was only implemented on Mac OSX until now (all this came from the QDesktopServices code). Change-Id: I7fd81d80ca77cf0ca6c213f59813a6163abe7dc5 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Don't include qguifunctions_wince.h in QtCore.Andreas Holzammer2012-02-081-1/+0
| | | | | | | | | | qguifunctions_wince.h does not live anymore in QtCore, but instead in QtGui, so do not include them in QtCore. Change-Id: I22222ae7045ee0140924197ac583a3bf2e0f3d36 Reviewed-by: Miikka Heikkinen <miikka.heikkinen@digia.com> Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
* Use Q_OS_WINCE instead of Q_WS_WINCEAndreas Holzammer2012-02-071-1/+1
| | | | | | | | | Window system defines have been deprecated, so use Q_OS_WINCE instead. Change-Id: I52059d0f854fe783ac20610ab248800c3e1e827c Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* Remove "All rights reserved" line from license headers.Jason McDonald2012-01-301-1/+1
| | | | | | | | | | As in the past, to avoid rewriting various autotests that contain line-number information, an extra blank line has been inserted at the end of the license text to ensure that this commit does not change the total number of lines in the license header. Change-Id: I311e001373776812699d6efc045b5f742890c689 Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* QStandardPaths: remove unused includes (leftovers from qdesktopservices)David Faure2012-01-261-4/+0
| | | | | Change-Id: I6fe23ecd04adc7dd68573dd0d6d01888c0cf71b6 Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
* Update contact information in license headers.Jason McDonald2012-01-231-1/+1
| | | | | | | Replace Nokia contact email address with Qt Project website. Change-Id: I431bbbf76d7c27d8b502f87947675c116994c415 Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Update copyright year in license headers.Jason McDonald2012-01-051-1/+1
| | | | | Change-Id: I02f2c620296fcd91d4967d58767ea33fc4e1e7dc Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* QStandardPaths: add GenericCacheLocation.David Faure2012-01-031-0/+3
| | | | | | | | | | | Much like DataLocation = GenericDataLocation + domain + appname, this makes CacheLocation = GenericCacheLocation + domain + appname. This way a framework library can have an application-independent cache (like ksycoca). Change-Id: I6a8c47ff85b7d5c68b594cc8b071a752d96b029d Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QStandardPaths: add DownloadLocation.David Faure2011-11-041-0/+1
| | | | | | | | | Only properly implemented on unix (XDG), falls back to Document location on Mac and Windows, because not easily available with the current API being used by either one. Change-Id: Id269f0e3c4e3a68e19205de96c0b39980fde80ff Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Rename storageLocation() to writableLocation().David Faure2011-10-231-3/+3
| | | | | Change-Id: I8f6522a70950f78ddd6141360d36d104bd697e28 Reviewed-by: Thiago Macieira (Intel) <thiago.macieira@intel.com>
* Add QStandardPaths::RuntimeLocation, for sockets ($XDG_RUNTIME_DIR)David Faure2011-10-231-5/+3
| | | | | Change-Id: I19c36a04a9deae49ffc20fdec6a2a7eb05155cb4 Reviewed-by: Thiago Macieira (Intel) <thiago.macieira@intel.com>
* QStandardPaths: add Config and GenericData, add methodsDavid Faure2011-10-231-18/+71
| | | | | | | New methods: standardLocations, locate, locateAll. Change-Id: I60bc90f8df53727a72c4b1839ea4d1d88a204e29 Reviewed-by: Thiago Macieira (Intel) <thiago.macieira@intel.com>
* Move path information from QDesktopServices (gui) to QStandardPaths (core)David Faure2011-10-231-0/+167
Change-Id: Ic596c21894d83b4dab0c3f5b1aed916ddd590f2f Reviewed-by: Thiago Macieira (Intel) <thiago.macieira@intel.com>