Commit Graph

57214 Commits

Author SHA1 Message Date
Eike Ziller
4dbc62a47e Fix soft assert when adding file to subfolder in generic project
We can only select a node directly in the wizard summary page's project
tree, if that is actually listed there.

Task-number: QTCREATORBUG-21342
Change-Id: I52b3db8c38ae2bb59b3f6856e79354ca60a00140
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2018-10-18 12:30:04 +00:00
Eike Ziller
5bc38589d8 Fix crash when adding file to sub folder in generic project
The moment the file is added to the project, a reparse is triggered,
which invalidates the tree sub-nodes.
So we need to check if the context node (on which the wizard was opened)
still exists before trying to access it, similar to how we do that in
JsonSummaryPage::findWizardContextNode.

Change-Id: I9154e000a31ea8d5d4ebc66c25528d422c377b94
Fixes: QTCREATORBUG-21342
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2018-10-18 12:29:44 +00:00
Orgad Shaneh
a9ac438ad8 Git: Add quick filter for branches panel
Change-Id: Idef4ab2db69f24bb004c00fa010b814fdaa7d56d
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2018-10-18 12:26:26 +00:00
David Schulz
170e599a11 LSP: support file pattern filter and multiple mime types for lsp clients
Change-Id: I6d1b6c38d41dfd247c8883e765e5e432dbe53a9e
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2018-10-18 12:00:40 +00:00
Christian Stenger
2d7d08710e Squish: Adapt to debugger related ui changes
Change-Id: I452d4ccab7dc7c196277f008877ee58a1b2c8f7b
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: Robert Loehning <robert.loehning@qt.io>
2018-10-18 11:44:01 +00:00
Ivan Donchevskii
3f613d25a1 Clang: Move text cursor utility methods into ClangCodeModel
These 3 are only used in ClangCodeModel.

Change-Id: Id7c2cead40473bcb746e4b105aa36cb7d51a2740
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
2018-10-18 09:13:35 +00:00
Christian Stenger
bee01b69a2 RemoteLinux: Fix compile with gcc5.3 and MSVC2015
Amends f4a12d488c.

Change-Id: If731f634f473a8a051e4e5de0351f6387a2d1898
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
2018-10-18 08:22:00 +00:00
Andre Hartmann
4e0f14b8a5 BranchView: Add ellipsis to rename and remove action
Both open a new dialog to perform the action.

Change-Id: Ie93b99b1ff64927de24de49cd5e30ee729d749b2
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2018-10-18 08:16:23 +00:00
Orgad Shaneh
14d1cffe1e README: Adapt to clang submodules
Change-Id: I518b3b3d48b24de28b253188e78665ef299cde9f
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
2018-10-18 07:51:56 +00:00
Christian Stenger
4656446ab4 QmlDesigner: Silence compiler warning
Change-Id: I29f725b918c84cebfbf0a8b735bbfb66c620c803
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2018-10-18 07:42:26 +00:00
Christian Stenger
9bf4cf485e QmlDesigner: Fix compile for auto tests
Amends ada0c6f405.

Change-Id: I5a092fca7e7ce95d62e36e0efd9135beabccfd65
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2018-10-18 07:42:14 +00:00
Tim Jenssen
ada0c6f405 QmlDesigner: fix to not use not existing puppets
also remove the path if it is the same as the default path

Task-number: QTCREATORBUG-21303
Change-Id: I811ffab789c1cfc200aa2c68672ee4d6ee83ecfe
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2018-10-17 16:07:37 +00:00
hjk
dcd0faf4c4 RemoteLinux: Use aspects in TarPackageCreationStep
Less code.

Change-Id: I0cd0e6ff04c71c1a2a514388032521152f715094
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2018-10-17 13:39:05 +00:00
Orgad Shaneh
218a439bd5 Qbs: Fix pch detection when there are multiple tags
Change-Id: I21f789cbaa01b36180b3566420a01e5b052d6ace
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2018-10-17 13:29:43 +00:00
Ulf Hermann
f4a12d488c RemoteLinux: Check remote files when deploying
We discern between local and remote timestamps, and if the local
timestamp matches, we still query the remote file via SSH to see if that
one differs. If so, we still upload the file. After uploading a file we
always query its remote timestamp and save it along with the local one.

