Commit Graph

1003 Commits

Author SHA1 Message Date
Eike Ziller
8e51295959 Merge remote-tracking branch 'origin/5.0'
Conflicts:
	src/libs/utils/processreaper.cpp
	src/plugins/clangcodemodel/clangmodelmanagersupport.cpp
	src/plugins/cmakeprojectmanager/cmakeprocess.cpp

Change-Id: Ie248bcb02a80f3e02ab19d73033ce2ba31e7fd83
2021-09-07 11:05:40 +02:00
Thomas Hartmann
1393aa8505 QmlProject: Open the first .ui.qml file in QDS
Open the first .ui.qml file of a .qmlproject to not
confuse users.

Task-number: QDS-4986
Change-Id: I56c77c2101fd549cb7b96ea7d273bb4f5234693a
Reviewed-by: Aleksei German <aleksei.german@qt.io>
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2021-09-06 11:57:53 +00:00
Artem Sokolovskii
bf2954ffbf Qml: Use QtcProcess
Change-Id: I12ff58739db14952bdf38355f0fe3b332f57f330
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2021-08-31 09:56:59 +00:00
hjk
30f171a491 Utils: Rename FilePath::normalizePathName to normalizedPathName
Change-Id: Ib7bcc9968749649f762a396d3861f7b67711e926
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2021-08-26 07:03:13 +00:00
hjk
db014de91c Utils: Introduce FilePath::normalizePathName()
... as wrapper around FileUtils::normalizePathName, and use it
in some places.

Change-Id: I42792e1f175b8119c8db930eae80a9f822ac70fa
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2021-08-23 10:37:26 +00:00
hjk
2f0219928d ProjectExplorer: FilePathify IDevice::qmlRunCommand
And remove a few unnecessary namespace qualifications nearby.

Change-Id: Iea866c98f13fe02e1ce29b855632beeaeeb8cd4f
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2021-08-17 10:17:50 +00:00
hjk
7c28c4f744 Utils: Introduce a FilePath constructor from char arrays
Similar to QT_RESTRICTED_CAST_FROM_ASCII to avoid the need for
decorations in user code.

At the same time, drop some convenience constructors and functions
in CommandLine and Icon essentially serving the same purpose.

Change-Id: Ida4e5ac19c2da0a4298a97b2a8e1511d56bbb79d
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2021-08-17 05:34:10 +00:00
Eike Ziller
c7168d1063 Merge remote-tracking branch 'origin/5.0'
Conflicts:
	src/plugins/coreplugin/locator/executefilter.cpp

Change-Id: Iff5b82a9e491b782e4720138904f389d318b005c
2021-08-11 10:10:51 +02:00
hjk
4a42bcd4e8 Utils/ProjectExplorer: Use FilePath for Runnable::workingDirectory
... and in some using code.

Change-Id: I231ea56628908f7d305d13f07eabe8803fe8a791
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2021-08-06 12:51:24 +00:00
Thomas Hartmann
4a4e124b07 QmlProject: Add simple way to change between Qt6/Qt5 kits
The feature is only available in QDS mode.
This adds a combobox to the run configuration which allows
the easy selection of a Qt 5 or Qt 6 kit.


Task-number: QDS-4733
Change-Id: I53fae9fe4bc415e5b1e8d385ef85ed81b8010b3a
Reviewed-by: Henning Gründl <henning.gruendl@qt.io>
2021-08-03 20:24:31 +00:00
Thomas Hartmann
9b17a2b283 QmlProject: Prefer Qt 6 kits if the project is flagged as Qt 6 project
A .qmlproject can contain 'qt6Project: true'. If this is the case
we prefer a Qt 6 kit, otherwise we prefer a Qt 5 kit.

We only change this behavior if Qt Creator is in QDS mode.

We should prefer desktop kits in any case.

