Commit Graph

43591 Commits

Author SHA1 Message Date
Nikolai Kosjar
9d7b054120 CppTools: Fix potential race condition
...when acessing m_headerPaths, m_projectFiles or m_definedMacros from
different threads.

ensureUpdated() locked the mutex before writing the variables, but
reading them happened with an unlocked mutex.

Change-Id: I4951fd58f1939e4e50534a018dd600004789668e
Reviewed-by: Erik Verbruggen <erik.verbruggen@theqtcompany.com>
2015-11-09 12:10:14 +00:00
hjk
4bf0ca6beb Json: Avoid unneeded intermediate copy of key strings
Change-Id: Ieb2401810e4b47fab77b287e50e13b33160a9297
Reviewed-by: David Schulz <david.schulz@theqtcompany.com>
2015-11-09 12:09:26 +00:00
Leena Miettinen
309b2b843c Doc: context menu commands in the Navigator
Change-Id: Ibfe6702d410b13936e9512c22539c4b76efce839
Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
2015-11-09 10:47:10 +00:00
Tobias Hunger
a08cb7d52e FolderNodes: Specify filter for Add Existing Directory
Allow foldernodes to specify which files they care for when doing
"Add Existing Directory". Before we used a fixed list with C++ header
and source files, which does make no sense for e.g. adding to resources.

Task-number: QTCREATORBUG-15278
Change-Id: I15dad133391485c2bcebd2d864623304b31b5f8f
Reviewed-by: Niels Weber <niels.weber@theqtcompany.com>
2015-11-09 10:35:30 +00:00
Tobias Hunger
34b99de5b1 Wizard: Always prefer context node
Always choose the context node as the project node to add the new
file(s) to. This fixes adding new files to resource files.

Task-number: QTCREATORBUG-15277
Change-Id: I27f6d9dbb402c88413570a8198a005496f103c7b
Reviewed-by: Niels Weber <niels.weber@theqtcompany.com>
2015-11-09 10:35:19 +00:00
Christian Stenger
8cdc648139 Tests: Fix compilation
Change-Id: Ia63f3afd7ae3e76f78ffea31702ba5968b74b418
Reviewed-by: hjk <hjk@theqtcompany.com>
2015-11-09 10:11:49 +00:00
hjk
a4a9529403 Debugger: Make boost::container::list autotest pass again
... by adjusting the expectations on the exact type display
and trying two possible versions of structure member names.

Change-Id: I817aeb787b905cb22c6f68856043a29db3e79e59
Reviewed-by: Christian Stenger <christian.stenger@theqtcompany.com>
2015-11-09 10:08:20 +00:00
Eike Ziller
7be5ef0f5c At close: Fix that editors were removed even when canceling
Because the editor manager was asked first if it wants to
abort closing (because closing an editor failed), editors
were closed before any other close listener was asked.
Ask the editor manager last to avoid ending up with an
empty editor list when canceling for some other reason.

Change-Id: Ie56866cb668a717b7072d8092b4d86b7b3196d01
Task-number: QTCREATORBUG-14401
Reviewed-by: David Schulz <david.schulz@theqtcompany.com>
2015-11-09 10:03:46 +00:00
hjk
f81dca4b38 Debugger: Relax reference counter sanity check
With C++11 we use std::atomic in the ref counter, giving yet
another possibility of structure member names. Instead of
trying to keep up with that, access the binary data directly.

Change-Id: Iabea831689f58f83150287218bb015c824e888ca
Reviewed-by: Christian Stenger <christian.stenger@theqtcompany.com>
2015-11-09 08:44:58 +00:00
hjk
b8a8fe34a2 Introduce a Qt-free JSON implementation
This is essentially QJson with Qt replaced by std:: features.

This is useful to have in circumstances where a Qt dependency
is undesirable, e.g. for the Qt Creator debugger protocol
implementation in our CDB extension.

Change-Id: Iec79c6b23b1e717ce1b6f4d38755287d1f479c13
Reviewed-by: David Schulz <david.schulz@theqtcompany.com>
2015-11-09 08:25:11 +00:00
hjk
626086e9d1 Debugger: Fix expansion of std::string et al
The objects have been reported as 'having children', but
when asked for them nothing was produced, leading to an
endless loop (until the next 'step' command).

