Commit Graph

44349 Commits

Author SHA1 Message Date
Tobias Hunger
15ac730438 ProjectImporter: Generalize handling of temporary data associated with kits
Generalize handling of temporary Qt versions, etc. that is associated with
temporary kits while importing projects.

Change-Id: I16a0c2e7f32546e131dcbeddc7a1e5048a9ad4c8
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2016-09-15 09:27:12 +00:00
Tobias Hunger
b07f92abc9 QmakeProjectImporter: Split up import method
Split up the import method into several smaller methods. Call these
from ProjectImporter::import, which now contains the build system
independent parts, moving all the build system dependent code into
the smaller methods.

This will allow to reuse logic for cmake project import.

Change-Id: Idcd1d1daaab18ebcc581cc5aff3f20c7757c639b
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2016-09-15 09:25:11 +00:00
Tobias Hunger
b5c3b3159c BuildInfo: Fix operator == to work better with subtypes
Different buildconfigurationfactories will always return different
BuildInfo, as the factories will turn the information into a different
set of objects (even if the information those objects are created from
are identical).

Each factory will always produce the same (sub-)type of BuildInfo, as
they need that information to proceed. So using the factory-address
as a kind of type-identifier is save.

Change-Id: Ia30355c26e045d453c0c2b75da893a4bac38b048
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2016-09-15 09:21:26 +00:00
Eike Ziller
32468cf0ec Fix build with MSVC 2015 Update 2
Complains about the constexpr otherwise.

Change-Id: Idb64ed3287b8f9506a811a091dd1ad8ae11b2ad8
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2016-09-15 09:21:15 +00:00
hjk
022120658d Debugger/Utils: Fix index passing of ItemViewEvents
... are restore 4.1 double click behavior in breakpoint view.

Change-Id: If211b9708c0173e940e4b02a9b7b27f4ed78c868
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2016-09-15 09:15:45 +00:00
Marco Bubke
7f8acd8fda TextEditor: Fix spelling
Change-Id: Iff98ad30bf857c9c4799bdea1aa69cb24ec7f356
Reviewed-by: David Schulz <david.schulz@qt.io>
2016-09-15 08:51:27 +00:00
Tobias Hunger
ffedf95ef5 ProjectImporter: Move logic to select preferred target into base class
That way the code can be reused in other importers later.

Change-Id: I6318f9c959b73b2af2692408b918eb1fab715137
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2016-09-15 07:55:38 +00:00
Tobias Hunger
6281d7c4c9 QtSupport: Introduce QtProjectImporter
Introduce a base class for importing Qt projects. This class handles
the handling of temporary Qt versions.

Use this in the QmakeProjectImporter.

Change-Id: I2e540f9bb75d607a68d1277db68243b04eee168f
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2016-09-15 07:55:34 +00:00
Tobias Hunger
52326f1e82 ProjectImporter: Clean up APIs, move more code into Base class
Change-Id: Ida7aae846888efb3c9da456a83db5a90256bf7d5
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2016-09-15 07:55:30 +00:00
Ulf Hermann
d5cdbf8baf Debugger: Avoid duplicate dock actions in Window->Views menu
The dock actions are already in the M_WINDOW_VIEWS container.

Change-Id: Ib71430818252711d7a97d6890b85ad6dd38c7134
Reviewed-by: hjk <hjk@qt.io>
2016-09-15 07:48:08 +00:00
David Schulz
015e12a72a Cdb: Fix Qt4 QMap dumper
The expanding depth of variables is limited in cdb. Instead of expanding
the linked list inside qmap add a new symbol for each child node.

Task-number: QTCREATORBUG-16212
Change-Id: I89a288c92d9168a54afcf2cdb8c8b8a6dd98a3b4
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2016-09-15 07:27:46 +00:00
David Schulz
6b112c1b04 Cdb: Introduce SymbolGroupChildInfo
Holds the offset and type of a symbol ancestor. This information is
cached and used to collect data directly via offset instead of expanding
known symbols.

Change-Id: I0c08f6911dfbb6016c4bb12cb6325be873c6000a
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2016-09-15 07:27:27 +00:00
Kudryavtsev Alexander
21dc290360 Nim: Fix build configuration factory priority
Change-Id: I3cdae467f14bf4fa76c3a477a715271a3d7f353b
Reviewed-by: Filippo Cucchetto <filippocucchetto@gmail.com>
Reviewed-by: hjk <hjk@qt.io>
2016-09-15 06:35:22 +00:00
Vikas Pachdha
1787d00e6e Continue process after lldb attach
lldb stops the process after attaching and the event loop is not yet started.
This makes the debugger wait for events while process is in stopped state

