Commit Graph

54723 Commits

Author SHA1 Message Date
Tobias Hunger
6829e33dc2 CMake: Move headers into their own folder in server-mode
Move all project headers into one folder. This reduces the time it
takes to generate the project tree, since the headers will only show up
once now (instead of once per target), severly reducing the number of
nodes in the tree.

Change-Id: Ibcfa7c02c1aec4a98054f4f8a97b69dfb4c25ae4
Reviewed-by: hjk <hjk@qt.io>
2017-03-29 11:53:11 +00:00
Tobias Hunger
348aa12eaa ProjectExplorer: Provide ProjectDocument and use it in all projects
Change-Id: I6e054ebf1043bd1f6748f1567f35c68394bd6528
Reviewed-by: hjk <hjk@qt.io>
2017-03-29 11:03:34 +00:00
Eike Ziller
06250531db Simplify Utils::transform (again)
Change-Id: I14690b55e9eeeac0aff243a6dfd6b83e7325179b
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
Reviewed-by: Nikita Baryshnikov <nib952051@gmail.com>
2017-03-29 09:05:42 +00:00
Przemyslaw Gorszkowski
163b2c027d Beautifier: added support for fallback-style option for clang-format
Task-number: QTCREATORBUG-17813
Change-Id: I36adee4889d1b851171d34852eed29639c68b574
Reviewed-by: Lorenz Haas <lorenz.haas@histomatics.de>
Reviewed-by: hjk <hjk@qt.io>
2017-03-29 08:35:24 +00:00
Thomas Hartmann
df64242ab2 QmlDesigner: Remove dead code
Change-Id: If0eb4e662a50d2bb6b1a44649b73bd3c517dba48
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2017-03-29 08:23:23 +00:00
Thomas Hartmann
d882cb4a8f Utils: Adjust name fillWithZero()
The name was quite missleading.

Change-Id: I538eca2a59e8a861e707fecd8331488e1919408a
Reviewed-by: David Schulz <david.schulz@qt.io>
2017-03-29 08:23:14 +00:00
hjk
666648e997 BareMetal: Adapt to introduction of ProjectExplorer::ToolSupport
Change-Id: I61efb5a19181618504b85e07c97b3bc400d9d537
Reviewed-by: Tim Sander <tim@krieglstein.org>
Reviewed-by: hjk <hjk@qt.io>
2017-03-29 08:11:25 +00:00
Tasuku Suzuki
2d196bd2a1 Move Session Manager... menu to Sessions > Manage...
Change-Id: If0f11c8c308069290174aa8cc6081108f9b448a1
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2017-03-29 08:07:35 +00:00
Orgad Shaneh
6a725ebd41 Core: Do not warn about big file that is already open
This is especially annoying during debug, when each step pops this
warning.

Change-Id: Id309c881f6b3062bc140740fe22b5c90cfddd08c
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2017-03-29 08:00:16 +00:00
Orgad Shaneh
74e570a858 Qmake: Add variable choosers where variables are parsed
Change-Id: I6203ebadbc934a7ae80ae1c5ca3cfad2471b787e
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2017-03-29 08:00:12 +00:00
Tobias Hunger
75538aa060 CMake: Speed up extra compiler processing a bit
Makes extra compiler selection 30% faster on my test project.

Change-Id: If78084ce4a5a93140598dd19e8448295ca122863
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-03-29 07:54:01 +00:00
hjk
fd8df8cff2 WinRT: Base WinRTDebugSupport on ProjectExplorer::ToolRunner
Change-Id: Ic4985d5eeee1af74a6f42b2b1df890450936f6f9
Reviewed-by: David Schulz <david.schulz@qt.io>
2017-03-29 07:41:16 +00:00
David Schulz
d0ee83768c Debugger: Reset expression syntax after evaluate
Fixes setting breakpoints after using python dumpers.