Task-number: QDS-4734
Change-Id: I90f6628cd071db01f2add068fd776774f7be133e
Reviewed-by: Henning Gründl <henning.gruendl@qt.io>
2021-08-03 20:24:21 +00:00
Thomas Hartmann
58602ec21c QmlDesigner: Add setting for Qt 6 projects
Adding
'qt6Project: true'
to the qmlproject file marks the project as Qt 6 'only'.

Task-number: QDS-4734
Change-Id: Ib9d969fd11d409e280734f9bedf759b40470fc61
Reviewed-by: Henning Gründl <henning.gruendl@qt.io>
2021-07-27 15:32:29 +00:00
hjk
1bde4ddbec ProjectExplorer: Use FilePaths in project tree nodes
Change-Id: I31b15c428d9b962333947b1e32641fd80f61d069
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2021-07-16 13:45:06 +00:00
Tim Jenssen
22121885fe baseqtversion: commands are FilePathes
also renamed the qmlscene* qmlRuntime*

Change-Id: Ifd522e21f5ce30aaa54060fdcebee2cd8b9463c4
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2021-07-14 09:50:01 +00:00
Tim Jenssen
453f4996db use "qml" as QML runtime
Since Qt 6.2 qmlscene is deprecated by Qt.

This patch also removes QMLViewer as a last
QtQuick 1 artifact in external tools.

Task-number: QDS-639
Task-number: QDS-4535
Task-number: QTCREATORBUG-22385
Change-Id: I5f67040954f8ef438961f7166a53bd96d5b73f4d
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2021-07-13 15:38:46 +00:00
hjk
b52f2d198a QtSupport: FilePathify BaseQtVersion::qmlsceneCommand()
Change-Id: Ia0bc3fcb40bbda31cd114503ab599b65d7597e70
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2021-07-01 07:37:00 +00:00
David Schulz
f66df921d7 Core: filepathify file renaming
Change-Id: I3d4f39e34e65cde3df7b7c19570e3a54d0625d53
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: David Schulz <david.schulz@qt.io>
2021-06-17 11:13:51 +00:00
David Schulz
410b02f8c5 Core: filepathify expected document changes
Change-Id: Ifa9341e55c79459db9ecef3c441da9b2816695bf
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2021-06-17 06:30:51 +00:00
David Schulz
5ec611b68e Utils: add FilePath::completeBaseName
Removing some FilePath::toFileInfo() calls again.

Change-Id: I6610beebf2c30754fde525b71f4c4a34ceb5e30b
Reviewed-by: hjk <hjk@qt.io>
2021-06-04 07:07:07 +00:00
David Schulz
a13aef759e Utils: filepathify fileutils
Change-Id: Ic9048369f64d793f5f567cdb0c715488fb5a4ff6
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2021-05-18 14:30:53 +00:00
David Schulz
8b7a90ac51 Utils: filepathify TextFileFormat
Change-Id: I6a4e2d38b0bbdec661a4a492901d9182a9f2e502
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2021-05-18 12:35:49 +00:00
hjk
f2f40efa03 Utils: Move process arguments class out of QtcProcess
The main QtcProcess interface is nowadays a CommandLine, with no
explicit references left to QtcProcess::Arguments and related static
helper functions, so it only clutters the QtcProcess class interface

So move these items out of QtcProcess, later potentially to a separate
file pair.

Change-Id: I45c300b656f5b30e2e2717232c855fdd97c2d1d7
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2021-05-11 09:45:24 +00:00
hjk
09d24face0 QmlProject: Use new RunConfiguration::setRunnableModifier
Change-Id: Idb729996b979effc96d97bfe7220668dfb904bb2
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2021-04-21 06:24:06 +00:00
Eike Ziller
bce81fd992 Projects: Create QIcons in the UI thread
Creating QIcons elsewhere is not safe because of image reader plugin
loading and the pixmap cache.

