Commit Graph

137 Commits

Author SHA1 Message Date
Eike Ziller
3f42c989ee Fix Qt 6 build of ProjectExplorer and targets & build systems
QStringRef is gone.
qsizetype vs int.
QMultiHash::insertMulti is gone.
QXmlStreamWriter writes UTF-8 by default.

Task-number: QTCREATORBUG-24098
Change-Id: Id217e40a1f17993a84fc725976e9cb84618b0580
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2020-09-21 11:31:54 +00:00
Alessandro Portale
a159af342e Android: Remove unused functions
As found by Cppcheck

Change-Id: I9274fe45ed49099b52b4f8556508ec0adc676386
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
2020-09-15 08:56:55 +00:00
Assam Boudjelthia
aa9367f5d4 Android: re-organize manifest editor widget
The current manifest editor has too many things at once with
a long scroll bar, that can be overwhelming, this changes that
by re-organizing elements and grouping others.

Change-Id: Ie997af475939effbc575fa9e2a1d20184e943ff1
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2020-07-22 07:37:39 +00:00
hjk
e1c88116b3 Core/Utils: Migrate further to Utils::Id
The coreplugin/id.h header is kept for downstream for now.

Change-Id: I8c44590f7b988b3770ecdc177c40783e12353e66
(cherry picked from commit 430a33dcd9)
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2020-07-06 11:15:18 +00:00
Ville Voutilainen
64896a9436 Android: parse image file names from manifest
Also scales splash images without stretching and reflects them
to other orientations.

Task-number: QTCREATORBUG-24149
Task-number: QTCREATORBUG-24150
Change-Id: Ie23a8ba5f75132971673d3232807e941dfd50f97
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2020-06-26 08:39:56 +00:00
Eike Ziller
7c5ed6f7d9 Move InfoBar to Utils
The only reason it was required to be in Core plugin, was its use of Id,
which now is available in Utils.

Change-Id: I66ce863c24924e6448d339b3422538a7fe167336
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2020-06-18 06:39:54 +00:00
hjk
3a690154cb Android: Use QRegularExpression to check package names
Task-number: QTCREATORBUG-24098
Change-Id: I1082d39e65c4237592c81758fcdde614fc50d6e0
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2020-06-10 09:24:52 +00:00
Ville Voutilainen
a2cd1e45df Android: add a splash screen editor to manifest editor
Task-number: QTCREATORBUG-24013
Task-number: QTCREATORBUG-24011
Change-Id: Iea7e8ff8f9bf616612827b70de67e01801ab1229
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
2020-06-07 17:47:57 +00:00
Eike Ziller
e5bb7d1ffe Remove unnecessary removeContextObject calls
They are removed on deletion now.

Change-Id: I08461ea4938e24ab450df013a0f8f820032381da
Reviewed-by: hjk <hjk@qt.io>
2020-05-27 08:42:00 +00:00
Ville Voutilainen
52188918c0 Android: add service editor to manifest editor
Task-number: QTCREATORBUG-23937
Change-Id: Iec0435721504df744ec985bd3e5cefcc0700e852
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
2020-05-25 11:18:09 +00:00
Eike Ziller
10114dc036 Merge remote-tracking branch 'origin/4.12'
Conflicts:
	src/plugins/android/androidmanifesteditorwidget.cpp

Change-Id: I8143d9e02837dcd78a637da7b333a6eeebb105cb
2020-04-07 11:13:58 +02:00
Assam Boudjelthia
8f8b1b3d9d Android: fix manifest editor appending lib_name meta-data
The manifest editor is always adding the meta-data part for
"android.app.lib_name" because parseMetaData() is wrongfully
returning false.

Change-Id: Ic5f1971e98f213b6fe517bf6605120b21ca51508
Reviewed-by: Ville Voutilainen <ville.voutilainen@qt.io>
2020-04-03 11:54:51 +00:00
Ville Voutilainen
3af1a7b4cf Android: fix a thinko in syncing icons to widgets
The path can't be set unconditionally, and copyIcon
sets the path when necessary. So call copyIcon here.