Change-Id: Ifd917526e91c73f82f943645e1d1d11790369179
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2017-03-29 07:05:28 +00:00
hjk
246c33ccba TextEditor: Avoid warning about unused parameter
Change-Id: I3f04f378330df85b8da3574d4bad2d74c4a4f4c7
Reviewed-by: David Schulz <david.schulz@qt.io>
2017-03-29 05:56:02 +00:00
Jarek Kobus
cd2a70c867 Remove unneeded includes
Change-Id: I83a6dc6ba33f7f8e1f6b1babbf60c69554435a0a
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
2017-03-28 19:13:42 +00:00
Eike Ziller
6dd428849a Guard against infinite loop in pathOrDirectoryFor(Node*,bool)
QFileInfo::absolutePath prints a warning and returns an empty string, if
given an empty string for the file path.

Task-number: QTCREATORBUG-17927
Change-Id: Ie49fc1500937c00ba579281785435e57464639ae
Reviewed-by: hjk <hjk@qt.io>
2017-03-28 15:43:27 +00:00
hjk
2a1e7cb9f5 RemoteLinux: Base AbstractLinuxRunSupport on PE::ToolSupport
This continues the quest started with eb0b0f944.

This also moves the AnalyzerRunControl::starting signal to the
base, similar to the already present started and finished
signals. Moving emission of the signal to the base is left
to a follow-up patch to keep this here small.

Change-Id: I12e04823df22e7667a4d0a9ee7412153180c60cc
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2017-03-28 14:50:05 +00:00
Jarek Kobus
9774f11738 Support diff a file from project explorer against the current file
Task-number: QTCREATORBUG-9432
Change-Id: Ie370bbffdb67dac520f392a73c1358f887157806
Reviewed-by: André Hartmann <aha_1980@gmx.de>
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2017-03-28 14:36:54 +00:00
Orgad Shaneh
ecacea18cb QmakePM: Fix toolchain executable comparison
Change-Id: I8fef9cb990be561cc822b33e772715895bbca6ca
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2017-03-28 13:58:44 +00:00
hjk
b0117cdfb4 QmakeProjectManager: Remove unused QmakePrifile::buildsFile()
Change-Id: Ia71e00036f5468415ffc2e5649efe96f3debbfc8
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2017-03-28 13:25:59 +00:00
Robert Loehning
93ce31ebb6 QmlDesigner: Remove dead code
Killed by a7a29fa6d6

Change-Id: If2952d5904b9c688387d1f904cb1b9a8e819d7f7
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
Reviewed-by: Robert Loehning <robert.loehning@qt.io>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2017-03-28 13:25:40 +00:00
Eike Ziller
1da65616b9 Add change log for 4.3
Change-Id: Ibf790b4a93fc83bb432f5b37d72aa7048acc1681
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
2017-03-28 13:23:39 +00:00
Thomas Hartmann
ddad6866eb QmlDesigner: Remove warning widget from DesignModeWidget
The form editor is now handling even initial warnings.
There is no need for an extra warning widget in the DesignModeWidget.

Change-Id: Iac85c1968e8040ee5f11435fa2876ce2d152c194
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-03-28 12:30:25 +00:00
Thomas Hartmann
acd08f24b8 Utils: Use brace initialization instead of constructor and 0
Calling T(0) for value types can lead to unexpected results.
Using brace initialization ensures we use value initialization
or the default constructor.

Change-Id: Ic33b186eebb1b37017d425ffca9bcf5d26df31d4
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-03-28 12:30:10 +00:00
Lorenz Haas
a5574bc802 Beautifier: Allow to define specific config file for AStyle
Change-Id: I3ea1a0bfb0f39d99606204a5699b01128138259e
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: David Schulz <david.schulz@qt.io>
2017-03-28 11:42:23 +00:00
Lorenz Haas
a9fb29e575 Beautifier: Fix tab order of Uncrustify's option page
Instead of defining a faulty tab order just let Qt do the job. The focus
jumped from "Use customized style" to "Format entire file..." instead of
to the combo box.

Change-Id: I33567d7cb6b8275a2b9a939c937a02d00f2f1bbc
Reviewed-by: David Schulz <david.schulz@qt.io>
2017-03-28 11:42:11 +00:00
Lorenz Haas
217df49346 Beautifier: Remove code that has no effect
The file name will be overwritten by restore(), called from
UncrustifyOptionsPage::widget(), right after the initialization.