Fixes: QTCREATORBUG-25301
Change-Id: Ia22a0cd571f808d7f5c639353fdf2e548743f8ca
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
2021-04-09 13:34:55 +00:00
Aleksei German
960d0e42ad Replace modal dialog with InfoBar in QmlProject
Change-Id: I0dfa8722748ae67ff29ad0aeb72681ee8c413d28
Fixes: QDS-3765
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
2021-03-24 14:57:01 +00:00
Michael Winkelmann
9b99e93a96 QmlBuildSystem: MainFilePath member function
Change-Id: I388af6ffdbd310c9a433f6fbcb76e86db4c5053f
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2021-03-23 13:26:08 +00:00
Marco Bubke
c2086e7854 QmlDesigner: Bump database version
Change-Id: I1342d85161e3d83de5411bd1a9ee97809b1ccfd7
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2021-03-22 08:34:22 +00:00
Aleksei German
3ad3f3ec16 Improve Qt Design Studio visibility in Qt Creator
Fixes: QDS-3765
Change-Id: I877da7c0caf153a48c17dbc9ced87ef54c1a082c
Reviewed-by: Knud Dollereder <knud.dollereder@qt.io>
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2021-03-19 14:00:30 +00:00
Marco Bubke
da7b83b238 QmlDesigner: Bump multi language database version
Change-Id: Icd9b379c4dfbc09a8f949c86e0354d28f6184bc7
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
2021-03-11 16:47:18 +00:00
Marco Bubke
00cec8a688 QmlProjectManager: Bump up version of the multilanguage database
Change-Id: I123171475f6d37241fdbe37c94725df718f5fe9f
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2021-03-09 08:57:53 +00:00
Miikka Heikkinen
49c8ccbe87 QmlProjectManager: Show .hdr images in projects view
Task-number: QDS-2128
Change-Id: Ib95eb63618c198db51dd51edbe9272f734cdb0e2
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
2021-01-29 11:59:04 +00:00
Eike Ziller
df6967a897 Merge remote-tracking branch 'origin/4.14'
Change-Id: I6e67f23464fc14dda5a659004f0aa360d6f5d25f
2021-01-27 12:28:47 +01:00
Marco Bubke
70f50b3503 QmlDesigner: Bump up database version
We change the database schema.

Change-Id: I2715f47995374fe3d17ba97af9287af198c28959
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2021-01-27 09:44:47 +00:00
Eike Ziller
37a0ef29c0 QML: Use new message manager API
That is more evocative. Also avoid some instances of popping up the
general messages pane, which should preferably only happen on direct
user interaction.

Task-number: QTCREATORBUG-24430
Change-Id: I69bb49f84c1486fd32b2a048ca4d76dceb6a0b2b
Reviewed-by: Knud Dollereder <knud.dollereder@qt.io>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2020-12-22 08:09:10 +00:00
Christian Kandeler
29ddb3bcdb ProjectExplorer: Allow to schedule a build/run during a project parse
Once we parsed the project initially, subsequent parses typically do not
change things in a major way, so we can expect e.g. run configurations to
stay intact.
It therefore makes sense to allow users to schedule an
application run not only during a build (see 4b92b7ac60), but also
during a parse. Arguably, this is even more relevant, as parsing is
usually not triggered directly by the user, but happens as a side effect
of editing a document or switching a branch. It is then annoying for
users to have to wait until the respective buttons get enabled again.

Fixes: QTCREATORBUG-24986
Change-Id: I1081ccde668eee794c39b96cd0bad5c3aaa580bc
Reviewed-by: hjk <hjk@qt.io>
2020-12-11 15:17:05 +00:00
Jarek Kobus
c9f5ce51e0 Don't use iterators to temporary containers
Fix a clazy warning, like:
Don't call QVector::begin() on temporary [clazy-temporary-iterator]

Indeed, we may pass begin and end iterators for 2 different
instances of temporary vector (shared though).

In addition: use const iterators.

Change-Id: Iac1055d9fc226f1b48ca72ee4f3aab433addfe7f
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2020-11-20 12:25:31 +00:00
Eike Ziller
4d39f2736f Merge remote-tracking branch 'origin/4.13' into 4.14
Change-Id: If549dd1bc610704ece881c408cf44192dabed8b9
2020-10-19 14:10:51 +02:00
Tim Jenssen
57e77ec449 qmlpreview: fix calling right localeIsoCode method
Also add some QTC_CHECK to get at least some warning
in case the functions are renamed in future.