Change-Id: I3bbfe10a7ed980b27a5fca1edfe44dd8983b8f7b
Reviewed-by: Christian Stenger <christian.stenger@theqtcompany.com>
2015-11-09 08:02:32 +00:00
Eike Ziller
11f6162739 Themes: Fix issues with restoring themes.
Themes from the user config where not restored correctly.
Improve error handling when no themes are found
in case of broken installations.
Cleanly differentiate between theme "id" (currently complete basename of
theme file) and theme "displayName" (as specified as a property in the
theme file).
Remove convoluted broken code that tried to allow using an absolute file
path for a theme on the command line and require themes to be installed
either in Qt Creator globally or in the user settings path.
In general stream line the code.

Task-number: QTCREATORBUG-15113
Task-number: QTCREATORBUG-15233
Change-Id: I014a4314e8bea27422ed4c42462cf16f4220698b
Reviewed-by: Alessandro Portale <alessandro.portale@theqtcompany.com>
2015-11-06 19:37:16 +00:00
Sergey Belyashov
1bf1f58a9c Update Russian translation
Change-Id: I50d77ef6ae188deb7d0242ac7f8995c1febf3c56
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
2015-11-06 15:28:56 +00:00
hjk
e5e3243dd1 Debugger: Fix std::string display for GCC 5.x
Task-number: QTCREATORBUG-15110
Change-Id: Ic1bcdf1b73e0013068e56a5d8804da42cdb2c237
Reviewed-by: Christian Stenger <christian.stenger@theqtcompany.com>
2015-11-06 14:05:07 +00:00
Martin Kampas
9c6bcbcb77 Debugger: move sourcePathMap back to DebuggerStartParameters
It has been in use by the Mer plugin for per build-engine path
mappings.

This reverts bits of commit 244cdb7804
(Debugger: Split off runtime-only items from DebuggerStartParameters)

Change-Id: Ibba60443c52cedf51722bc71c4df67bee5f1ecec
Reviewed-by: hjk <hjk@theqtcompany.com>
2015-11-06 13:29:57 +00:00
Martin Kampas
9d49d8147c Core: Fix FancyToolButton initial visibility
This fixes the case when action is set not visible _before_ adding with
FancyActionBar::insertAction.

Change-Id: Ib59129532d74b8edf8ed8e83fc9bb13ad3b996fc
Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com>
2015-11-06 12:24:44 +00:00
Nikolai Kosjar
56f37f78b2 Clang: Speed up requesting diagnostics
Register the translation unit and request diagnostics from the
clangbackend as soon as the project part is determined. There is no
reason to wait until the parser is finished for the highlighter.

Change-Id: Iebccbf59ebd205389462dcee97363746fb651bb2
Reviewed-by: Erik Verbruggen <erik.verbruggen@theqtcompany.com>
2015-11-06 11:55:39 +00:00
Nikolai Kosjar
787b386ecc Clang: Use the fallback project part
...for project-less files.

Change-Id: I02d7e26bdd40dfce3b0663a07b591ee6beb2f6b7
Reviewed-by: Erik Verbruggen <erik.verbruggen@theqtcompany.com>
2015-11-06 11:55:28 +00:00
Nikolai Kosjar
2ca473d59e Clang: Print command line args for debugging
...if qtc.clangbackend.verboselib=true.

Change-Id: Ibba408db955892daf055b2050d810ce55b9d8913
Reviewed-by: Erik Verbruggen <erik.verbruggen@theqtcompany.com>
2015-11-06 11:55:12 +00:00
Nikolai Kosjar
23fa5a7efd Clang: Provide the language option to the backend
Provide the language option (e.g. "-x c++-header") when registering a
translation unit for the editor.

Task-number: QTCREATORBUG-14787
Change-Id: Ie06f9fdab302f1b21ba72cdb65b6aabf9f7bc04c
Reviewed-by: Erik Verbruggen <erik.verbruggen@theqtcompany.com>
2015-11-06 11:54:16 +00:00
Nikolai Kosjar
08fcb7f317 Clang: Filter out invalid diagnostic ranges
Apparently libclang might return invalid ranges.

Now we discard the invalid ranges. Since there is a diagnostic location
(in addition to ranges) the editor will still display an indication for
the user.

