Commit Graph

40 Commits

Author SHA1 Message Date
Tobias Hunger
aa4e05f07b CMakeBuildSettingsWidget: Fix filtering in cmake configuration
This got broken with the introduction of the grouping.

Task-number: QTCREATORBUG-15814
Change-Id: Ic9908d01a1ecb636db0c8f4b7f1db926ccaedd4e
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2017-10-17 14:47:02 +00:00
Tobias Hunger
b49722c820 CMakeBuildSettingsWidget: Forward-declare ProgressIndicator
Change-Id: I3808e973671849c6014780ee99896cb2d139dc18
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2017-10-17 14:46:56 +00:00
Tobias Hunger
b1157e4e63 CMake: Allow to unset configuration values
Change-Id: I649323e3c2cc51ea69dd7e216f30eeb653f3873b
Reviewed-by: hjk <hjk@qt.io>
2017-10-17 08:21:07 +00:00
Tobias Hunger
02533e61cf CMake: Fix project parsing notification
This builds on top of 08677c0b01 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>
2017-10-06 09:53:40 +00:00
Christian Stenger
bf5bc72b5a CMakePM: Fix compile with Qt5.6
Broke with be376ae7.

Change-Id: I9c99a7be78c7ec0359cefee84e2e1877d20f25bf
Reviewed-by: André Hartmann <aha_1980@gmx.de>
2017-09-20 05:22:24 +00:00
Tobias Hunger
be376ae706 CMake: Enable type forcing for CMake configuation values
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>
2017-09-19 13:17:50 +00:00
Tobias Hunger
f4ff420036 CMake: Improve delegates for CMake configuration
Change-Id: Ib1d2bfca1b2faafd36c53f24c6649e73ee0af190
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-09-19 08:42:20 +00:00
Christian Stenger
b1373c4853 CMakePM: Fix compile with Qt5.6
Change-Id: Ic50efba6b7ff70d4811b7e790e7b9c1f89a1fe44
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-09-18 12:16:05 +00:00
Tobias Hunger
dfec256dff CMake: Allow CMake configuration to be forced to string type
This allows editing values with misidentified types in Project Mode.

Change-Id: Ic74da2ca71cc9046cbbeb1202075976c9edd28b7
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-09-18 11:36:51 +00:00
Tobias Hunger
63ce81db5e CMake: Sort Project CMake configuration via the Proxy model
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>
2017-09-15 12:10:19 +00:00
Tobias Hunger
8e5528212f CMake: Only enable edit button for CMake configuration when useful
Only enable the button when items are actually editable.

Change-Id: I54fd5430772a6db61c85b59d5c655d3bd4ebf8d7
Reviewed-by: hjk <hjk@qt.io>
2017-09-15 12:10:13 +00:00
Tobias Hunger
cacb6b17d0 CMake: Group entries in project configuration
Change-Id: I6aa797f5ff49a5cc33dfbdf0b25dcd78abbff66e
Reviewed-by: hjk <hjk@qt.io>
2017-09-12 12:55:51 +00:00
Tobias Hunger
5d8b0e6352 Utils: Separate rendering out of ProgressIndicator
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>
2017-07-27 09:15:05 +00:00
Tobias Hunger
46f39f5601 CMake: Simplify signaling
Change-Id: I50fdaed0d813b5004c1756e9c5a6efd3ce7a3318
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-07-26 09:29:47 +00:00
Tobias Hunger
09b127f9f1 Project: Move signalling of parsing state into Project
Get rid of duplicated code to do such signaling in derived Project types.

Change-Id: I26914a1d751d72ee65c15a7943e0e7f34978f042
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-07-26 09:29:21 +00:00
Felix Kälberer
accac479e0 CMake: Filter CMake variables
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>
2017-05-17 20:29:23 +00:00
Tobias Hunger
06ccc35b3b CMake: Clear error flag in CmakeBuildConfiguration
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>
2017-04-07 11:43:45 +00:00
Tobias Hunger
9ac96339ff CMake: Keep project configuration table visible at all times
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>
2017-02-03 10:39:06 +00:00
Tobias Hunger
087d6d7472 CMake: Mark changes to CMake configuration that contradicts a kit
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>
2017-01-20 12:48:22 +00:00
Ulf Hermann
018ba5a834 Rename the "ERROR" icon to "CRITICAL"
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>
2017-01-02 12:27:54 +00:00
Tobias Hunger
c9f7aef71d CMake: Stop progressindicator on build settings widget on error
Change-Id: I75051aa23baa88d984092ba594dda72c489d7c19
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2016-12-05 09:27:57 +00:00
Alexander Drozdov
76b76f2723 CMakeProjectManager: Support drop down selector for options
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>
2016-10-10 15:07:30 +00:00
Ulf Hermann
15fbfaf2e9 Move icons to Utils
This way we can use them from libraries, not only from plugins.

Change-Id: Ic35cfd5f04d638d87606bf272b2c00ded1267c1b
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2016-08-05 10:52:53 +00:00
Stanislav Ionascu
c1d735503b CMake: make it possible to insert new vars in project settings
Task-number: QTCREATORBUG-16238
Change-Id: If98acc4f27cabbb606b2fc1017096da626ba1144
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2016-05-24 08:44:57 +00:00
Tobias Hunger
fd761cd790 CMake: Warn if kit settings are overridden by the project
Change-Id: I8f01b267f27617d6561124d173ac2e5ae5b9f4d6
Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
2016-05-20 11:52:17 +00:00
Tobias Hunger
76a050cb83 CMake: Move BuildDirManager from the project into the buildconfiguration
Change-Id: I90126ff22dd394eba4145db142b3914d211af476
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2016-02-26 12:17:31 +00:00
Tobias Hunger
0d10ce3834 CMake: Disable BC if there is an error during initial cmake run
* Disable the BC and give report the cmake error
* Show a warning label in the BC