Task-number: QTCREATORBUG-15705
Change-Id: Iae6fe94fc483d963b377582c4cbbb443be5e6cba
Reviewed-by: hjk <hjk@qt.io>
2016-09-14 14:17:40 +00:00
Christian Stenger
95fa0e397b Debugger: Fix detection of lldb via xcrun
Change-Id: If91efbd1d7a3e01440a3ed5ee0172975c2b0eff1
Reviewed-by: hjk <hjk@qt.io>
2016-09-14 13:28:04 +00:00
Nikolai Kosjar
cb0e730bb5 Clang: Clean up exceptions
* Extract common stuff into the base class ClangException
* Remove unused exceptions TranslationUnitParseErrorException and
  TranslationUnitReparseErrorException
* Do not send error messages to the Qt Creator side. The messages were
  only generated when the backend crashed and while it was not yet fully
  re-initialized (e.g. do code completion right after crash where the
  document was not yet registered at the backend).

Change-Id: I91d98d5ef681ad487f7a2fd66f78fa7cd1e958df
Reviewed-by: David Schulz <david.schulz@qt.io>
2016-09-14 13:08:08 +00:00
Nikolai Kosjar
26cb17bb65 Clang: More renaming fixes
Change-Id: If796869b26fc6faf5919041368fb26e8a42ae8a2
Reviewed-by: David Schulz <david.schulz@qt.io>
2016-09-14 13:08:04 +00:00
Nikolai Kosjar
9606988989 Clang: Move exception classes into single header/source unit
Change-Id: I60b4ce61e46d6f4ba87a2be49e6bbc219508c471
Reviewed-by: David Schulz <david.schulz@qt.io>
2016-09-14 13:07:56 +00:00
Tobias Hunger
dfbb0b64b9 CMake: Improve cmake setup on Apple
Users tend to select cmake.app, which is actually a GUI for cmake and
not what Creator expects. So check for the proper binary in the bundle
and return that if it exists.

Change-Id: I1668baa6236ee4ae88da200cef257b636f7a9e72
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2016-09-14 12:40:22 +00:00
Christian Stenger
6f963fd56e Utils: Fix logic in TemplateEngine and adjust auto test
Broke with 8641277121.

Change-Id: I49174428bf940ef4c3fa7f6ebd3124a907a555b8
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2016-09-14 12:34:31 +00:00
hjk
734c348700 ProjectExplorer: Some polishing of the new ProjectWindow layout
This moves all non-Build&Run entries under a separate 'Project settings'
entry.

Internally, this mainly makes the information flow on what item a user
selected and in which direction in the tree information needs updated
a bit more explicit.

Change-Id: I4583151356ef50b244b1d05dd77f04de2355105f
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2016-09-14 12:31:12 +00:00
Orgad Shaneh
129591cb52 Utils: Add constexpr to most functions in HostOsInfo
Change-Id: If45cc91e0ae4061e01e3540e1867b08bffbe5774
Reviewed-by: Daniel Teske <qt@squorn.de>
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2016-09-14 10:50:29 +00:00
Orgad Shaneh
074b61c3a7 Core: Replace preprocessor with HostOsInfo
Change-Id: I2f227277fc52df3e4902ea24838f7601dfb84014
Reviewed-by: Daniel Teske <qt@squorn.de>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2016-09-14 10:10:20 +00:00
Eike Ziller
b547b5b078 Help: Remove QtWebKit backend
QtWebKit is gone, removing it is better than letting it rot.

Change-Id: Ie0a43f9aed028edb76b2e9f2dac0b4a9be8ce05d
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2016-09-14 10:07:39 +00:00
Marco Bubke
d1a155f737 Clang: Make ClangString inline
ClangString is called many times so inlining the thin wrapper brings
little performance advantages without any disadvantages.

Change-Id: Ieb1229cf8e81ed3fda859254230df14d56c405ca
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
2016-09-14 09:45:20 +00:00
Ulf Hermann
6b79bba985 QmlProfiler: Don't accept compile events in memory usage model
As compiling happens asynchronously it messes up the stack based
approach used to attribute memory usage to QML/JS events. Compiling
generally doesn't use the JavaScript heap, so we can ignore it here.

