Commit Graph

3443 Commits

Author SHA1 Message Date
Tobias Hunger
c251a22dc4 CMakeProject: Remove friend from CmakeProjectNode class
Change-Id: I562db9a1299f47f993517999070a99b12b26e04b
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2015-11-02 15:14:21 +00:00
Eike Ziller
310ae09996 Merge remote-tracking branch 'origin/3.6'
Change-Id: I68512c775ed25b51c8b0abe1818c9c7c5955874c
2015-10-30 16:08:03 +01:00
Tobias Hunger
e60f62c131 ProjectNodes: Sprinkle override over the Node classes
Change-Id: I87db3a1b212aa0a3f140b8d299679f6c1f691004
Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com>
2015-10-30 13:35:53 +00:00
Tobias Hunger
ca6144f0d6 CMake: Fix cmake preloadCache file support
* Make it work at all again for cmake configurations without a
  preloadCache file
* Fix the KitInformation to provide the getters/setters like all
  the other KitInformation do
* Use those setters consistently
* Remove useless conversion from QString to QByteArray and back

Change-Id: I8fc43b3531da2c04034c89b29915a29c331fe064
Reviewed-by: Cristian Adam <cristian.adam@gmail.com>
Reviewed-by: Benjamin Zeller <benjamin.zeller@canonical.com>
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2015-10-29 16:21:18 +00:00
Robert Loehning
5d588d4100 CMake: Show native separators in CMakeRunPage
Change-Id: Id82db707cbed96a125c3bc84375482873127ce99
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2015-10-28 10:04:54 +00:00
Christian Kandeler
93ea3e2844 CMakeProjectManager: Fix qbs build.
Change-Id: Id85e0c05eb8989992890d244db461bb97ead9aff
Reviewed-by: Tom Deblauwe <deblauwetom@gmail.com>
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2015-10-27 11:04:03 +00:00
Tobias Hunger
aface7b1d6 Expand CurrentBuild:Type in the wizards
This was just unset before.

Task-number: QTCREATORBUG-15178
Change-Id: Ice66273e2ce9bc60bd8a96516f774201a7a95331
Reviewed-by: Alessandro Portale <alessandro.portale@theqtcompany.com>
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2015-10-26 16:57:02 +00:00
Tom Deblauwe
751c8252e0 CMake: Reapply fix for finding the corresponding source directory.
It seems this fix has been removed when refactoring the CMakeCpbParser class out.

See commit a700e625ef.

Change-Id: Ia217a21d579b7b3a1478a66f9920d1b57b986b04
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2015-10-26 15:11:49 +00:00
Tobias Hunger
95b94cf602 Cmake: Fix build
... and shorten some lines along the way.

Change-Id: I154610ebcf2f9592d105c6fcae8084c12a79e1d1
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2015-10-26 15:01:09 +00:00
Tom Deblauwe
f6fcfb4c9a CMake: add preload cache cmake script file per kit
Change-Id: I51c33610f2eb300ef5de2e565c567d799eddc9cf
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2015-10-26 12:37:54 +00:00
Leena Miettinen
2af989376b CMake: fix UI text
Change-Id: I6803aa799e495007358dbc5f5ee6b8e1d2c6e874
Reviewed-by: Benjamin Zeller <benjamin.zeller@canonical.com>
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2015-10-23 12:53:28 +00:00
Ulf Hermann
69377f0de4 Introduce Profile build mode
We define a Profile build to be a Release build with separate debug
info. You can thus change a given build from Release to Profile of vice
versa by toggling the separate debug info checkbox. The messaging for
future user interaction about Profile builds has to take this into
account.

Task-number: QTCREATORBUG-14009
Change-Id: I62a5b13993b20bf36329b1eefa8b1b6096f31644
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2015-10-20 16:15:18 +00:00
Benjamin Zeller
465722be78 CMakeProjectManager: Remember the preferNinja setting
There was a problem in the CMakeSettingsPage that prevented
the preferNinja setting to be remembered. This patch fixes
it.

Task-number: QTCREATORBUG-15162
Change-Id: I9ffaa67e05f2c99b5e9136f3c98004c68d03dede
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
Reviewed-by: Daniel Teske <daniel.teske@theqtcompany.com>
2015-10-09 15:43:57 +00:00
Orgad Shaneh
c3772f478c Cmake: Fix MSVC warning
cmakeautocompleter.cpp:113: warning: C4129: '(' : unrecognized character escape sequence

