Commit Graph

44349 Commits

Author SHA1 Message Date
Nikolai Kosjar
be3e12c8af CppEditor: Avoid auto insertion of '}' in empty line
...when typing '{'.

Change-Id: Ia1d3bcd7440c96ed3c8c1479148dd74d3d291689
Reviewed-by: David Schulz <david.schulz@qt.io>
2017-07-17 07:58:24 +00:00
Christian Kandeler
be2b3c91ae Add Q_FALLTHROUGH for Qt < 5.8
... and make use of it.
With gcc 7, the new option -Wimplicit-fallthrough is introduced and
added to the -Wextra set, triggering dozens of warnings in our sources.
Therefore, we annotate all obviously intended fall-throughs. The ones
that are still left are unclear and need to be checked by the respective
maintainer.

Change-Id: I44ead33cd42a4b41c28ee5fcb5a31db272710bbc
Reviewed-by: Nikita Baryshnikov <nib952051@gmail.com>
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2017-07-17 07:51:23 +00:00
Nikolai Kosjar
c9301e80bb Clang: Hide the # button in the editor tool bar
...since this is not yet implemented and confuses users.

Change-Id: I16e41f3308607aeaf1fb4a8d38ca276781c88952
Reviewed-by: David Schulz <david.schulz@qt.io>
2017-07-17 07:43:08 +00:00
David Schulz
635750aa11 Clang: delay text mark update
Reducing display of unwanted line annotations while typing in small
files.

Change-Id: I51864bbc3056ad792d5ee4b96f63e954dfba79dd
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
2017-07-17 07:14:06 +00:00
hjk
892026a619 ClangStaticAnalyzer: Compile fix due to unsubmitted dependency
This patch needs to be reverted later.

Change-Id: Ia120e225ec1086eca786f668999a48e5ee19ec7e
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2017-07-14 15:41:08 +00:00
hjk
ca660c796c ClangStaticAnalyzer: Fix rampdown
Stop button wasn't doing anything.

Change-Id: I84f3d5dccdbdd5a7a800ecc86c3938b01eaa0550
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
2017-07-14 13:11:30 +00:00
Eike Ziller
9b000b7b80 Merge remote-tracking branch 'origin/4.4'
Change-Id: Ia013f44f432d9c4dcc2e9626b9b3c9d7fa84b623
2017-07-14 14:24:25 +02:00
Christian Kandeler
1f04804e6e Update qbs submodule
To HEAD of 1.9 branch.

Change-Id: I7995a3361ee7c15d8c9bfbe55afea878759be961
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2017-07-14 11:27:05 +00:00
Ivan Donchevskii
5a7a64b37d Completion: improve complete in the middle
Backport the master commit (cherry-pick).
Apply clang fix to the old code model
Do not replace the text after cursor if
the proposal does not contain it or
if proposal matches 100% the text after it

Task-number: QTCREATORBUG-18471
Change-Id: I10c90580d46d2d2c899dc1ed8fe4d7df0531691a
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
2017-07-14 10:03:48 +00:00
hjk
6a44992050 Make ApplicationLauncher report QStrings, not QByteArray
Realistically, we only have UTF-8/plain ASCII messages, and if not then
the conversion should happen when the message enters the "creator eco
system" as there's potentially information on the actual encoding
present, not at some random consumer further down the chain.

Change-Id: Ie21199b99255f5c4d28fce3da7db2fd6c3bcfb3a
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2017-07-14 09:27:58 +00:00
Eike Ziller
5ac8193ec6 Merge remote-tracking branch 'origin/4.3' into 4.4
Change-Id: I0e624a7ff494985966c24c0989fe20df585f86a0
2017-07-14 09:23:21 +02:00
Eike Ziller
4388b5b6cd Help: Remove unnecessary class
By using connect to a function directly.

Change-Id: Iab06810203720f26eba908293438a6d12631ea15
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
2017-07-14 06:46:36 +00:00
Orgad Shaneh
5299b81a4d Debugger: Fix typo and a missing newline
Change-Id: I220e4e6c185ab74b07575260c886d4e962b75137
Reviewed-by: hjk <hjk@qt.io>
2017-07-14 06:19:55 +00:00
Orgad Shaneh
023edafe4c Debugger: Fix copy-and-pasto in qmlDebugging
Change-Id: I89af5e4cc555457d4b55cd94049175618dc059d8
Reviewed-by: hjk <hjk@qt.io>
2017-07-14 06:19:26 +00:00
Orgad Shaneh
b710f79bef Debugger: Reduce one call to runnable()
Change-Id: I8e0ce18fa65a3281fcadf9b5a8ffb4008a0cf294
Reviewed-by: hjk <hjk@qt.io>
2017-07-14 06:19:09 +00:00
Orgad Shaneh
7327bb3537 Debugger: Fix engine name in start message
Change-Id: Iaf3bf66b5347093f1898f58f140a47fbc77fada5
Reviewed-by: hjk <hjk@qt.io>
2017-07-14 06:18:54 +00:00
Orgad Shaneh
b207ef447d Debugger: Sort settings in dump
It's a hash, it has random order.