Task-number: QTCREATORBUG-15272
Change-Id: I351e136b9925a53fb2273a394e17873c5533798d
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
Reviewed-by: Erik Verbruggen <erik.verbruggen@theqtcompany.com>
2015-11-06 11:33:12 +00:00
Nikolai Kosjar
8f2ad8d246 Clang: Remove dead code
Change-Id: Ic81768748bb998d73906dcfc599a52f8c363f5b8
Reviewed-by: Erik Verbruggen <erik.verbruggen@theqtcompany.com>
2015-11-06 11:32:53 +00:00
Nikolai Kosjar
582494e68f Clang: Fix misleading function name
Change-Id: I60934867db6b61c8309a712db8a189d458a73ea7
Reviewed-by: Erik Verbruggen <erik.verbruggen@theqtcompany.com>
2015-11-06 11:32:47 +00:00
Nikolai Kosjar
d06aee195f Clang: Remove pointless function
Change-Id: Ib4cc26ca39f7ced993a9a4c142208c377d940719
Reviewed-by: Erik Verbruggen <erik.verbruggen@theqtcompany.com>
2015-11-06 11:32:42 +00:00
Martin Kampas
e26cce2b5a Core: Deduplicate FancyToolButton initialization
Change-Id: Iea178d2af7ab03e14a59745bc1bbe34e7d3294f1
Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com>
2015-11-06 10:58:57 +00:00
hjk
f58ab8d723 Debugger: Fix std::set<...>::iterator dumper for GCC 5.x and C++11
Change-Id: Icaca7da1f5ae6f958ae0fdaf217bde611d049916
Reviewed-by: Niels Weber <niels.weber@theqtcompany.com>
2015-11-06 10:08:48 +00:00
hjk
34196f510d Debugger: Add dumper for GCC 5.x's std::__cxx11::list
Change-Id: Idaf6692668210838488699dcab38d1517825bda3
Reviewed-by: Niels Weber <niels.weber@theqtcompany.com>
2015-11-06 10:08:05 +00:00
Martin Kampas
573c4988fe Remotelinux: Fix deploy config widget geometry
Change-Id: Ie550c0549b976bba3d50e39bee3b349867640c6d
Reviewed-by: Christian Kandeler <christian.kandeler@theqtcompany.com>
2015-11-06 04:44:27 +00:00
Eike Ziller
06d4e9318a sdktool: Fix that settings were written to wrong location
We needed to adapt the relative settings location to the new destdir:
sdktool moved from QtC/bin to QtC/libexec/qtcreator

Change-Id: I24152ea7ba6c0992941ad1750489ddc22f1767b0
Reviewed-by: Christian Kandeler <christian.kandeler@theqtcompany.com>
2015-11-05 14:58:20 +00:00
Sergey Belyashov
6ec3bcf866 Fix missing translations
Fixed some lacks of Q_OBJECT macro.

Change-Id: I226078baa40977ef49357b34b1e9dc5f0491d76a
Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com>
2015-11-05 14:41:56 +00:00
Marco Benelli
30ef3a3afc QmlJs: added a new test case in reformatter test.
Change-Id: I4f6c78cd9d2a2e407ef26e498418617efeee5bba
Reviewed-by: Erik Verbruggen <erik.verbruggen@theqtcompany.com>
2015-11-05 13:30:15 +00:00
Marco Benelli
b4e42171fd QmlJs: updated .pro file in fileformat test.
Change-Id: I1c6fb32820d8a5e58900c2812f43045bd588aff2
Reviewed-by: Erik Verbruggen <erik.verbruggen@theqtcompany.com>
2015-11-05 13:30:04 +00:00
Alessandro Portale
4db3209cd4 BinEditor: HighDPI fixes
The cursor drawing caused graphical artifacts under HighDPI.

Change-Id: I542346673ad8111ef03fbd80143de484fdb2d455
Task-number: QTCREATORBUG-15222
Reviewed-by: hjk <hjk@theqtcompany.com>
2015-11-05 12:41:58 +00:00
Leena Miettinen
12f1375f4e Doc: using Go to Implementation context menu command
Change-Id: I1fc905909e4d95934b0669a8d27801d6446548d6
Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
2015-11-05 10:14:58 +00:00
hjk
9d6c63d4d2 Debugger: Move the 'break on qFatal' implementation to gdbbridge
Easier to create invisible breakpoints there.

Task-number: QTCREATORBUG-15276
Change-Id: I76ffa45f9f0de5ffbc3b82a7ef9a4ddcdfff62eb
Reviewed-by: Christian Stenger <christian.stenger@theqtcompany.com>
2015-11-05 09:42:03 +00:00
Alessandro Portale
18365814ad Find: Add a HighDPI wrap indicator
Change-Id: Id31e779a98b3f048a42838590b6ace02c2b86bfd
Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com>
2015-11-05 08:46:19 +00:00
Ulf Hermann
b0771016fe QmlProfiler: remove dead code
Change-Id: Id1287ae6d756a317841dce58159899a0ac07fb86
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
2015-11-05 08:42:23 +00:00
Ulf Hermann
834883b0fb QmlProfiler: Support additional attributes of input events
Change-Id: I92a28d0476ad814601f33b76e508bdbea02eefff
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
2015-11-05 08:42:16 +00:00
Christian Stenger
db64434b40 ProjectExplorer: Fix compile with gcc 4.7.3
Introduced with e6a98f368e.