Change-Id: I4dccf3a0690a9c755c1e4672bfa669deaf893be2
Reviewed-by: Daniel Teske <daniel.teske@theqtcompany.com>
2015-09-29 10:33:47 +00:00
Jan Dalheimer
ac98023275 CMake: Indentation and matching brace insertion for the CMake editor
Adds the following improvements to the CMake editor:
* Indentation support (both through Ctrl+I and when pressing enter)
* Insertion of matching paranthesis and quotes (pressing '(' inserts ')')

Change-Id: If9a63b08b3e0897989e4d8ac69e3acc072b0b825
Reviewed-by: Daniel Teske <daniel.teske@theqtcompany.com>
2015-09-26 10:36:00 +00:00
Daniel Teske
1c38aa287a Simplify logic for showing UnconfiguredTargetPanel/TargetPanel
This doesn't change when the those panes are shown.

Change-Id: Ie5a2d27321e5268f59775892198999a8414a0adb
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2015-09-18 17:44:33 +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
Daniel Teske
bcdadbec72 ProjectNode: Provide default implementations of a few functions
Since a lot of derived classes can make use of those.

Change-Id: I051542e8d318476348d753de4d4c0a30b3a9ed62
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2015-09-15 10:46:28 +00:00
Eike Ziller
c868b9f3ed Merge remote-tracking branch 'origin/3.5'
Change-Id: Ife5fdcd71b0adc99d4297a28a64515e9e93d7864
2015-09-04 09:19:28 +02:00
Christian Kandeler
8d3aa026e0 Utils: Rename PathChooser::changed() signal.
The name is overly generic, particularly with a pathChanged() signal
also present. Rename to "rawPathChanged", which adequately describes the
semantics.

Change-Id: Ia62b8b0a97a794cb6d5ad6b8ce0abcd36b5f5cdb
Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com>
2015-09-03 11:12:57 +00:00
Benjamin Zeller
4ffb6649ec CMakeProjectManager: Use factories to create runconfig
At the moment RC factories are ignored when creating
runconfigurations or updating them. This patch changes
the behavior so the RCs are first created/removed and
then updated to match the build targets. This way plugins
can provide custom factories and RCs for cmake projects.

Change-Id: I4a7797e7382784e33ecf016e322eab00e20c07e0
Reviewed-by: Daniel Teske <daniel.teske@theqtcompany.com>
2015-09-03 10:38:23 +00:00
Robert Loehning
0a1ad894d5 CMake: Fix project tree displaying "." folders
Task-number: QTCREATORBUG-14994
Change-Id: Iea5a820083b8fc1974a749992f937965285370b6
Reviewed-by: Christian Kandeler <christian.kandeler@theqtcompany.com>
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2015-09-01 13:37:21 +00:00
Eike Ziller
3b1a966cc8 Merge remote-tracking branch 'origin/3.5'
Change-Id: Iebaabfc2f724cd493b7cab025406531cea5cd2dc
2015-09-01 12:57:51 +02:00
Daniel Teske
cea36f1376 Fix various context menu actions from project managers
The correct pattern is this: The actions in the build menu are supposed
to be for the startup project. They should use the global context and be
manually hidden/shown if the startup project changes.

This fixes a crash on assigning keyboard shortcut to the edit files
context menu action.

The slot connected assumed that the action could only be triggered via
the context menu. By using ProjectTree;:currentProject() the code now
works even if the project tree is not actually focused.

It also fixes that the "Run CMake" action was shown even in the build menu,
even though a non cmake project was the startup project.

Change-Id: I0bb8086d8b1078b4c71c3b5ba9d7f8596757e724
Task-number: QTCREATORBUG-14728
Task-number: QTCREATORBUG-14768
Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com>
2015-08-31 14:57:36 +00:00
Daniel Teske
13c2c40636 Cmake: Read the build.ninja file only once
The first getCmakeCXXFlags that reads the build.ninja file
stores the contents in the inout parameter cachedBuildNinja.
Further calls to getCMakeCXXFlags just use this cached value.

This prevents excessive locking of this file while constructing
the code model information.