Change-Id: I6ae90b0d175a8a398f7a774deb25a8e5b5c46c62
Reviewed-by: hjk <hjk@qt.io>
2017-07-14 06:18:38 +00:00
Orgad Shaneh
365e747a11 Beautifier: Add accelerators to menu items
Change-Id: Ie94b09ed640df457235be6b8a145d953c4eca03e
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: André Hartmann <aha_1980@gmx.de>
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2017-07-13 19:00:12 +00:00
hjk
96a0d01196 RemoteLinux: Implement FifoGatherer::stop()
... instead of onFinished(), which is on its way out. Should be the
right think in theory and not make a difference in practice as
the code appears to be unused right now.

Change-Id: I5ef415fc0fab8902e8e31e75354a5943d99b2182
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2017-07-13 15:47:51 +00:00
Tobias Hunger
7b0166a6a4 Modeling: Do not crash on invalid qmodel files in a project
Task-number: QTCREATORBUG-18526
Change-Id: I2947f9227c6f96b2b576ca6e942c3f27f28116b3
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
Reviewed-by: Jochen Becher <jochen_becher@gmx.de>
2017-07-13 14:51:21 +00:00
Nikolai Kosjar
3cd8ddc966 CppEditor: Remove invalid QTC_CHECK
For the Clang Code Model, this assert is not valid as it does not
require the semantic info.

Change-Id: Ia28253354baa531c620c1bd4dead16ef88a95f1b
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
2017-07-13 13:24:35 +00:00
Eike Ziller
6afc0c3eb6 Help: Add method for showing URL in specific viewer
That centralizes all the focus setting, raising of windows, etc. This
was for example already done wrong when opening links in help mode and
external window.

Change-Id: I5036b5caa751d1f36dc442078624a31fb8f573ee
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
2017-07-13 10:49:16 +00:00
Eike Ziller
be3dbd4c53 Help: Do not unnecessarily open help mode
When using the "Web Search" locator filter ('r') or "Get Help Online"
from the context menu on build errors in the issues pane, we already
know that we want to show the URL in an external browser, not help mode.

Task-number: QTCREATORBUG-17795
Change-Id: Ie7faa527907124251a60e7618747d81a6003fa19
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
2017-07-13 10:06:07 +00:00
Christian Kandeler
0e2b89e637 QmlProfiler: Fix release build
A header file was indirectly included in debug mode.

Change-Id: I9142fc9b92fd6db1182c6602a0ac4a723aa2c9f7
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2017-07-13 08:50:56 +00:00
Eike Ziller
f3e1b6bb6e Merge remote-tracking branch 'origin/4.4'
Change-Id: Idfb9177bc09e4db0b5750832f119fa5e19d74c29
2017-07-13 09:47:07 +02:00
hjk
611f373df6 QmlProfiler: Partially dissolve QmlProfilerRunControlFactory
Change-Id: Id902cfa6387bcb6ad96da0cd36f3114f795afd99
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2017-07-13 07:31:12 +00:00
Eike Ziller
c8affd6e74 Help: Remove trivial slots
Use one-line lambdas

Change-Id: I85d1fe33283b6c517a1942d833d6b127002540f5
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
2017-07-12 14:07:00 +00:00
Kai Koehne
2eb83100ff ReadOnlyFilesDialog: Hide 'What's this' button on Windows
Change-Id: Id0f9a8ca3d0e395e46d6f7a4c01c6a33d1bc7688
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2017-07-12 12:43:00 +00:00
Eike Ziller
d614131bef Help: Fix setting focus to help viewer
Change-Id: Ie846d6996298b74a4b55c359787fd4f63b471cdf
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
2017-07-12 12:35:22 +00:00
Eike Ziller
ed850a7934 Fix build on macOS with Qt 5.6
Change-Id: I6d189aa17c43d740115cbaa5f410059f364b82d5
Reviewed-by: Jake Petroules <jake.petroules@qt.io>
2017-07-12 10:29:02 +00:00
hjk
0a2032e434 ProjectExplorer: Rename RunControl::finished to stopped
That's what it is.

Change-Id: I8cf9af23bb7cafe1cde8f165fdbf85cdeb79f7e4
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2017-07-12 10:06:34 +00:00
hjk
9e67a9453a Debugger: Use a somewhat less intrusive hack for 'start at main'
Change-Id: Ie649a4a11c88f3686cd6ed1e73f34c7c78fd0e13
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2017-07-12 09:45:28 +00:00
hjk
5868c1e53b ProjectExplorer: Remove unused RunWorker functions
Change-Id: If5d7368cf46b789c80162271cb6e71ebaae1548e
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2017-07-12 09:10:00 +00:00
Eike Ziller
d522ec373f Merge remote-tracking branch 'origin/4.4'
Change-Id: Iec15792ab28b3d34234d8e564a8ee33808772fa8
2017-07-12 10:52:25 +02:00
Eike Ziller
5a1a20f2ee Merge remote-tracking branch 'origin/4.3' into 4.4
Change-Id: Ifb1dcc847ba4b32a79b349955fad5207e402cb7b
2017-07-12 10:50:49 +02:00
hjk
cdca4bd9df Qnx: Prefer SimpleTargetRunner::setRunnable over RunControl::*
RunControl::setRunnable is meant to go in the long run, individual
RunWorkers are better suited to handle their needs (and only their
needs) than trusting a one-Runnable-fits-all-workers-in-RunControl
setups.