Change-Id: If8cc4b0ad2b8c2e0531260a8b92b7e2cd76a6d56
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
2016-09-14 08:36:24 +00:00
Ulf Hermann
257d1990c6 QmlProfiler: Don't handle type IDs in memory usage model
Events in the memory usage model should not be selected when a type
ID is propagated from the statistics or flame graph model. The event
in the respective QML/JS model should rather be selected.

Change-Id: I6646358650f61c424c607e9dd8edb7fd9a61597e
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
2016-09-14 08:35:17 +00:00
Ulf Hermann
fbb45e5a57 QmlProfiler: Keep Compiling events separate in flame graph
The QML compiler can run asynchronously and produce ranges that don't
match up with other QML/JS ranges. The flame graph model assumes that
all ranges are perfectly nested, and produces incorrect data if they
aren't. The compile ranges are perfectly nested among themselves, and
the other QML/JS ranges are also perfectly nested among themselves, so
we can fix this by keeping separate stacks for them.

Change-Id: If4ea251c6a2e74bd04e142cf184937600ea31a87
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
2016-09-14 08:34:47 +00:00
Ulf Hermann
0eb1301b5c QmlProfiler: Don't lie about the debug messages model's row count
The previous code would crash in the renderer if the type id is smaller
than the detail type of the message. That is rare, but can happen.

Change-Id: I7702284bc61a7c9227c7ad81ecf714255db5db9f
Reviewed-by: Michael Winkelmann <Michael.winkelmann@qt.io>
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
2016-09-14 08:04:44 +00:00
Orgad Shaneh
0db572a739 Fix compilation
setSettings is used in GdbTermEngine, but not declared at all on
Windows.

Change-Id: I1d19e302f1761f8502b4c16b75f8cad34b4d7b3b
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2016-09-13 11:15:07 +00:00
Eike Ziller
478377d880 Merge "Merge remote-tracking branch 'origin/4.1'" 2016-09-13 10:15:56 +00:00
Eike Ziller
c635c6b50a Merge remote-tracking branch 'origin/4.1'
Conflicts:
	share/qtcreator/qmldesigner/propertyEditorQmlSources/HelperWidgets/ExtendedFunctionButton.qml
	src/plugins/android/androidrunner.cpp
	src/plugins/debugger/debuggerruncontrol.cpp
	src/plugins/qmlprofiler/qmlprofilerstatisticsmodel.cpp
	src/plugins/qmlprofiler/qmlprofilerstatisticsmodel.h
	tests/system/suite_WELP/tst_WELP03/test.py

Change-Id: Ibac4d71d4f4dbe1e4f05052d2f8a2dcfd82edd4c
2016-09-13 12:15:09 +02:00
Orgad Shaneh
d0341214b6 Debugger: Add QTC_CHECK define
Used in some comments, but not in live code.

Change-Id: I1fc0301c1864fba541a27b4d77708e44231c0a2f
Reviewed-by: hjk <hjk@qt.io>
2016-09-13 10:05:11 +00:00
Orgad Shaneh
88aa956bb7 Get rid of Utils::sleep
Replace with std::this_thread::sleep_for()

Change-Id: I3a02fa6d4fc1b41d8d7b01bb3ba0342ce49b8e61
Reviewed-by: BogDan Vatra <bogdan@kdab.com>
Reviewed-by: Vikas Pachdha <vikas.pachdha@qt.io>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2016-09-13 10:04:55 +00:00
Nikolai Kosjar
8edda219d9 Clang: Remove superfluous try/catch
Change-Id: I7e1cd9fb6d80461518c0c52a8274f689c595dcd7
Reviewed-by: David Schulz <david.schulz@qt.io>
2016-09-13 08:18:56 +00:00
Nikolai Kosjar
622109193d Clang: Remove unused enum 'SendMode'
Change-Id: Ia95aface60d6f00db5e38d28fc3bf2a3fd7d4406
Reviewed-by: David Schulz <david.schulz@qt.io>
2016-09-13 08:18:42 +00:00
Orgad Shaneh
d407dfac65 Debugger: Replace macro usages with HostOsInfo
Change-Id: I6c42e20d7ef5596577a8b13737aba64b7783b7bd
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2016-09-13 05:38:47 +00:00
Alessandro Portale
061582681c ClangRefactoring: Fix Msvc warning
clangrefactoringplugin.cpp(51): warning C4138: '*/' found outside of
comment.