Change-Id: Ie4e78855152e9946950603c95fa881755e850c62
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
(cherry picked from commit 165ccb828d)
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2020-10-14 15:14:48 +00:00
hjk
2cabd2ceb5 Utils: Consolidate LayoutBuilder interface a bit
- the var args template for addItems was overkill creating a lot of
  instantiations. Use a temporary list instead.
- allow default constructed LayoutItems to be used for an empty cell,
  avoiding the use of a QLabel with empty text
- add an addRow({...}) overload as convenience shortcut for
  .startNewRow().addItems({...}
- rename startNewRow() to finishRow()

Change-Id: I6d49dacbac3d7acf140ca526884ba1ceeeca2e0d
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2020-09-24 10:32:26 +00:00
hjk
cec468d78a Utils/ProjectExplorer: Move re-usabled bits of aspects to Utils
Classes involved are BaseAspect and some derived classes,
LayoutBuilder and VariableChooser.

This is mostly mechanical, with various include/using changes
to make it compile.

Change-Id: I624a457f3555f102e541c4c71e33a9423af32250
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2020-09-23 07:44:42 +00:00
hjk
61bfd32438 ProjectExplorer: Introduce a ProjectConfiguration::kit() function
For convenience, and use it in some places.

Change-Id: I8f7cb502b37b2fbf4cf2d17cac9c6299558332dc
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2020-09-09 06:27:21 +00:00
David Schulz
339db00f85 Core: replace QString with Utils::FilePath to get documents
Change-Id: I01777c227398be8bd3bf877c5429b84a75aa361b
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2020-09-04 10:14:14 +00:00
Eike Ziller
2a05186194 Merge remote-tracking branch 'origin/4.13' into master
Conflicts:
	CMakeLists.txt

Change-Id: I799060da2cb299bb0c49a3da3530fad18427a23c
2020-08-21 10:08:55 +02:00
Thomas Hartmann
02c9f0384c QmlProject: Fix crash
Change-Id: I6b83b6c05b1c94f62c868329ea118d638d9928b6
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2020-08-20 12:12:46 +00:00
hjk
51e7bce109 ProjectExplorer: Rename Base*Aspect to *Aspect
In most cases they are used directly, so there's not much Base* in that.

Added the old name as alias as porting help for a while.

Change-Id: I494a8a560b8996bcf74915ea3570b504df6a6b4c
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2020-08-14 07:35:43 +00:00
Tim Jenssen
4fe5b923cd Merge remote-tracking branch 'origin/qds-1.59' into 4.13
Change-Id: Ic720f3adab305c5ef8cd10e713ccabf510eff0c0
2020-08-13 06:39:40 +00:00
Tim Jenssen
bde420f7b7 qmlproject: rename lastUsedLanguage -> currentLocale
removed the connection from plugin to
QmlMultiLanguageAspect::setCurrentLocale
but calling it directly in QmlPreviewPlugin::setLocale

Does not matter which method is called it will change the right
thing only once because it is checking if it already have the
set locale.

Change-Id: I6cb4b115788adc103481dcda45e3214a0cd73401
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
2020-07-23 09:14:31 +00:00
Tim Jenssen
b45b771581 qmlproject: add convenience method to QmlMultiLanguageAspect
Change-Id: I88799aa1c5caa5c967b7c680ef9ddcbdd4b01bf5
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
2020-07-21 15:37:41 +00:00
Tim Jenssen
3659f5b41d qmlpreview: stop previews if the language backend is changed
Change-Id: Iadf0712ea429f3bdb8c4109dfb558466fa2743f2
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
2020-07-21 15:37:31 +00:00
Tim Jenssen
d628a7c6cd qmlproject: remove unnecessary separator
results in two separators which looks wrong

Change-Id: Ie715e1b504303a9ab819ede08b1e69095c5d870d
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
2020-07-20 16:56:21 +00:00