Change-Id: Ieed634f351a7b3e79ed9327878534e69a8de7e95
Reviewed-by: Laurent Montel <laurent.montel@kdab.com>
Reviewed-by: David Schulz <david.schulz@qt.io>
2017-03-28 11:41:59 +00:00
Ulf Hermann
7b5db5db90 Timeline: Fix and clarify index lookup
There was a subtle bug in firstIndexNoParents(): If the model had
exactly one range with an endtime <= the given start time, it would
return 0, rather than -1.

Also, add some comments, and don't check for count == 1. The check for
count == 1 is redundant as that case is already covered by the endTime
and startTime checks for the first and last elements. As count == 1 is
really rare and this is a very hot code path, we drop it.

Change-Id: Ic21318cf82d2aea4c70d96989c56c2870dc871f7
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2017-03-28 10:52:29 +00:00
Ulf Hermann
1f23c11a56 Timeline: Further optimize item selection
We start from an event in the middle, rather than at the edge of the
permissible range. Then we work our way to the edges, cutting the search
short when we find that we cannot get better anymore. This reduces the
number of events that have to be checked.

Change-Id: Iba4591aa5ef71a769f26e7ee003701ffc68d3340
Task-number: QTCREATORBUG-14983
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2017-03-28 10:22:53 +00:00
Ulf Hermann
7432cd4fe6 Timeline: Add functions to find "best" and parent index in a model
This is useful if you have a timestamp and are looking for a range that
is "close" to that timestamp. It's hard to determine a range that
actually covers the timestamp, but the "best" index gives a pretty good
starting point for a subsequent linear search.

In order to determine if there cannot be any earlier range that touches
a given timestamp we need to check the parent range. Add a function that
retrieves it.

Change-Id: I2a3cad006ff8449620c56899ab8166d1b62d6747
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2017-03-28 10:22:48 +00:00
David Schulz
86edeb9722 Debugger: Use native value for pointer dereference
Change-Id: Ibde6ff382e7adc0c196837c9eba04391c0a2c3a0
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2017-03-28 09:22:28 +00:00
hjk
3aa13958fd ProjectExplorer: De-virtualize Project::files()
It's never overloaded.

Change-Id: Ia733e7525a98c19060abbbfc2ae49c06be8b8d5d
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2017-03-28 08:30:40 +00:00
Eike Ziller
016767b2a6 Merge remote-tracking branch 'origin/4.3'
Conflicts:
	src/plugins/genericprojectmanager/genericproject.cpp
	src/plugins/genericprojectmanager/genericproject.h
	src/plugins/projectexplorer/projectmodels.cpp

Change-Id: I290cba328212cadd3c12909d1f2f3642d326a1ca
2017-03-28 09:56:16 +02:00
hjk
2ee7967750 ProjectExplorer: Fix enabling state of main project nodes
Since the rootProjectNode() containing the parsed files is now nested
under a new project node the main node needs to delegate enable/disable
decisions.

Task-number: QTCREATORBUG-17922
Change-Id: Ie7bb6d6802072a2127b32c0fe51fb25fc1c9c6cc
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2017-03-28 07:10:54 +00:00
David Schulz
7f5b37ed14 Debugger: Disable QObject property dumper test on Windows
Change-Id: Iff91a41aae9328c6e935480c5cfc2fe3643ca743
Reviewed-by: hjk <hjk@qt.io>
2017-03-28 05:38:30 +00:00
Christian Stenger
0a3efc042d AutoTest: Fix warning for guessed configs
The check whether to emit a warning regarding guessed
configurations must get evaluated after the configuration
has been completed otherwise the guessed flag would be
always false.

Change-Id: I20e6dcdfff5110d4d9128ffcc97cba1a70f44fe9
Reviewed-by: David Schulz <david.schulz@qt.io>
2017-03-28 05:07:04 +00:00
Christian Stenger
124efb32f5 AutoTest: Re-do completeTestInformation()
Use information provided by the codemodel and the run configurations
as much as possible to avoid guessing.
This also fixes running CMake based tests from within the
AutoTest plugin.