Task-number: QTCREATORBUG-23747
Change-Id: I72a61798ad54c94a5c2a30bb313eb234f51d5ff3
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
Reviewed-by: BogDan Vatra <bogdan@kdab.com>
2020-04-03 10:03:14 +00:00
Eike Ziller
c8a2ea5433 Merge remote-tracking branch 'origin/4.12'
Conflicts:
	src/plugins/qmldesigner/components/curveeditor/detail/graphicsview.cpp

Change-Id: I2a0ccb84560174c5170d5baaff526c0e095f0ba0
2020-03-19 09:35:50 +01:00
Assam Boudjelthia
86090059dd Android: remove unnecessary minimumSize limit to permissions listView
The minimumSize can cause the manifest editor UI to have a vertical
scroll bar even if it's not needed on some small displays.

Change-Id: I78b855d63d5a5f16a77ce58b86f0537f526aec44
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2020-03-18 14:05:51 +00:00
Ville Voutilainen
1fbc8a7f68 Android: turn manifest editor application icons into widgets
Change-Id: If192b1b4809cd68ebd214f3fd82e26c7818df32f
Reviewed-by: BogDan Vatra <bogdan@kdab.com>
2020-03-06 11:00:04 +00:00
BogDan Vatra
8bb3b3c4f1 Disable androidMinSdkVersion & androidTargetSdkVersion editing if needed
Starting with Qt 5.15 we moved sdk min & target versions from
AndroidManifest.xml file to build.gradle (the change was needed by
android gradle plugin).

Fixes: QTBUG-70817
Change-Id: I3b493d88da1a4a98f1a6d8ebadc26aebfc601090
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2020-03-06 07:18:04 +00:00
Assam Boudjelthia
fc3f5033e2 Android: fix minor syntax issues
This fixes minor things missed in previous commit
b081d7dc8f.

Change-Id: I47c0703a81726d7c0c2bf01d844e39096424ea5e
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2020-03-03 13:02:10 +00:00
Assam Boudjelthia
75a895a7a3 Android: place add permissions combobox on top of the list view
It's more convenient to have the add permissions combobox
on top of the list view, so that it would be directly visible
without needing to scroll down, especially if on non-fullscreen
mode or small screen.

Task-number: QTCREATORBUG-23283
Change-Id: If3ef29fc91dd38f00d03ec63ce56103728c4b5f9
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2020-03-03 12:29:21 +00:00
Assam Boudjelthia
b081d7dc8f Android: allow style extraction method selection to the manifest editor
Make a bit more easier to choose the method of style extraction to
the manifest editor UI.

Task-number: QTCREATORBUG-23283
Change-Id: I65ad52f07d31913cf091ef4ef1693617ac82d4ad
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2020-03-03 12:29:01 +00:00
Ville Voutilainen
82dab12acd Android: make icon removal actually work
Also adjusts icon preview sizes and adds a master icon from which
the other icons are generated.

Task-number: QTCREATORBUG-23283
Change-Id: I21c3d11f9b5d4d815dc6d9ad7c2363b67767d03a
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2020-02-25 20:07:54 +00:00
Assam Boudjelthia
67df868f5c Android: Automatically use the correct NDK for each Qt version
Based on change 286266, we can find a correct NDK version for Qt for
Andriod version. This change allows Android plugin to get relevant NDK
information and registers appropriate toolchains and kits settings.

[ChangeLog][Android] Automatically use correct NDK version
corresponding to used Qt version.

Task-number: QTCREATORBUG-23583
Change-Id: Ic6b0d7a1ae8962c075b77498de88e018a008ac3e
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2020-02-17 16:14:50 +00:00
Ville Voutilainen
0f3f85278d Android: make the manifest editor's icon selector's layout more compact
Change-Id: I89c6aba9ebffd02521f0c849f5dcad40245ce5db
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2020-01-30 08:14:43 +00:00
Ville Voutilainen
c4113381ee Android: make manifest editor icon buttons more self-evident
Task-number: QTCREATORBUG-23283
Change-Id: I727a0c808c2ce5a50b696889ac973692a03422be
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2020-01-29 08:01:45 +00:00
hjk
3ecf3d9575 Android: Simplify code in manifest editor
Change-Id: I1a54cc1d59b9fdf03083363cc26c25f72e893006
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2019-11-18 07:47:09 +00:00
Sona Kurazyan
8e31932c29 Remove usages of deprecated APIs of QLayout
Replaced:
  QLayout::setMargin() -> QLayout::setContentsMargins()
  QLayout::margin() -> QLayout::getContentsMargins()