Change-Id: If5737d033fa2682c264ab7ac1189c59947e3b28d
Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
2016-02-15 11:57:19 +00:00
Tobias Hunger
28e4306865 CMake: Add UI to display and edit cmake configuration
Change-Id: I95944dcd58dc86023c2757068979f92b8989011b
Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
2016-02-15 11:57:11 +00:00
Tobias Hunger
859bf2c5ce CMake: Do not run a cmake wizard all the time
Do not push the cmake running straight into the face of the user. Do it
in the background instead.

This needs some follow-up patches to become really useful.

Change-Id: I3457178b33e3f14bdeac25005a773d17abb73b65
Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
2016-02-15 11:04:45 +00:00
Tobias Hunger
397e7f4843 Update License according to agreement with Free Qt Foundation
* Update files in src/plugins

Change-Id: Ia5d77fad7d19d4bb3498e78661982f68729adb22
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2016-01-19 15:57:01 +00:00
Tobias Hunger
1d6c960f05 CMake: Avoid passing CMakeManager around
Change-Id: I96d7f3785767d1d56ca27a2d0af778edf98d63e1
Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
2016-01-08 12:50:26 +00:00
Tobias Hunger
b2b6d3c526 CMake: Semi-automatic cleanups
* Shorten header guards
* Use override and auto where possible
* Remove useless destructors, etc.
* Remove private slots sections, unify private: sections
* Use member initialization where it makes sense

Change-Id: I00eaf6d706adc16859176d1b68c631d3336bb39f
Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
2016-01-08 12:17:41 +00:00
Tobias Hunger
e26617c3ed CMake: Simplify setup of CMakeOpenProjectWizard
The information is contained in the BuildInfo, so there is no
need to provide it a second time.

Change-Id: I512d148e36996130fab6d8e007dd16d5acebaebb
Reviewed-by: Niels Weber <niels.weber@theqtcompany.com>
Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
2016-01-08 12:17:24 +00:00
Tobias Hunger
ad6c5db3eb CMake: Simplify code a bit
Change-Id: If16aed7a361a00a308570bdafc19ab5c6bb59e36
Reviewed-by: Cristian Adam <cristian.adam@gmail.com>
Reviewed-by: Niels Weber <niels.weber@theqtcompany.com>
2016-01-08 10:12:14 +00:00
Tobias Hunger
025f548b6e CMake: Make CMake build configuration widget look more like others
Change-Id: Iaed519d4d7e73d8fe313ba2c9028db702e59d7dc
Reviewed-by: Cristian Adam <cristian.adam@gmail.com>
Reviewed-by: Niels Weber <niels.weber@theqtcompany.com>
Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
2016-01-08 10:11:49 +00:00
Tobias Hunger
4756fbbfec CMake: Do not bother to remember ninja support status
Do not bother to remember ninja support status now that it is no longer
used.

Change-Id: Ief24af8e39ad5e39633ccb6d31858fa003de5ce8
Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
2016-01-08 10:11:24 +00:00
Tobias Hunger
11aff016fd CMake: Convert BuildSettingsWidget to Qt5 style connects
Change-Id: I8471196f08f99084dcd3b8173f4528ed6d3e305f
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2016-01-05 13:03:04 +00:00
Daniel Teske
014a7b332b CMake: Rewrite logic for kit selection
Some time ago the all the wizards for the Plain C++ were coalesced into one wizard.

Since then the wizard asks first for the targets via a targetsetuppage and then
in the CMakeOpenProjectWizard asked for the kit again.

This patch clean thats up, by always using the TargetSetupPage for kit
selection and removing code from the CMakeOpenProjectWizard for kit selection.

It also adds more types of buildconfigurations

Offer: Debug, Release, ReleaseWithDebugInfo, MinSizeRelease with the
corresponding -DCMAKE_BUILD_TYPE parameters. That argument is saved
in the build configuration and used once for the first cmake run. (Subsequent
runs of cmake don't require passing that to cmake again.)

Also do not require running cmake on creating the buildconfiguraiton, instead
postpone that until the buildconfiguration is made active. With the current
cmake wizard, selecting multiple kits would show a dialog per buildconfiguration.

Change-Id: I3bb806113f4f529f8e291830647d2515a6c4df8a
Task-number: QTCREATORBUG-12219
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2015-09-16 10:08:52 +00:00
Benjamin Zeller
cd3238cead CMakeProjectManager: Export CMakeProject
Export CMakeProject to make it possible for plugins
to inspect the BuildTargets of a cmake project.

Change-Id: Ia7eb94689afefee7789e32ec009579856746787a
Reviewed-by: Daniel Teske <daniel.teske@theqtcompany.com>
2015-03-10 13:32:01 +00:00
Benjamin Zeller
7ca9f1f277 CMakeProjectManager: Split up cmakeproject source files
Preparing for exporting the CMakeProject symbol. Removing all APIs
from the header file that will continue to be interal API.

Change-Id: I820ea0efb909e6a75be70ccb3b419f841a15cfb3
Reviewed-by: Daniel Teske <daniel.teske@theqtcompany.com>
2015-03-10 12:54:52 +00:00