aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/cmakeprojectmanager/cmakebuildsettingswidget.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Fix filtering in various hierarchical viewsEike Ziller2020-06-221-3/+8
| | | | | | | | | | | | | | The intermediate "category" nodes where never filtered out. CategorySortFilterModel was changed to use filterRegularExpression() and setFilterFixedString does not set that (it only affects filterRegExp() which we need to get rid off). Set a regular expression directly instead of a fixed string. Amends 47e576528e4f61c1e387e7ee89bc6b18b7ce3d94 Change-Id: I6f844027b83d66ca2d5088d83e6e84b01b9eda45 Reviewed-by: hjk <hjk@qt.io>
* CMake: Remove magic configuration from CMakeTobias Hunger2020-06-091-42/+71
| | | | | | | | | | | | | | | | | | | | | | Get rid of magic configuration handling in the CMakeProjectManager. * Use CMakeCache.txt as the sole source of truth, do not keep a shadow copy of configuration in the .user file * Have initial CMake arguments that are easy to edit in batch (Fixes: QTCREATORBUG-18179) used whenever no CMakeCache.txt file is in the build directory. These allow for any thing that can be passed to CMake on the command line. (Fixes: QTCREATORBUG-16296) * Ask when changes to CMake configuration were not applied (Fixes: QTCREATORBUG-18504) * Run cmake with arguments effecting its configuration only when the CMake settings are changed in the UI, run CMake without any special arguments in all other cases. * Get rid of the confusing dialog used to keep settings in sync between what is in CMakeCache.txt and Creator (Fixes: QTCREATORBUG-23218) Change-Id: I26d55be7df733f084f5691ecf7d7b4352f58b8e7 Reviewed-by: Cristian Adam <cristian.adam@qt.io>
* CMake: Fix includes all over the CMake pluginTobias Hunger2020-04-201-14/+4
| | | | | | | | | | | | | | Keep internals internal, remove some unnecessary includes, add some that should have been there. This reduces the number of files that get rebuild when working on CMake internals from over 1000 to about 200. This patch also moves some code around that ended up being in the wrong file. Change-Id: Icd7366ac760dc85031040720418fbb16336dce9b Reviewed-by: Eike Ziller <eike.ziller@qt.io>
* CMake: Use BuildDirectoryAspect for UI related to Build DirectoryTobias Hunger2020-03-231-24/+12
| | | | | | | Do not re-create the UI yourself. Change-Id: I8e7610ee6717105a3e05743d0451a3c6732197c5 Reviewed-by: hjk <hjk@qt.io>
* CMake: Fix typo in symbol namesTobias Hunger2020-03-191-3/+3
| | | | | | | | | I can't spell occurred:-/ Similar typos in 3rd party code (sqlite) has been left in place. Change-Id: I7cfa9911fc434d42ce3df8e9c7ccb83dc00401e8 Reviewed-by: hjk <hjk@qt.io>
* CMake: Connect CMakeBuildSettingsWidget only to "its" build systemhjk2020-02-121-1/+1
| | | | | Change-Id: I1259b3325d633cb89043ce65f8e33b7914f6f06e Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* CMakePM: Fix possible crash on exitChristian Stenger2020-02-071-3/+2
| | | | | | | | | | | | The pathchooser might get deleted after the inner line edit had been destroyed already (as its ownership was transferred to the layout of the CMake build settings widget. Partially reverts 314ceb13bc2a6d. Change-Id: I3ff990af55ed08978d9f0c079c4b98a019a6ec87 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* CMakePM: Fix handling of qml debuggingChristian Stenger2020-02-071-0/+50
| | | | | | | | | | | | | | Add a respective aspect to the build configuration for handling qml debugging from the build side similar to what we do with qmake and qbs. Qml debugging needs to get enabled on the build side before the settings on the run configuration page has an effect. Fixes: QTCREATORBUG-23541 Change-Id: I86267747601015760737d8b21978712896892a37 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* CMakeProjectManager: Fix memory leaksChristian Kandeler2020-01-271-4/+4
| | | | | Change-Id: Ie1d046a4d736b02db9465062784730ebbab6a2ed Reviewed-by: hjk <hjk@qt.io>
* CMakeProjectManager: Use Utils::InfoLabel in CMakeBuildSettingsWidgetAlessandro Portale2020-01-031-23/+5
| | | | | | Task-number: QTCREATORBUG-23346 Change-Id: I6f8928ad1ed8ac15d354c7105d95be941833ae0d Reviewed-by: Cristian Adam <cristian.adam@qt.io>
* Utils: Use FilePath for PathChooser::m_baseDirectoryhjk2019-12-191-1/+1
| | | | | | | ... and collapse the two accessor versions to one. Change-Id: I282753a0092601cff073684053ff914016452645 Reviewed-by: Eike Ziller <eike.ziller@qt.io>
* ProjectExplorer: Move BuildSystem owership to BuildConfigurationhjk2019-11-191-6/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | ... or Target. This patch moves build system from conceptually "one per project" to "one per target (i.e. per project-and-kit)" or "per BuildConfigurations" for targets where the builds differ significantly. Building requires usually items from the kit (Qt version, compiler, ...) so a target-agnostic build is practically almost always wrong. Moving the build system to the target also has the potential to solve issues caused by switching targets while parsing, that used Project::activeTarget() regularly, with potentially different results before and after the switch. This patch might create performance/size regressions when several targets are set up per project as the build system implementation's internal data are duplicated in this case. The idea is to fix that by sharing per-project pieces again in the project implementation once these problems occur. Change-Id: I87f640ce418b93175b5029124eaa55f3b8721dca Reviewed-by: Christian Stenger <christian.stenger@qt.io> Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* ProjectExlorer: Streamline creation of NamedWidgetshjk2019-11-011-2/+1
| | | | | Change-Id: I67c1506ea4e2d7722c9ce38738e350418d725a0e Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* CMake Project: Make sure the tree has focus after adding an itemCristian Adam2019-10-091-0/+1
| | | | | | | | Adding items and losing them in the tree was a bad usability feature. On Windows that was the behavior. Change-Id: Ic0f9b41fce79844aaf8803713cb0220c4618c127 Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* Remove usages of deprecated APIs of QLayoutSona Kurazyan2019-09-021-2/+2
| | | | | | | | | | Replaced: QLayout::setMargin() -> QLayout::setContentsMargins() QLayout::margin() -> QLayout::getContentsMargins() Task-number: QTBUG-76491 Change-Id: If28ef6910b3afe5d04e4746b74f9362a3e3b3c8e Reviewed-by: Eike Ziller <eike.ziller@qt.io>
* ProjectExplorer: Handle parsingStarted/Finished in BuildConfigurationTobias Hunger2019-08-211-2/+2
| | | | | | | | | Make all buildconfigurations disabled while the project parses. This unifies how this is handled in different build systems. Change-Id: I6afca3743ad1433529a4f9d3bfdf73042799e456 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* Avoid warning on empty expressionshjk2019-07-231-1/+1
| | | | | | | | For some reason, Q_UNUSED includes already a semicolon, adding one on the user side creates an additional empty statement. Change-Id: I9c5e8fac381345a60792cb75e2938fd53958d3b0 Reviewed-by: Christian Stenger <christian.stenger@qt.io>
* Utils: Rename FileName to FilePathhjk2019-05-281-1/+1
| | | | | | | | More in line with QFileInfo terminonlogy which appears to be best-of-breed within Qt. Change-Id: I1d051ff1c8363ebd4ee56376451df45216c4c9ab Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* Merge remote-tracking branch 'origin/4.9'Eike Ziller2019-05-281-5/+0
|\ | | | | | | | | | | | | | | | | | | Conflicts: src/plugins/cmakeprojectmanager/cmakebuildsettingswidget.cpp src/plugins/qmldesigner/qmldesignerextension/timelineeditor/preseteditor.cpp src/plugins/qmldesigner/qmldesignerextension/timelineeditor/timelinesettingsmodel.cpp src/shared/qbs Change-Id: I369368de9b9c682b03e224d489589043e1f6782b
| * CMake: don't disable widgets on configuration errorAaron Barany2019-05-241-6/+0
| | | | | | | | | | | | | | | | If the configuration failure was caused by an incorrect option, you want to be able to fully use the UI to fix the issue. Change-Id: I3048b1f6e0b4d88e90433df9a36ca18fa72c03c6 Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* | cmake: do not change filter line edit state in case cmake parsing failsAsit Dhal2019-04-291-1/+0
| | | | | | | | | | | | | | Fixes: QTCREATORBUG-20289 Change-Id: I920c6fe977dd645f4685d2b0ea398ce91e63ab91 Reviewed-by: Orgad Shaneh <orgads@gmail.com> Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* | ProjectExplorer: Rename KitInformation to KitAspectChristian Kandeler2019-02-111-1/+1
|/ | | | | | | | | | | The name "KitInformation" does not properly convey the fact that it represents a certain *aspect* of a kit. The same goes for "KitConfigWidget", which in addition was inconsistent with "KitInformation". We now use "KitAspect" and "KitAspectWidget". Change-Id: I9804ee4cedc4d61fad533ea1dd4e4720e67fde97 Reviewed-by: hjk <hjk@qt.io>
* CMake: Fix scrolling when editing configurationAaron Barany2019-01-251-3/+13
| | | | | | | | | | | | | Find the index for the new item from the model rather than attempting to find the item by the row count, which would often return the incorrect index. It also scrolls to the item so it's in view once it starts editing. Listen for layout change to scroll to the selected index. This ensures that when you name an item after adding it, it will scroll to the new location to edit the value afterward. Change-Id: Iaa338148a40b921398cfe95da977371a91965a58 Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* CMakeProjectManager: ModernizeAlessandro Portale2018-11-251-3/+3
| | | | | | | | | | modernize-use-auto modernize-use-nullptr modernize-use-override modernize-use-using Change-Id: I6a272bc3b75835840b3d6cbe83be6f50f94bbedb Reviewed-by: Orgad Shaneh <orgads@gmail.com>
* Utils: Purge asConstOrgad Shaneh2018-04-091-1/+0
| | | | | | | | Replace by qAsConst. Change-Id: I3301366f73c066c86f08df7188d70dc3b613c55c Reviewed-by: Christian Stenger <christian.stenger@qt.io> Reviewed-by: hjk <hjk@qt.io>
* CMake: Block project configuration widget while project is parsingTobias Hunger2017-11-141-0/+2
| | | | | | | | | | This prevents the user from changing settings while the project is parsing. Those changes would get lost. Task-number: QTCREATORBUG-18988 Change-Id: Ie04c6750c8aea3fe5543168ae4838f42fe488ca2 Reviewed-by: Eike Ziller <eike.ziller@qt.io> Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
* CMake: Fix header size in CMake configuration viewTobias Hunger2017-10-241-1/+1
| | | | | | | | | Stretch the first column, not the second:-/ Task-number: QTCREATORBUG-19128 Change-Id: I0d2e945b14b83d5449af50016fb2ef6ad19da871 Reviewed-by: hjk <hjk@qt.io> Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
* CMake: Fix "CMake settings have changed on disk"Tobias Hunger2017-10-241-3/+20
| | | | | | | | | * Improve the UI by showing settings in CMake and the project * Fix setting CMake configuration to project Change-Id: I6e127344551fa00f3f7e6170465cb3dda2e4a634 Task-number: QTCREATORBUG-17555 Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
* CMakeBuildSettingsWidget: Fix filtering in cmake configurationTobias Hunger2017-10-171-2/+3
| | | | | | | | This got broken with the introduction of the grouping. Task-number: QTCREATORBUG-15814 Change-Id: Ic9908d01a1ecb636db0c8f4b7f1db926ccaedd4e Reviewed-by: Eike Ziller <eike.ziller@qt.io>
* CMakeBuildSettingsWidget: Forward-declare ProgressIndicatorTobias Hunger2017-10-171-1/+2
| | | | | Change-Id: I3808e973671849c6014780ee99896cb2d139dc18 Reviewed-by: Eike Ziller <eike.ziller@qt.io>
* CMake: Allow to unset configuration valuesTobias Hunger2017-10-171-18/+30
| | | | | Change-Id: I649323e3c2cc51ea69dd7e216f30eeb653f3873b Reviewed-by: hjk <hjk@qt.io>
* CMake: Fix project parsing notificationTobias Hunger2017-10-061-4/+4
| | | | | | | | | This builds on top of 08677c0b014cc44d944e32d462f502a67c948404 and fixes one more code path to go through a common entry/exit point. Change-Id: I1d00fa9242f247028e5d3b0ef3b5fe1d3f4cb03d Reviewed-by: hjk <hjk@qt.io> Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
* CMakePM: Fix compile with Qt5.6Christian Stenger2017-09-201-1/+1
| | | | | | | Broke with be376ae7. Change-Id: I9c99a7be78c7ec0359cefee84e2e1877d20f25bf Reviewed-by: André Hartmann <aha_1980@gmx.de>
* CMake: Enable type forcing for CMake configuation valuesTobias Hunger2017-09-191-4/+36
| | | | | | | | Allow to force the type for CMake configuration values, now that this type changes how you can edit the values. Change-Id: Id89e0ec8547b778fc0aff9a2e00c0d7406cbcac1 Reviewed-by: hjk <hjk@qt.io>
* CMake: Improve delegates for CMake configurationTobias Hunger2017-09-191-5/+22
| | | | | Change-Id: Ib1d2bfca1b2faafd36c53f24c6649e73ee0af190 Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
* CMakePM: Fix compile with Qt5.6Christian Stenger2017-09-181-1/+1
| | | | | Change-Id: Ic50efba6b7ff70d4811b7e790e7b9c1f89a1fe44 Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
* CMake: Allow CMake configuration to be forced to string typeTobias Hunger2017-09-181-0/+30
| | | | | | | This allows editing values with misidentified types in Project Mode. Change-Id: Ic74da2ca71cc9046cbbeb1202075976c9edd28b7 Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
* CMake: Sort Project CMake configuration via the Proxy modelTobias Hunger2017-09-151-0/+3
| | | | | | | | Makes renaming items feel more natural as they do no longer stick to the top (note that currently you can only rename newly added items!). Change-Id: I89d0dc7cb73e08d8b60900a96ffd2ab1c2b490c2 Reviewed-by: hjk <hjk@qt.io>
* CMake: Only enable edit button for CMake configuration when usefulTobias Hunger2017-09-151-0/+22
| | | | | | | Only enable the button when items are actually editable. Change-Id: I54fd5430772a6db61c85b59d5c655d3bd4ebf8d7 Reviewed-by: hjk <hjk@qt.io>
* CMake: Group entries in project configurationTobias Hunger2017-09-121-6/+10
| | | | | Change-Id: I6aa797f5ff49a5cc33dfbdf0b25dcd78abbff66e Reviewed-by: hjk <hjk@qt.io>
* Utils: Separate rendering out of ProgressIndicatorTobias Hunger2017-07-271-1/+1
| | | | | | | | | I want to reuse the rendering of the progress indicator outside of a widget. Change-Id: Icaeeb798578ad838693b68556bf2193c4ba45cfa Reviewed-by: Eike Ziller <eike.ziller@qt.io> Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
* CMake: Simplify signalingTobias Hunger2017-07-261-1/+1
| | | | | Change-Id: I50fdaed0d813b5004c1756e9c5a6efd3ce7a3318 Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
* Project: Move signalling of parsing state into ProjectTobias Hunger2017-07-261-1/+1
| | | | | | | Get rid of duplicated code to do such signaling in derived Project types. Change-Id: I26914a1d751d72ee65c15a7943e0e7f34978f042 Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
* CMake: Filter CMake variablesFelix Kälberer2017-05-171-2/+17
| | | | | | | | | | Add a text field to filter CMake variables in the CMake project configuration view. As in the cmake-gui, the filter does a simple string search over all variable names and values. Task-number: QTCREATORBUG-17973 Change-Id: Id7219c16509c620c39978cb05c5e0e62cf9c19df Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* CMake: Clear error flag in CmakeBuildConfigurationTobias Hunger2017-04-071-0/+2
| | | | | | | | | Remove/refresh the error message in the CMake build configuration when the enabled state changes. Task-number: QTCREATORBUG-17948 Change-Id: I0f210fc572dde40a9adfee7ec2d934926d576d61 Reviewed-by: hjk <hjk@qt.io>
* CMake: Keep project configuration table visible at all timesTobias Hunger2017-02-031-5/+3
| | | | | | | | | Keep the project configuration visible at all times. This way users can actually add settings, even when the configuration fails. Task-number: QTCREATORBUG-17628 Change-Id: I0a342e0cba1dd720661a171818e0d91415ef5703 Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
* CMake: Mark changes to CMake configuration that contradicts a kitTobias Hunger2017-01-201-0/+18
| | | | | | | | Mark changes in the project that override configuration settings from the kit. Task-number: QTCREATORBUG-17244 Change-Id: I3452116ad5f4626ffcd85dfcc86715b6946d6572 Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
* Rename the "ERROR" icon to "CRITICAL"Ulf Hermann2017-01-021-1/+1
| | | | | | | | | | | | | We mostly use this icon in terms of showing messages which might be informational, warnings, or errors. We cannot call the icon "ERROR" as that clashes with some macro on windows. To be more inline with Qt's predefined messaging macros (qDebug(), qInfo(), qWarning(), qCritical(), qFatal()), we rename the icon to "CRITICAL" and regroup the entries in the header to suggest this usage. Change-Id: I89880919d7ca54ea9c86de384eb29f375bf3075f Reviewed-by: Maurice Kalinowski <maurice.kalinowski@qt.io> Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
* CMake: Stop progressindicator on build settings widget on errorTobias Hunger2016-12-051-0/+5
| | | | | Change-Id: I75051aa23baa88d984092ba594dda72c489d7c19 Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
* CMakeProjectManager: Support drop down selector for optionsAlexander Drozdov2016-10-101-0/+2
| | | | | | | | | | | | | | | | | | | CMake provides "hack" for cmake-gui, that allows set options variants and select then from drop down list. Allows Qt Creator re-use this solution. See: - https://blog.kitware.com/constraining-values-with-comboboxes-in-cmake-cmake-gui/ - http://blog.bethcodes.com/cmake-tips-tricks-drop-down-list Drop down values can be added to option via: SET_PROPERTY(CACHE OptionName PROPERTY STRINGS Option1 Option2 Option3) This solution should not restrict to provide any other value, it provides only suggestion for user to select one of prdefined values. Change-Id: I8fc52155775f1e04979db8206bb42363df9359e8 Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>