Fixes: QTCREATORBUG-21225
Change-Id: Ieeae1c3e61907beb7ad0fe9b03772af6ae351be7
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2018-10-17 13:13:32 +00:00
Christian Kandeler
5bf9ac7d56 Android: Prevent invalid assertions in toolchain detection code
NDK r17 removed the MIPS toolchains, but kept the respective
directories, which was enough for us to assume the compiler binaries
were also present.
Instead, we now explicitly check for the presence of the compiler
binaries.

Change-Id: Ice68cf497a66f5e8b900e29634a988547fdee0d8
Reviewed-by: Vikas Pachdha <vikas.pachdha@qt.io>
2018-10-17 12:46:46 +00:00
Eike Ziller
e06c8672ac Add changes file for 4.7.2
Change-Id: I042c29592b46a4f094251d241dba442bc4d728c6
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
2018-10-17 12:21:26 +00:00
hjk
32b4dbbd84 Debugger: Use actions in different contexts
... for F10-as-in-Start-and-break-at-main and F10-as-in-step-over.

Change-Id: Ie8e9e9be389a09a1485cadeea8b2d035a130920a
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2018-10-17 10:50:23 +00:00
David Schulz
77635c0ec9 LSP: warn on non existing language client executables
Change-Id: Ie996f80f4c4d836970f62f1a174bb92967dfb281
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2018-10-17 10:38:20 +00:00
David Schulz
7a7dcc9064 LSP: Fix positions for code completions
The columns are also zero based. All previously checked language server
that were tested seem to ignore the fact that the completion was
triggered outside of the line when triggering a completion on the last
character in a line. Never the less this issue can easily be reproduced
with other than the go language server when trying to complete code in
the middle of a line.

Fixes: QTCREATORBUG-21325
Change-Id: I1485f041a27b8fe8b85de4e13bac8bbb296dbf69
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2018-10-17 08:26:48 +00:00
Ivan Donchevskii
239c15b5e2 Fixes: Clang: Sort the initial list of includes for the code completion
Task-number: QTCREATORBUG-6242
Change-Id: Icdd5671801079a547a08b1276a6dbc76fed4bd30
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
2018-10-17 08:09:59 +00:00
Ivan Donchevskii
f8e6ba916c Clang: Fix abandoning the parentheses for function
Was introduced in 0f96f735f0 because the the incorrect
move to the '&' character.

Task-number: QTCREATORBUG-21305
Change-Id: I55d79e68795f55b758aa95072fca10bc00d49037
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
2018-10-17 07:31:05 +00:00
Ulf Hermann
d1cd39081b QmlProfiler: Further improve QmlProfilerTool test
Don't close the fake debug server after receiving one connection. The
client might time out after establishing the TCP connection, but before
receiving the hello message.

Also, retry more aggressively, just like we do in the
QmlProfilerClientManager test.

Change-Id: Ib0a6c068c97d8000b599d51f31f90712db219af2
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2018-10-17 07:16:29 +00:00
Ivan Donchevskii
cafd5ced1a Clang: Significantly improve ClangFormat plugin usability
What's new:
1. New LibFormat option is used to prevent lines shrink,
   which allows to drop most of tricks used before for that purpose.
2. Cached UTF-8 source code is used to improve performance
3. Improved error handling.
4. Slightly improved UI.

Change-Id: I4605200fa103167369a40650b2e1ad2c61e8133b
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
2018-10-17 07:16:04 +00:00
Christian Stenger
6f73b3b175 AutoTest: Limit test execution under cursor
Run and debug under cursor simply used the literal under
the cursor to find matching test cases or functions. This
obviously finds more than the test under cursor.
This patch limits this behavior by taking current file
and line number into account as well.
If the action gets triggered on a test definition then
the found tests are limited to this position.
If the literal under cursor does not belong to the
definition of the test (declaration, string, comment) the
original behavior gets triggered.