Task-number: QTCREATORBUG-17882
Change-Id: I5639fa947fa602b76faf50e9b58d7a74af4e1f9c
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2017-03-28 05:06:55 +00:00
Christian Stenger
a65ce0fe5b CMakePM: Fix assignment of build system target
Additionally rename formerly used variable to better express
what it is for.

Change-Id: I6ecf6a5ac30bc411b41a1de3629a27f8882a0a28
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2017-03-28 05:06:43 +00:00
Orgad Shaneh
d2c3cff407 QmlDesigner: Re-add core-private also in qbs build
Change-Id: I197a4caafe984326778b6613957bbd3d327680d9
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2017-03-27 17:36:59 +00:00
Tobias Hunger
fc5ce1e710 ProjectExplorer: Handle project file list globally
Handle the generation of the list of files in a project globally, based
on the project tree.

Creator now has the concept of TreeManagers which can enrich the project
tree with additional data (e.g. the files found in a resource file), which
the project does not necessarily know about. So use that tree to find
the files that belong to a project instead of implementing similar features
in each project.

Change-Id: Ia375a914a1f2c0adaa427f9eda834eec2db07f68
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Marco Benelli <marco.benelli@qt.io>
2017-03-27 15:32:13 +00:00
Tobias Hunger
d1a5304564 CMake: Fix WS
Change-Id: Id06a9d8d831fcc0ce3fe38f852e34e144a79e0e9
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-03-27 15:32:02 +00:00
Tobias Hunger
437af83c9a QmlJSModelManager: Avoid needless Mime database lookups
This speeds up processing of a cmake project without any QML files by a
factor of 16 on my machine.

Task-number: QTCREATORBUG-17884
Change-Id: I823d4a051451adbca10a8b73c17d288e03387378
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2017-03-27 15:18:15 +00:00
David Schulz
767d988891 Debugger: Cache reference to an unresolvables type as struct
This fixes throwing an uncaught exception if local variables contain
arrays or pointer to a type that can not be looked up.

Change-Id: If9407e5cf5d86bb89594266d4122a53dd65a80bb
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2017-03-27 13:19:13 +00:00
David Schulz
bb04bbe9d4 Debugger: Add dumper for Utf8String
Change-Id: I0f9411a246d121e22c8b65bf188598c427993726
Reviewed-by: hjk <hjk@qt.io>
2017-03-27 12:01:16 +00:00
hjk
173186c31d ProjectExplorer: Show something during parsing again
This partially reverts 5ac13620. Looks like "soon enough" is not
soon enough for non-trivial projects.

Change-Id: Ib0d317c36e78f1af12b6c1f2a2aab48922517e98
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2017-03-27 11:57:49 +00:00
Tobias Hunger
7da1e233eb ProjectExplorer: Add missing breaks to switch in Abi class
Change-Id: I6c855d221e7a4d81f7338bc119c7ecff815e7ea6
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-03-27 11:54:09 +00:00
Tobias Hunger
3a20cec60a CMake: Break loop in error handling
Block access to the BuildDirManager while one of its errors is
processed. This prevents more errors being raised as part of
error handling, which can trigger a loop.

Task-number: QTCREATORBUG-17869
Change-Id: Ic6f8d9a3c3b4e63f27260c40f27ab09d20b62b3e
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-03-27 11:53:43 +00:00
Tobias Hunger
17b89cd422 CMake: Speed up server-mode reader
This patch reduces the time to generate a project tree by 15% in
my test project.

Change-Id: Ie5956cdd2108873118654857dc299bdb0b6d3636
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-03-27 11:53:35 +00:00
Tobias Hunger
54be52a4fa ProjectNodes: Enable nested nodes outside of the top level node
Enable adding nested nodes not a child of the top level node.

Change-Id: Ia6bb4ed6e3e6649a98151c88133ff5ec7197573d
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-03-27 11:53:29 +00:00
Ulf Hermann
2703d02db6 Timeline: Only search hovered events when !selectionLocked
Otherwise we are not going to do anything with the result. The
searching can be very expensive would happen whenever the mouse moves.
This also makes the q_ptr in TimelineRendererPrivate obsolete.

Change-Id: I582d0e85b63925f3f329e9a7463f2abee7947c5b
Task-number: QTCREATORBUG-14983
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2017-03-27 09:25:42 +00:00