Change-Id: I6bdb32cc69581503dd252af83b75428c0de2f648
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2017-07-12 08:22:30 +00:00
hjk
7a64a73c4e Debugger: Remove unneeded friend and member
Change-Id: Idf5297b2b29f74722bfc7f8ae1b1aa7e6de92f90
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2017-07-12 08:22:14 +00:00
Thomas Hartmann
16e5b61880 QmlDesigner: Turn FormEditor item into QGraphicsItem
QGraphicsObject is a QObject and significantly heavier
then QGraphicsItem. There is no need to use
QGraphicsObject in our case.
Using QGraphicsItem instead is simply good practice.

Change-Id: I65f9db85eace25fd0e7873093e903d923eb338dc
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-07-12 07:25:11 +00:00
Thomas Hartmann
fde2bc2571 QmlDesigner: Show message box if StatesList.qml cannot be created
I also removed the hard assert.

Change-Id: Ia15d9f82fb63e7d8dd6acf8547b9e96bad838d3f
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-07-12 07:24:51 +00:00
Thomas Hartmann
1789422de8 QmlDesigner: Check for qmldir of QtQuick.Controls
If QtQuick Controls 1 are missing there is no reason to
build QmlDesigner.

Change-Id: Ic8777fef6addc460b05c8218d96aa13379f02cea
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-07-12 07:24:41 +00:00
Orgad Shaneh
d294f91758 main: Remove unused variable
This amends commit a6c17fc537.

Change-Id: I365513a9e11e6c07310799f87a4e299cd110dcf3
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2017-07-11 20:28:26 +00:00
Orgad Shaneh
2a197ed9bf Revert "App: (Re-)enable automatic HighDPI scaling for Linux"
It breaks running over PuTTY with VcxSrv.

This reverts commit 36c8227caf.

Task-number: QTCREATORBUG-18467
Change-Id: Id93497ee24cdb574d1e4a1ac1b0fb112012a695d
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2017-07-11 20:28:14 +00:00
Jochen Becher
05f7b92f0a ModelEditor: Introduce QMT_ASSERT
This change shall solve a lot of Coverity findings

Change-Id: I1e699f7363426e9b6008fc77d3f498fe3d968b4f
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2017-07-11 20:17:55 +00:00
Jochen Becher
8ccdbe1944 ModelEditor: Satisfy Coverity using Q_UNRECHABLE
If I remove the switch cases gcc produces a warning. Coverity recognizes
the cases as dead code and produces a finding. Maybe Q_UNRECHABLE is
modeled in Coviery to suppress dead code issues.

Change-Id: Idae2c088ba95b3e00cb4ef788d075fe7e0d4b6a5
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2017-07-11 20:17:46 +00:00
Jochen Becher
706b0874f5 ModelEditor: Fix a number of trivial coverity issues
Change-Id: Ie61e017b993ac788284611fb40052e5f59521a56
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2017-07-11 20:17:28 +00:00
hjk
0d06dbb5b2 BareMetal: Dissolve BareMetalRunControlFactory
Less code.

Change-Id: Ie3bd75557e4f4b5acff65a9b3a074692ea652253
Reviewed-by: hjk <hjk@qt.io>
2017-07-11 16:06:08 +00:00
Hannah von Reth
ada1429594 Introduce setPerspectiveEnabled
This enables us to mark perspectives as disabled.

Change-Id: I52b2434f33f8550b6d2459f915dfd8cdb1389140
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: hjk <hjk@qt.io>
2017-07-11 15:38:49 +00:00
hjk
82f8cb70e6 WinRT: Dissolve RunControlFactory
Less code, and it's what most other targets do nowadays.

Change-Id: I2cf55d1a32ad10427ce2508536d03bca8921b451
Reviewed-by: David Schulz <david.schulz@qt.io>
2017-07-11 14:57:16 +00:00
Ivan Donchevskii
550ed2927d C++: fix lookups for functions with const args
Make declarations equal in case they differ only
by argument const and/or volatile (13.1.3.4).

Task-number: QTCREATORBUG-18475
Change-Id: Id0561fda3b9081b92716a8739ba9963e90b5d709
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
2017-07-11 13:38:56 +00:00
hjk
20b6ccd23b Locator: Add a virtual destructor to BasicLocatorFilterTest
Change-Id: Ic5947003945d4cfc87484106052e98e06e4e700a
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
2017-07-11 12:54:07 +00:00