Change-Id: I0cda4e07e43ece2ec24ebb130394ac007d6e7646
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2016-09-12 16:05:31 +00:00
Orgad Shaneh
8d14f76c10 Gerrit: Support pushing initial commit for review
Enable manual selection of target branch on this case.

Task-number: QTCREATORBUG-16780
Change-Id: I925ceef52ec56ebf77abcee58065c7b8afcc0854
Reviewed-by: André Hartmann <aha_1980@gmx.de>
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2016-09-12 14:21:07 +00:00
Orgad Shaneh
5b49ed506b Git: Return empty list for remote branches when there are none
The function currently returns "<Detached HEAD>"

Change-Id: I68786d5521549aacc29807632a5054593db24b3b
Reviewed-by: André Hartmann <aha_1980@gmx.de>
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2016-09-12 14:21:02 +00:00
Eike Ziller
181a17bbdc Output pane: Fix that height setting could reset
When opening Qt Creator, and closing it without showing an output pane,
it would write a height of 0 into the settings.

Task-number: QTCREATORBUG-16829
Change-Id: Ia8ab0cea6620c4e654060f92f51bd5f0ce10e6b9
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2016-09-12 13:53:04 +00:00
BogDan Vatra
5c34c678f5 Android: API-24 is not unknown anymore
Change-Id: Id0ce6b1fb289e356985d388f4843cffa24ddd77b
Reviewed-by: Vikas Pachdha <vikas.pachdha@qt.io>
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2016-09-12 13:44:14 +00:00
Tobias Hunger
e57f8e9038 GccToolChain: Redetect ABIs if the targetAbi is invalid
Fixes issues with broken ABIs in the settings, like you get when going
from QtCreator 4.2 to 4.1 and back.

Task-number: QTCREATORBUG-16823
Change-Id: Ibcab5d3bc8255dfeb647e512f5db1d94155f9d9a
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2016-09-12 13:42:53 +00:00
Orgad Shaneh
b8c99a66b3 QmlJS: Replace macro usage with HostOsInfo
Change-Id: Ie1e7c5eb5a5f700ae63b4bcc6c1a9b1a4ed7a426
Reviewed-by: Marco Benelli <marco.benelli@qt.io>
2016-09-12 13:21:03 +00:00
Tobias Hunger
3f80732dfb ProjectExplorer: Export AnsiFilterParser
Task-number: QTCREATORBUG-16848
Change-Id: Ic04a156bd95b1a6ec95e8c49dfebd765e53ff903
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2016-09-12 12:13:18 +00:00
Marco Benelli
cc996134de QmlJs: more informative warning message for Javascript
The warnings for Javascript follows the rules of JsLint, that can be
non-obvious to the user.  This patch add a reference to the relevant
section in QtCreator documentation.

Task-number: QTCREATORBUG-16771
Change-Id: I64ce331c6adf4b45c2510e35d68a6ce7e37ed6d5
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
2016-09-12 12:00:07 +00:00
Marco Benelli
aecc590390 qmljs: use QRegularExpression to parse imports.
Use a regular expression to get the module name, major version and
minor version from a string representing the module import.

Change-Id: I99f85ff4844cdfba142b45b4881241a1d40b772e
Reviewed-by: Erik Verbruggen <erik.verbruggen@qt.io>
2016-09-12 10:29:58 +00:00
Eike Ziller
e4e30b24e0 Help: Fix online documentation path
When trying to open pages that should be in the installed documentation,
but are not, we try to open the page from the online documentation in
the external browser (e.g. for the links from Welcome mode). Looks like
the online documentation moved.

Change-Id: I7a8eaf37783661dc4751a12b65efeac419d3a802
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2016-09-12 09:10:03 +00:00
Orgad Shaneh
f22e8d6fea QmlDesigner: Replace macro usage with HostOsInfo
Change-Id: Ic9ee44be3fd1c67fd24c53046e578b59bd44ccec
Reviewed-by: Thomas Hartmann <Thomas.Hartmann@theqtcompany.com>
2016-09-12 07:40:25 +00:00
Orgad Shaneh
37a90653f9 Autotest: Replace macro usage with HostOsInfo
Change-Id: I5f9626ff13d49611b2dd000ba0311823a18b5867
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2016-09-12 07:34:29 +00:00