Change-Id: I81e1431194bed6913c69abb2d954068c999a5c1b
Task-number: QTCREATORBUG-14639
Reviewed-by: Tom Tanner
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2015-08-31 10:20:12 +00:00
Daniel Teske
c9a9f08d0a Cmake Open Project: Allow opening projects that have cmake errors
Change-Id: I3779fbe3f6409139b3d027f96ad390a174c0ff7f
Task-number: QTCREATORBUG-6903
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2015-08-31 10:19:45 +00:00
Eike Ziller
cd5f9f6ff8 Merge remote-tracking branch 'origin/3.5'
Change-Id: I7b3ef276d438ff0f184a649153e8aeec08a9f8c9
2015-08-04 13:16:03 +02:00
Orgad Shaneh
866310d56f CMake: Initialize kit priority
Detected by memcheck

Change-Id: I27bb03ce4b4b63ae596bd3a788b6a95cd0944454
Reviewed-by: Daniel Teske <daniel.teske@theqtcompany.com>
2015-08-03 09:35:31 +00:00
Daniel Teske
edad1ba516 Project: Improve fromMap() error reporting interface
Instead of just a bool, return a tristate of: Ok, Error and UserAbort.
Also add a out parameter errorMessgge.

Change-Id: Icb076de49998e9372839d0631c2776e905e4a0f6
Task-number: QTCREATORBUG-13223
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@theqtcompany.com>
2015-07-28 10:34:12 +00:00
Sergey Belyashov
007daabff5 Fix i18n problems
In the QmlEngine, a few tr() have been replaced by
QCoreApplication::translate().
In other files, Q_OBJECT has been added to the class definitions.

Change-Id: Ia0505c19934dc691cd3d67f4946293290c2fec68
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Daniel Teske <daniel.teske@theqtcompany.com>
Reviewed-by: hjk <hjk@theqtcompany.com>
2015-07-23 19:19:06 +00:00
Daniel Teske
902db4fa28 Cmake: Fix autodetection of cmake on Windows
By using some of the infrastructure in Utils::Environment. Due to
wanting to find all cmake executables in PATH and not just the
first one, we need some custom code.

(cherry picked from commit ca8b43f6c8)
Change-Id: If3161d712b9f6e659450a3d0647f83344e68ba5d
Task-number: QTCREATORBUG-14740
Reviewed-by: Robert Loehning <robert.loehning@theqtcompany.com>
Reviewed-by: Daniel Teske <daniel.teske@theqtcompany.com>
2015-07-21 10:48:07 +00:00
Daniel Teske
ca8b43f6c8 Cmake: Fix autodetection of cmake on Windows
By using some of the infrastructure in Utils::Environment. Due to
wanting to find all cmake executables in PATH and not just the
first one, we need some custom code.

Change-Id: If3161d712b9f6e659450a3d0647f83344e68ba5d
Task-number: QTCREATORBUG-14740
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Benjamin Zeller <benjamin.zeller@canonical.com>
Reviewed-by: Daniel Teske <daniel.teske@theqtcompany.com>
2015-07-17 10:25:25 +00:00
Daniel Teske
21d547998f Fix leaking of CMakeTools
Change-Id: I36d3d19cbd0bccc3ee74f8aae1622dbed22aa45a
Task-number: QTCREATORBUG-14727
Reviewed-by: Benjamin Zeller <benjamin.zeller@canonical.com>
Reviewed-by: Daniel Teske <daniel.teske@theqtcompany.com>
2015-07-15 14:56:04 +00:00
hjk
93fd1d0507 {Q,C}makeProjectManager: Adjust tooltip capitalization
Follows suit after 3d78ec69bb.

Change-Id: I1756e0e50dcf414db9ea3f3b2092f8eeb647ae80
Reviewed-by: Daniel Teske <daniel.teske@theqtcompany.com>
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@theqtcompany.com>
2015-07-07 07:51:57 +00:00
Eike Ziller
4dd95aa5d4 Merge remote-tracking branch 'origin/3.4'
Change-Id: Id13cbdf2f7047366e543c91fbe7c21a9c4759e56
2015-06-17 12:04:21 +02:00
Joerg Bornemann
f0467f8b01 support Visual Studio 2015
Task-number: QTBUG-46344
Change-Id: I49c3e2776e65cc83d40d1f5ab3be1365d17242d1
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
2015-06-15 11:53:37 +00:00
wonder.mice
34b92b7574 CodeBlocks: Take into account file target when explicitly specified
Change-Id: I37556ef6c2c7a651709012daa9a84c66cf3af505
Reviewed-by: Daniel Teske <daniel.teske@theqtcompany.com>
2015-06-15 10:18:18 +00:00
Eike Ziller
6dd0e79d09 Add override to IDocument hierarchy
Change-Id: I6884f59fe0f06e380254c1f8076dd561d9df4ee3
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2015-06-11 09:32:18 +00:00
Eike Ziller
b1393d4778 TreeModel: takeItem should return the item
The usual Qt API for "takeXyz()" methods is to return the item that was
"taken".