Task-number: QTBUG-76491
Change-Id: If28ef6910b3afe5d04e4746b74f9362a3e3b3c8e
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2019-09-02 13:01:07 +00:00
hjk
36fcd52136 Utils: Add toSet/toList functions
As replacement for functionality that's being deprecated
in Qt but still useful or needed, or that cannot easily be handled
without resorting to #if QT_VERSION checks in user code.

Change-Id: Id3575a54ff944bf0e89d452d13944fcaee270208
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2019-07-02 12:48:54 +00:00
hjk
473a741c9f Utils: Rename FileName to FilePath
More in line with QFileInfo terminonlogy which appears to be
best-of-breed within Qt.

Change-Id: I1d051ff1c8363ebd4ee56376451df45216c4c9ab
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2019-05-28 12:23:26 +00:00
hjk
413025db10 Android: Simplify AndroidManifestEditorWidget::iconPath
Avoid a use of FileName::appendPath().

Change-Id: Ifd5367dc9048bf379362d594d32809e0971e9524
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2019-05-16 08:02:04 +00:00
hjk
6f37348b4c Replace static_casts by QOverload where possible
Mainly to get rid of the QProcess::finished deprecation warning.

Also adjust coding style in the surrounding connects when needed.

Change-Id: I12f9b248c7974b892c4a069356e578e80f8c59e9
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2019-02-26 15:18:14 +00:00
Christian Kandeler
83dd031960 ProjectExplorer: Rename KitInformation to KitAspect
The name "KitInformation" does not properly convey the fact that it
represents a certain *aspect* of a kit. The same goes for
"KitConfigWidget", which in addition was inconsistent with
"KitInformation".
We now use "KitAspect" and "KitAspectWidget".

Change-Id: I9804ee4cedc4d61fad533ea1dd4e4720e67fde97
Reviewed-by: hjk <hjk@qt.io>
2019-02-11 11:55:01 +00:00
Eike Ziller
71d60ee9c8 Merge remote-tracking branch 'origin/4.8'
Conflicts:
	src/plugins/cpptools/compileroptionsbuilder.cpp

Change-Id: I522f91de70aff28692d7c3a050e8d52df0b82a76
2019-01-15 08:40:23 +01:00
Andy Shaw
986ce6fb98 Respect the setting of the version code via the pro file
As a pro file can now set the version name and code via the pro file,
this enables support for the code part as it will default to a
variable (similar to the version name). Therefore we need to use
QLineEdit for this over QSpinBox so that it is kept intact.

Done-with: Markus Maier <markus.maier@rosenberger.de>
Change-Id: I0524a90dc94888c11365164c41259a934caffa1c
Reviewed-by: Markus Maier <markus.maier@rosenberger.de>
Reviewed-by: Vikas Pachdha <vikas.pachdha@qt.io>
2019-01-09 11:42:16 +00:00
hjk
93257a56a0 QmakeAndroid: Replace remaining AndroidQtSupport
This uses the same approach as in the previous patches: Have some
generic interface in the base classes (here ProjectNode::targetData()
setTargetData()) and implement on the qmake project side.

Implementation for Cmake/QBS is architecture-wise possible, but
not used right now, and left for later.

Change-Id: I3bbf66170020cf9027a894cd66db15ec7ffbf499
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2018-12-20 13:13:51 +00:00
hjk
a9ce1a66a0 QmakeAndroid: Fill application combobox
... using a new base ProjectNode::targetApplications() function.

Change-Id: Id210683dce6bfa7ffbc89973423d326d76ac9309
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2018-12-17 14:02:06 +00:00
hjk
e88e47ff68 Android: Use less direct access to the qmake build step
Instead of qobject_cast use the reacently introduced virtual function
BuildConfiguration::regenerateBuildFiles() to trigger the necessary
work in the qmake case.

Change-Id: Ie5fd36550b5bad8c5f3f8bb1e2a3a16843f8f5b7
Reviewed-by: Vikas Pachdha <vikas.pachdha@qt.io>
2018-07-26 08:57:47 +00:00
Alessandro Portale
be5c228e5b Android: Modernize
modernize-use-auto
modernize-use-nullptr
modernize-use-override
modernize-use-using
modernize-use-equals-default
modernize-use-transparent-functors