Change-Id: Ia8b67cc27e5a1b10f88cdc8e690270ebe1c72a55
Reviewed-by: hjk <hjk@theqtcompany.com>
2015-11-05 08:17:19 +00:00
hjk
e6a98f368e Core: Replace ICoreListener by std::functions
ICoreListener::coreAboutToClose() remains in the core,
ICoreListener::editorAboutToClose() is handled by a new
EditorManager::addCloseEditorListener() function.

This removes the need for some boiler plate code resulting
from the need to implement the interface in custom classes
(DesignModeCoreListener, EditorClosingCoreListener,
PojectEplorer::CoreListener and VcsBase::CoreListener).

EditorManager::addCloseEditorListener

Change-Id: Ie554c987b5455b555be6d77b77e4013639201d22
Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com>
2015-11-04 17:52:20 +00:00
Christian Kandeler
ed25b429f6 Fix qbs build for non-OS X platforms.
Change-Id: Iaa9a3d7ae713347b028e9414cff6028b957300c7
Reviewed-by: Jake Petroules <jake.petroules@theqtcompany.com>
2015-11-04 17:15:12 +00:00
Leena Miettinen
0d02544e67 Doc: text zooming in Application and Compile Output panes
Updated screen shots.

Change-Id: Id17908d3720aa4b7074f43169a09da05cd74eede
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2015-11-04 13:29:51 +00:00
Alessandro Portale
f4e5210cda app: Setting HighDPI environment variables
After b42bd585c4 there was
no automatic scaling of Qt Creator's UI with Qt 5.6 on non-OSX,
anymore.

This commit re-introduces it for Windows.

As a small bonus, now the environment variable is only set during
QApplication creation and unset afterwards. The run environments
are now not affected, anymore.

Change-Id: If0039df500d28a93c1ca8c2df9960992a010723f
Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com>
2015-11-04 13:07:02 +00:00
hjk
2b16b97f19 Debugger: Make DebuggerEngine::runCommand() virtual.
Allows default implementation of e.g. stack retrieval in the base
class.

Change-Id: I96460b19aa31347b2c863736b4ce2b5046eb4de6
Reviewed-by: Christian Stenger <christian.stenger@theqtcompany.com>
Reviewed-by: David Schulz <david.schulz@theqtcompany.com>
2015-11-04 11:48:05 +00:00
Christian Stenger
4ed5afba27 CppTools: Fix compile with gcc 4.7.3
Change-Id: I6a6f0a8ab065fb2c02373165a4b43d76f039d1f3
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2015-11-04 11:10:41 +00:00
Tobias Hunger
3febe4e7a2 Wizard: Stop summarypage from getting confused by similar project names
Do destinguish between /tmp/untitled1 and /tmp/untitled10.

Add some line-breaks while editing the file.

Change-Id: I49f9457bd43f188d4327fea3b84254ecb41ee7fc
Reviewed-by: Niels Weber <niels.weber@theqtcompany.com>
2015-11-04 09:10:15 +00:00
Tobias Hunger
e1ed5e4804 FileUtils: Replace FileNameList with an alias
The functionality in that class is covered by initializers and
Utils::unique, so there is no need to keep a custom class.

This way FileNameList plays way nicer with utils/algorithm.h.

Change-Id: I8eeae6aca0558ecd998920c4fdfc5ea56bf75501
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com>
2015-11-04 09:10:01 +00:00
Orgad Shaneh
45d9d08599 BareMetal: Fix translation context
Change-Id: Ia3a9a17bcbb5c8b7fb3fee903ec56f5f63414be2
Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com>
2015-11-04 08:51:20 +00:00
Tobias Hunger
1bb16ad6b5 Algorithm: Add filteredUnique
This methods returns a new container with only the unique elements
in the input container. Uses == for comparison of elements.

Change-Id: I80c2027b4d275d27343bd64851c17d42bc971e82
Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com>
2015-11-04 08:48:20 +00:00
Leena Miettinen
88818c1be1 Bare Metal: write "Bare Metal" as two words
...in the title of the Options page.

Change-Id: I081113e7982f730604a769f077f1de15c9185ca2
Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com>
2015-11-03 14:41:24 +00:00