Fixes: QTCREATORBUG-21093
Change-Id: I051d25c1d18e819caf2950b5c62d51e6d70d1b22
Reviewed-by: pawelrutka <prutka13@gmail.com>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: David Schulz <david.schulz@qt.io>
2018-10-17 07:02:56 +00:00
David Schulz
613280bbe4 Debugger: Fix warn on release for CDB
Fixes: QTCREATORBUG-21328
Change-Id: I0dd09fa7df57d708aeb08e37d26d96031d28fb0c
Reviewed-by: hjk <hjk@qt.io>
2018-10-17 07:02:42 +00:00
David Schulz
c882286529 ProjectExplorer: cancel MSVC tool chain detection on shutdown
Task-number: QTCREATORBUG-21329
Change-Id: I681757f1a2e77ecd7f766f25ab554d57473f1c6d
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2018-10-17 07:01:49 +00:00
hjk
d6c605d84c ProjectExplorer: Change BuildStepConfigWidget::summaryWidget()
From a virtual function to a normal one backed by a real data member.

That's essentially what several re-implementations did, the other
ones used a fixed value instead.

Change-Id: I61e45f1d4f7f0f80fe2eb1f2729785f37e7bb803
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2018-10-17 06:14:55 +00:00
Ivan Donchevskii
3c1565efcb Clang: Fix build with clang 7.0
As an addition update the header with Clang-Tidy checks.

Change-Id: Ib4a4d324e8cad95403a3e799e352205b05ed7475
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
2018-10-17 05:56:51 +00:00
Ivan Donchevskii
78211741c8 Clang: Make SourceLocation lazily calculate its fields
Trigger path, line, column and offset evaluation only if one
of them is accessed.

Change-Id: Ib2f8b06ece94a3b7424db28523b5796628865202
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
2018-10-17 05:56:39 +00:00
David Schulz
727ea78a5d LSP: restrict automatic completion
Only request an automatic completion if the cursor is after at least 3
'identifier' characters (alphanumerical characters and underscore).

Change-Id: I1bac8f184042fb68135ce24c20d17fc134aae5ac
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2018-10-16 13:44:14 +00:00
Ulf Hermann
fb1c562c2e QmlJS: Don't recalculate the empty library's fingerprint
LibraryInfo::calculateFingerprint() is expensive. The default ctor will
always result in the same fingerprint. We only need to calculate it
once.

Change-Id: I680dc63624d68ddeca7f3467f4518d767274b246
Reviewed-by: Marco Benelli <marco.benelli@qt.io>
2018-10-16 13:28:05 +00:00
Christian Stenger
a2a29d1861 Debugger: Re-enable breakpoint state handling with keyboard
This patch re-enables disabling or enabling breakpoints using
the respective keyboard shortcut.
Had been disabled since d6911fd10c.

Change-Id: Iea3ce679bafcc78910be07984fd03b4a6e66eb8b
Reviewed-by: hjk <hjk@qt.io>
2018-10-16 12:07:33 +00:00
Christian Stenger
326adef0de Squish: Further adaption to UI changes of debugger
Change-Id: I0e28d2f929c7a69aa61313e3e5473143dc88e5b1
Reviewed-by: Robert Loehning <robert.loehning@qt.io>
2018-10-16 12:07:24 +00:00
hjk
d0d83f6b31 Debugger: Remove unused DebuggerRunTool::quitDebugger
Change-Id: Id3b59f9651ebc65e3fc7588bea789ccaa96522af
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2018-10-16 12:03:41 +00:00
hjk
8fc53e9764 Modernize non-existing IDevice::operator=()
Change-Id: Ia22ba1f307ef25348466740564072fd6fe8d6c9c
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2018-10-16 11:37:05 +00:00
hjk
7c562f1d4b Debugger: Remove unused DebuggerItem::m_autoDetectionSource
Change-Id: I02fb55cea393a4d8167942f66bdeb0af4e385e2c
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2018-10-16 11:31:07 +00:00
hjk
ded488819a ProjectExplorer: Remove BuildStepListWidget::additionalSummaryText()
... and related code.