Change-Id: I6c9e567edf16cf436c0e0c1239b40f74574a1096
Reviewed-by: Vikas Pachdha <vikas.pachdha@qt.io>
2018-07-26 08:26:21 +00:00
Eike Ziller
f8f882ecdf Fix focus handling in android manifest editor
If focus gets set on the editor widget, either the current focus widget
of the current page (gui/text) should receive application focus, or the
page itself (where the gui page should defer that to its first input
widget).

Change-Id: I8a35c2e9ca06fe694069b594788f7f40307abbda
Reviewed-by: Vikas Pachdha <vikas.pachdha@qt.io>
2018-01-04 07:41:46 +00:00
Eike Ziller
2684254fad Fix text based Android manifest editor actions
All text editor actions were disabled. We want the actions to be enabled
when the focus is in the text editor widget in the Android manifest
editor.

For this the text editor action handler must differentiate between the
_editor_ and the _context_ that it handles. The one for the text based
manifest editor handles the manifest editor, but the context is specific
to the text editor part.

Change-Id: Ib91cc763cb27333a7d5b6e5b036dfead33961871
Reviewed-by: David Schulz <david.schulz@qt.io>
2017-05-18 07:08:56 +00:00
Tim Jenssen
f2b8e9acd1 SessionManager: Clean up methods around projects
Clean up methods around projects() and update its usages to modern
language standards.

Change-Id: Ia0a4574d014ce41e0d511a392e4eed4680981d0e
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-03-02 09:31:23 +00:00
Tim Jenssen
2631ffabd5 Remove spaces in initializer lists
Format initializer lists code style like.

Change-Id: Ib82c235e4ba7dc75ee96a7abc0c47eff7b0a9013
Reviewed-by: hjk <hjk@qt.io>
2017-02-22 16:25:09 +00:00
hjk
56409f5afa Replace a few occurrences of QStringList() << ...
... by something shorter.

Change-Id: I363b4e509adb07997517b2d233246a333aea4aea
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2017-02-08 11:21:45 +00:00
Jarek Kobus
ca4be197ef Revert "Replace virtual isModified method with a getter/setter/notifier"
This doesn't fix the issue with cleaning the clear state of undo stack.
This introduced the issue when ui file is opened it's marked as modified.
It reverts 59c90e00c1
and d0c537ca75

Change-Id: Ifd4ff8483d6c297461632de500a4502b1fd0871f
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2016-10-21 09:19:56 +00:00
Jarek Kobus
59c90e00c1 Replace virtual isModified method with a getter/setter/notifier
We have lacked the setter and dedicated notifier before.

Change-Id: I58845a48259d260c5cc90ae94b173c79cddcfef9
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2016-10-17 14:44:08 +00:00
Orgad Shaneh
670e54345c Remove use of deprecated Qt algorithms
Change-Id: Ib35cffa2d5762874feea9b1d4df7f569c0e5f496
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2016-08-09 13:41:25 +00:00
Ulf Hermann
15fbfaf2e9 Move icons to Utils
This way we can use them from libraries, not only from plugins.

Change-Id: Ic35cfd5f04d638d87606bf272b2c00ded1267c1b
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2016-08-05 10:52:53 +00:00
Orgad Shaneh
88dfa84fc6 Android: Use Qt5-style connects
The heavy lifting was done by clazy.

Change-Id: Id09b62b7b9812d9c0981202c257d18387a8b09d9
Reviewed-by: BogDan Vatra <bogdan@kdab.com>
2016-07-04 09:35:58 +00:00
Eike Ziller
68aeb40ff5 Merge remote-tracking branch 'origin/3.6' into 4.0
Change-Id: I5c524b61aa558b66e74a9260b59583851530ac36
2016-03-08 12:51:55 +01:00
Tobias Hunger
d502727b2c Android: Fix possible crash
Change-Id: I1b73a077f6d2f157d4367358f9f156d32b3e6cea
Task-number: QTCREATORBUG-15832
Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com>
2016-03-08 11:30:19 +00:00
Tobias Hunger
397e7f4843 Update License according to agreement with Free Qt Foundation
* Update files in src/plugins

Change-Id: Ia5d77fad7d19d4bb3498e78661982f68729adb22
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2016-01-19 15:57:01 +00:00