Change-Id: Ie144051801487a301b3f13e2857735b65f58150b
Reviewed-by: hjk <hjk@theqtcompany.com>
2015-06-10 08:05:32 +00:00
Eike Ziller
e00aa54f4e Add override keyword to IEditor & TextEditorWidget implementations
Change-Id: I403101d788d9edfea5c5c9440ab4f39ad00e81f7
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2015-06-09 04:17:42 +00:00
Tobias Hunger
51fec1a3ca cmakeprojectmanager: s/Q_DECL_OVERRIDE/override/g
Change-Id: I9465394a8c128e894e3e758d2494e5e8b50c8b37
Reviewed-by: Daniel Teske <daniel.teske@theqtcompany.com>
2015-06-03 13:48:24 +00:00
Daniel Teske
ebf051be27 CMakeRunPage: Fix appending of error messages
Change-Id: I2b1c54bbe948ca8b3ba5384a2e97e29b2fd878c9
Task-number: QTCREATORBUG-14439
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2015-05-18 10:51:02 +00:00
hjk
b02b0c8d6d CMake: Remove no more used CMakeRunConfiguration::setRunMode function
Change-Id: I1e618408ba87fa1fbcd3c78498adb83d149d935a
Reviewed-by: Daniel Teske <daniel.teske@theqtcompany.com>
2015-05-18 07:36:35 +00:00
hjk
192b3fc994 CMake: Use TerminalAspect in CMakeRunConfiguration
Change-Id: I293252c2beadc6fc4b4650dbf09127aa5e7898f6
Reviewed-by: Daniel Teske <daniel.teske@theqtcompany.com>
2015-05-12 11:51:29 +00:00
Eike Ziller
4058ff6fe9 Merge remote-tracking branch 'origin/3.4'
Conflicts:
	src/libs/extensionsystem/pluginview.cpp

Change-Id: I410156c1003d5dc81e915110c6d432bcd71da010
2015-05-07 14:42:46 +02:00
hjk
a6990e7e24 CMake: Use ArgumentsAspect in CMakeRunConfiguration
Change-Id: I30fbfc0bcc5e6c997190c3f1a1c279dab06fdbc0
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2015-04-30 12:37:16 +00:00
Tobias Hunger
5b77a3a8c1 Blackberry: Remove blackberry support
Keep QNX.

A short informal search did not turn up any more blackberry users,
even though there is interest in QNX. So this patch removes the
platform: We had no contact with the maintainers in months, there
are no changes going into the code for about as long.

I am not even aware of anybody testing the platform, so any
remaining users are probably better of with Qt Creator 3.2 or so
where the code was extensively tested.

Change-Id: Ibeda6bfd8565599918cfcc08fd01cb5ed8793dc2
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2015-04-30 11:15:53 +00:00
Claus Steuer
81f64f85a0 CMakeProject: Fix CXX Flags parsing for ninja projects
For ninja projects the "build.ninja" file is parsed to extract the cxx
flags for each target. This file is located in the working directory
of the "all" target, however since commit "65c113bc" qtcreator searches
in the build directory of the current target. I have restored the
search behavior to the previous state and added some code to ensure
that the parsed flags really belong to the target

Change-Id: I7cc7f6dbd4f12aec698133206da889037131bb13
Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com>
Reviewed-by: Daniel Teske <daniel.teske@theqtcompany.com>
2015-04-24 09:36:52 +00:00
hjk
2b19081cb0 TreeModel: More API cleanup
- introduce topLevelItemCount (similar to QTreeWidget)
- squash untypedTreeLevelItems()
- rename removeItems() to clear()
- rename removeItem() to takeItem()
- rename treeLevelItems<> to itemsAtLevel<>

Change-Id: I0f1bb4110f7687b20da3d92e3d943858645a9fa2
Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com>
2015-04-22 13:48:18 +00:00
hjk
89b0e4c069 TreeModel: API cleanup
- rename index{From->For}Item
- rename item{From->For}Index
- remove ununsed setColumnCount

Change-Id: I1cce9657e476dd1e8ffa9f7cdb2e646fab6884ab
Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com>
2015-04-22 12:08:37 +00:00