The base implementation returns an empty string, the only re-implemented
version in the qmake step returned a member that has been empty since
243145621 "Profile introduction" in 2012.

Change-Id: Ifafdc1b88bf4a96cdca5b48d9ccf47b63d9d987a
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2018-10-16 11:20:32 +00:00
Nikolai Kosjar
3160172b58 ClangFormat: Fix constructing libs for qbs
Assignment after concat() was missing.

Change-Id: I9a038cae6372648561a5450e9e3417c4c603ab7e
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2018-10-16 11:06:22 +00:00
hjk
d58eac6325 Handle IDeviceFactory restoring in base class
Change-Id: Idb892bcff6b91dbc11a8271915e5cc86d1669e74
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2018-10-16 11:01:40 +00:00
David Schulz
7826fdaa56 LSP: fix crashing and leaking memory
... in the language client code assist by making the
code assist provider a member of the client.

Change-Id: I8ea22300a2c824ff00b87cdeaf8ea5f0cf95e4a9
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2018-10-16 10:40:48 +00:00
Christian Stenger
885be5524c Squish: Adapt to changed UI of debugger
Change-Id: I234ec55f69751f9fc9c543956fe5b9f058ef9633
Reviewed-by: Robert Loehning <robert.loehning@qt.io>
2018-10-16 10:40:41 +00:00
hjk
fa96f73192 Debugger: Rework step{In,Out,Over} handling
Main menu action pass operation to current engine, everything else
is handled there.

Combine execute{Step,Next} and execute{Step,Next}I functions.
Implementation were mostly similar, in some cases unneeded
(the instruction-wise version e.g. for Python)

Drop GDB-isms 'step', 'next' in favor of 'step in' and 'step over'.

Change-Id: I232232bc7a67d9d297a74f1c81dc43be96787d34
Reviewed-by: David Schulz <david.schulz@qt.io>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2018-10-16 10:34:31 +00:00
Ivan Donchevskii
78fbb0826b Clang: Fix fix-its positions calculation
Code completion does not save the unsaved file contents
in translation unit therefore we need to access unsaved
file directly to calculate the proper UTF-16 column.

Change-Id: I0f217b0d36e0ff94ebc483ed6bef94b55efd311a
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
2018-10-16 10:08:08 +00:00
Ivan Donchevskii
3e93f66c5d Clang: Fix SourceLocation column recalculation
Fix column conversion according to the fact that
columns are 1-based.

Change-Id: I75e9b966d96b9bb7648822b564e57f8838ebb3f8
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
2018-10-16 09:58:20 +00:00
Leena Miettinen
fac917b477 Doc: Describe the experimental language client plugin
Change-Id: I14e227a242dc101f9e535f56da52beddb5bc325a
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: David Schulz <david.schulz@qt.io>
2018-10-16 09:06:11 +00:00
Marco Bubke
2c885fa3d4 Clang: Split symbol storage
We need UsedMacros and source related statements in the PCH manager too,
so we have to split that class.

Task-number: QTCREATORBUG-21289
Change-Id: Ie27d4b518b3d6d9174e93fcb243fdb55a09ddf51
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
2018-10-16 08:57:00 +00:00
David Schulz
468dcc67cb LSP: remove unused LanguageChooseDelegate
Change-Id: I1003d96e603789a9c627d5ecffb6051722c0862a
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2018-10-16 08:52:27 +00:00
David Schulz
4a7051213b LSP: Create settings widget based on settings type
Change-Id: I4ecdfa386a33114a9d36d21e02ac5eecd9d8f3b7
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: David Schulz <david.schulz@qt.io>
2018-10-16 08:43:48 +00:00
hjk
f18176d6c0 ProjectExplorer: Remove Run{Control,Configuration}::abi
Unused now, and arguably not a valid concept anymore.
A run control may consist of different runworkers,
'operating' on different systems.

Since the removed RunConfiguration::abi() implementation uses
only public Target ABI, user code could revive that locally
in case it was needed again.

Change-Id: I658c6e88b4a1aec18bf4de91fc86230552bc0710
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2018-10-16 08:13:38 +00:00