Commit Graph

48 Commits

Author SHA1 Message Date
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
92a52a7181 Use Qt's QFileInfoList instead of QList<QFileInfo>
Helps to adapt to potential upstream changes in Qt 6

Change-Id: Ie154bd4fd513d46cb0493758be8943fc4581d71c
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2019-05-28 07:19:45 +00:00
Eike Ziller
e0d38ae414 Export Wizard values to JavaScript macro
Registers a new function "value('name')", available to the wizard json
files, which returns the value of the variable "name" as a JavaScript
object. So, variables with a string value are actual JavaScript strings,
booleans are booleans, lists are lists, and dictionaries are
dictionaries.

The patch also makes it actually possible to assign JSON lists and
dictionaries to values.

This removes some hacks involving creating complex JavaScript objects
through string substitution.

Change-Id: I4ac6da22bc5bccc9fadee97694c2fa14d44c9307
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2019-05-09 11:19:43 +00:00
Nikolai Kosjar
b1031d25dc ProjectExplorer: Fix build with Qt 5.9
‘qEnvironmentVariable’ was not declared in this scope.

Change-Id: Ibd5922c07a360410e006315459b35b5c45f87a9f
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2018-10-08 12:55:21 +00:00
Laurent Montel
167f08e2ce Allow to define a environment variable for qtc templates
Now we can load qtc templates from anothers directories.
In kde we start to provide some templates and we need
to be able to specify it.

Change-Id: I373faae7fdc3fa34ac9b3c7c57d69c1a5e4d244e
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2018-10-08 12:33:10 +00:00
Alessandro Portale
8d19333075 ProjectExplorer: Modernize
modernize-use-auto
modernize-use-nullptr
modernize-use-override
modernize-use-using
modernize-use-default-member-init
modernize-use-equals-default
modernize-use-transparent-functors

Change-Id: Iebed22caa2e733d292f334e956e3d16b844e14e3
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2018-07-16 10:01:53 +00:00
Tim Jenssen
d96c80c1a5 Wizards: sprinkle some consts
Change-Id: I54d8a37ce508570ce85faeca049ad2b855b99e47
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2017-09-27 09:01:33 +00:00
Alessandro Portale
5a0d7a0abd Core: Enable text overlay for "New File/Project" icons
Change-Id: I6f206b2c97f7435b4de3a06c32b3933f3519181a
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2017-07-24 15:26:57 +00:00
Tobias Hunger
95ac4edfd4 Projectexplorer: Modernize codebase
Change-Id: I4793b58aa77bcd46af99f8b843c0f7439cdc9269
Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
Reviewed-by: Vikas Pachdha <vikas.pachdha@theqtcompany.com>
2016-04-15 09:40:53 +00:00
Eike Ziller
f4e87a7e0c Merge remote-tracking branch 'origin/3.6' into 4.0
Conflicts:
	src/plugins/projectexplorer/applicationlauncher.cpp
	src/plugins/projectexplorer/applicationlauncher.h
	src/plugins/qmlprofiler/qmlprofilerclientmanager.cpp
	src/plugins/qmlprofiler/qmlprofilertool.cpp
	src/plugins/qtsupport/uicodemodelsupport.cpp
	src/plugins/qtsupport/uicodemodelsupport.h

Change-Id: I6f6ae77422d99f4f422b108ade6b64273df9dd57
2016-03-03 16:10:04 +01:00
Eike Ziller
1698b77827 Fix translations of JSON based wizards.
Used inconsistent translation contexts.

Task-number: QTCREATORBUG-8945
Change-Id: I59d1370501438f4ca00cd801cb6f2803a5ada9b7
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2016-03-02 14:47:07 +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
Tobias Hunger
4fde1b5501 Wizard: Make wizards report which type of projects they can support
Use that information to decide whether the wizard is a File or ProjectWizard

Change-Id: Ie630e206317c7e01e77c811819cb95b360a04e09
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2016-01-19 15:19:51 +00:00
Tobias Hunger
56a9b93a28 JsonWizard: Add option to put evaluated expressions into options
This is necessary to allow for constants that are not re-evaluated all
the time.

Change-Id: I4aec9d71aeae1a25ffa97eac177dd9c6fc6a90ca
Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
2015-12-14 14:26:24 +00:00
Tobias Hunger
480f40c038 JSONWizard: Unify "options" handling
Code was duplicated between the factory of the wizard and the file
generator.

Change-Id: Ied2ba99218a5f06e8a0dce0fbc12f277195de8ad
Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
2015-12-14 14:26:17 +00:00
Tobias Hunger
eebe44d3cf Wizards: Turn "platform" into an Id
It used to be a string constant.

Change-Id: Ibea34dc52e97a483989e6d628b908231f4e2dc54
Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
2015-12-02 14:49:20 +00:00
Tobias Hunger
4b0a8648e4 FeatureProvider: Remove Feature and FeatureSet
Use Core::Id for Feature and QSet<Core::Id> for FeatureSet.

Change-Id: I12341036bd9eaa82589d92bd3f7d21f2e6b737bd
Reviewed-by: Niels Weber <niels.weber@theqtcompany.com>
Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
2015-12-02 14:49:17 +00:00
Tobias Hunger
ca29cbfc8a Consistently use Utils::FileNameList
Consistently use Utils::FileNameList in favor of QList<Utils::FileName>

Change-Id: Iafbb466c882bfd91c25c9e78f107d401bfdb6d55
Reviewed-by: Niels Weber <niels.weber@theqtcompany.com>
2015-11-16 08:33:02 +00:00
Tobias Hunger
25e3d88834 JsonWizard: Keep "options" optional
Do not report an error if "options" are unset.

Change-Id: I53f12624275be2d8af8d38da8dfe6bfa6603b948
Reviewed-by: Alessandro Portale <alessandro.portale@theqtcompany.com>
2015-10-22 11:32:58 +00:00
Tobias Hunger
9324ef6eb1 JsonWizard: Allow object or list of objects for "options"
This is compatible with the existing wizards and makes writing a wizard
a tiny bit simpler and more consistent.

Change-Id: I72c6f858f337552fe2495a16beff17cdf0cce66d
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2015-09-22 09:14:46 +00:00
Leena Miettinen
3c1e53c8ac JSON Wizards: fix message punctuation and wording
Change-Id: Ic144da9b9511dfd13960c2263be89dd06683e228
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2015-07-03 09:02:09 +00:00
Tobias Hunger
5e2cd22065 JsonWizard: Be more consistent with the information exported to the wizard
s/trCategory/trDisplayCategory/ to match set field in the wizard.json file.

Change-Id: I3c78cc1e49978e028fb17256f82eb852a5dc50cb
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@theqtcompany.com>
2015-07-03 09:00:54 +00:00
Tobias Hunger
9d0c39768f Wizards: Allow for async wizards
Change-Id: Id150ede2549150be8e720c5a0e31b05309cb3fb9
Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com>
2015-06-03 12:59:22 +00:00
Tobias Hunger
7e41b40c91 Wizards: Treat running wizards in the same way as a running NewDialog
That is block the New file or project action.

Change-Id: Ic7bb6013fce02fdcdd5c86b70ba5428218597a40
Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com>
2015-06-03 08:07:29 +00:00
Tobias Hunger
bcc3cc992b JsonWizard: Make description on projects page default to the wizard description
Change-Id: Icb8a4856dda4298b3ee901bc7a5c22190ddca5a6
Reviewed-by: Alessandro Portale <alessandro.portale@theqtcompany.com>
2015-05-28 15:53:02 +00:00
Tobias Hunger
f1f2475d3e JsonWizard: split plugins and features when considering enabled state
Now that we have the infrastructure to handle both separately it makes
no more sense to merge them.

Change-Id: Ia2694eef60c0fe17b025e4d6766c7a8f775513f5
Reviewed-by: Alessandro Portale <alessandro.portale@theqtcompany.com>
2015-05-28 15:50:24 +00:00
Tobias Hunger
bd40ef3659 JsonWizard: Make enabled state of wizard more dynamic
Now it can be toggled based on platform selected.

Change-Id: I663e8cff149da8df55baab4ab4f61c2c2e06f837
Reviewed-by: Alessandro Portale <alessandro.portale@theqtcompany.com>
2015-05-28 15:44:50 +00:00
Tobias Hunger
b70d63952a JsonWizard: Make enabled/disabled more consistent
Wizards have a "disabled" flag, everything else can be "enabled". Make
that more consistent by having the "enabled" for the wizard, too.
Wizards default to "enabled" now, just as they did default to "not
disabled" before.

Change-Id: Ic91f60196137daf353f7995b10ade19673d66f4e
Reviewed-by: Alessandro Portale <alessandro.portale@theqtcompany.com>
2015-05-28 15:00:49 +00:00
Tobias Hunger
fd64aeed3e JsonWizard: Mark class-kinds as deprecated in warning.
Change-Id: I381c43fb85b552fef3a07910954482a45cbff5c0
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2015-05-26 12:02:41 +00:00
Tobias Hunger
25f2f8e1ee IWizardFactory: Create wizards with factoryCreators
Do not use the object pool to hold potential wizards. Register
FactoryCreator functions with IWizardFactory instead and use
those to create the wizards when necessary.

This saves us a couple of cycles during startup since we can now
delay construction of all wizards and it makes us more flexible
wrt. managing the lifecycle of the wizard factories.

Change-Id: I95d6a6dfcdf0fd995e1934a9fefcd96c6a676753
Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com>
2015-05-26 11:47:53 +00:00
Tobias Hunger
5a05103635 JsonWizard: Enable support for descriptive images in wizards
These images are displayed above the description in the new file/project dialog.

Change-Id: Ib218e62a40891ebc2c675c49b32b3789c42d740d
Reviewed-by: Alessandro Portale <alessandro.portale@theqtcompany.com>
2015-05-26 11:18:48 +00:00
Tobias Hunger
9c1f96d47a IWizardFactory: Remove class wizard kind
Map existing class wizards to file wizards. The separation has never
been clean anyway. Now "file" wizards create one or more files,
"project" wizards create a complete project (something that can be
opened as a project in Qt Creator).

Change-Id: I0562f26019b54a59d46814a13a0b2fa8995c3e0f
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@theqtcompany.com>
Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com>
2015-05-26 10:17:30 +00:00
Tobias Hunger
a19f9f683a IWizardFactory: Use Core::Id to identify a wizard
Change-Id: I9e1e9ce9a61d7d06a9869f309ed3089d843137a2
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2015-05-21 14:29:47 +00:00
Tobias Hunger
1e1fee86c4 JsonWizard: Treat no visible page the same as no page at all
Just accept the dialog and try to generate files when no page is
displayed.

Change-Id: I0ae9aa6c29e55f52f3edad35742869a0cc535521
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2015-05-04 15:26:56 +00:00
Tobias Hunger
7b8a867011 JsonWizard: Remove error reporting when a key was not found
Change-Id: Ic7066aa4ce1a8b2e584c825b5b013b9621c28010
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2015-05-04 15:26:16 +00:00
Eike Ziller
9926fc2ab1 Merge commit '3c85058694ee2e41658d17f524fb48f0b187d2fe'
Conflicts:
	src/libs/utils/tooltip/tipcontents.cpp
	src/libs/utils/tooltip/tipcontents.h
	src/plugins/android/androiddeployqtstep.cpp
	src/plugins/baremetal/baremetalconstants.h
	src/plugins/baremetal/baremetaldevice.cpp
	src/plugins/baremetal/baremetaldevice.h
	src/plugins/baremetal/baremetaldeviceconfigurationwidget.cpp
	src/plugins/baremetal/baremetaldeviceconfigurationwidget.h
	src/plugins/baremetal/baremetaldeviceconfigurationwizard.cpp
	src/plugins/baremetal/baremetaldeviceconfigurationwizardpages.cpp
	src/plugins/baremetal/baremetaldeviceconfigurationwizardpages.h
	src/plugins/baremetal/baremetalplugin.cpp
	src/plugins/baremetal/baremetalplugin.h
	src/plugins/baremetal/baremetalruncontrolfactory.cpp
	src/plugins/baremetal/baremetalruncontrolfactory.h
	src/plugins/cppeditor/cppcodemodelinspectordialog.cpp
	src/plugins/cppeditor/cppdoxygen_test.cpp
	src/plugins/cppeditor/cppdoxygen_test.h
	src/plugins/debugger/breakpointmarker.cpp
	src/plugins/debugger/debuggeritemmodel.cpp
	src/plugins/debugger/debuggeritemmodel.h
	src/plugins/debugger/loadcoredialog.cpp
	src/plugins/genericprojectmanager/cppmodelmanagerhelper.cpp
	src/plugins/projectexplorer/addnewmodel.cpp
	src/plugins/projectexplorer/addnewmodel.h
	src/plugins/projectexplorer/jsonwizard/jsonfieldpage.cpp
	src/plugins/qmlprofiler/abstracttimelinemodel.cpp
	src/plugins/qmlprofiler/abstracttimelinemodel.h
	src/plugins/qmlprofiler/notesmodel.cpp
	src/plugins/qmlprofiler/qml/CategoryLabel.qml
	src/plugins/qmlprofiler/qml/MainView.qml
	src/plugins/qmlprofiler/qml/Overview.js
	src/plugins/qmlprofiler/qml/Overview.qml
	src/plugins/qmlprofiler/qml/TimeDisplay.qml
	src/plugins/qmlprofiler/qml/TimeMarks.qml
	src/plugins/qmlprofiler/qmlprofilertimelinemodelproxy.cpp
	src/plugins/qmlprofiler/sortedtimelinemodel.cpp
	src/plugins/qmlprofiler/sortedtimelinemodel.h
	src/plugins/qmlprofiler/timelinemodelaggregator.cpp
	src/plugins/qmlprofiler/timelinemodelaggregator.h
	src/plugins/qmlprofiler/timelinerenderer.cpp
	src/plugins/qmlprofiler/timelinerenderer.h
	src/plugins/qmlprojectmanager/QmlProjectManager.json.in
	src/plugins/texteditor/findinfiles.cpp
	src/plugins/vcsbase/vcsconfigurationpage.cpp
	src/shared/qbs
	src/shared/scriptwrapper/interface_wrap_helpers.h
	src/shared/scriptwrapper/wrap_helpers.h
	tests/auto/qmlprofiler/abstracttimelinemodel/tst_abstracttimelinemodel.cpp
	tests/system/suite_debugger/tst_debug_empty_main/test.py
	tests/system/suite_debugger/tst_qml_js_console/test.py
	tests/system/suite_debugger/tst_qml_locals/test.py

Change-Id: I67540b648f8b162496f4aa606b04d50c7c9125c6
2015-02-12 17:29:21 +01:00
Tobias Hunger
01699e9f25 JsonWizard: Allow for wizards without generators
The Checkout wizard will not feature any generator.

Change-Id: I05900309a5ea8a638493ab0fa5499759bcdc181f
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2015-01-21 12:11:18 +01:00
Tobias Hunger
21f272a8c7 JsonWizard: WS only change
Change-Id: I6f5fd3818d51ee531b92be0b78b4435d621fe0ed
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2015-01-21 09:27:34 +01:00
Eike Ziller
3c85058694 Update License
Change-Id: I711d5fb475ef814a1dc9d2822740e827f3f67125
Reviewed-by: Alessandro Portale <alessandro.portale@digia.com>
2015-01-16 12:37:56 +01:00
Robert Loehning
18aa49e7c2 String improvements
Change-Id: I45778c9562ba530a36ddaf201f0c61d380d701cf
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@theqtcompany.com>
2015-01-06 11:50:19 +01:00
Eike Ziller
225e599c94 Register wizard windows so they appear in window list and get shortcuts
Change-Id: I69b3a49ba2e2162585502a523be835918b7b9533
Task-number: QTCREATORBUG-13766
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2015-01-05 16:04:52 +01:00
Tobias Hunger
b9d2fd8eac JsonWizard: Allow enableing/disableing of pages from the Json file
Change-Id: Ic21f0f176f2a82577eaf4a72fbb01c011e1ada2b
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
2014-11-03 09:42:07 +01:00
hjk
a439483d70 Use QFileInfo::exist(f) instead of QFileInfo(f).exists() if possible
Faster.

Change-Id: I91aa67462e11ff3258600d7f158de79942d0dc81
Reviewed-by: Marc Reilly <marc.reilly@gmail.com>
Reviewed-by: Christian Stenger <christian.stenger@digia.com>
2014-11-03 09:31:28 +01:00
Tobias Hunger
4c737d7157 JsonWizard: Small improvement to error message
Change-Id: I54368d8f7ceba1e43b0834f106edf16e065ad32d
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
2014-10-30 16:46:44 +01:00
Eike Ziller
9c7019f0b2 License update.
Change-Id: I0acde2c3b995693de682679471f03af85bdd0a61
Reviewed-by: Alessandro Portale <alessandro.portale@digia.com>
2014-10-15 15:19:55 +02:00
Tobias Hunger
f51fcacacb JsonWizard: Add File- and Summary pages
These reuse the existing pages we use for other wizards.

Change-Id: Ic505204e0988a6b44d112da35748f81d9f8e2c1f
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
2014-09-30 10:56:17 +02:00
Ulf Hermann
544783cf2a ProjectExplorer: Avoid static initialization fiasko
The search paths can only be constructed once the extension system is
ready. This may never happen if the plugin is loaded directly, e.g.
from an autotest.

Change-Id: Ibfcb7bbb6138480d772d5097aaa8b0ae44d1b043
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
2014-09-29 14:58:43 +02:00
Tobias Hunger
3491b1f22a Add JsonWizard
This is a generalization of the customwizard (using Json for its
configuration files since that is so easy to handle in Qt 5 and
since it is incompatible with the customwizard anyway).

It allows to define an arbitrary number of pages and generators to
generate the actual files.

Change-Id: I45a01cf7fb906701b627fa1471a898cad472f679
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
2014-09-19 16:54:50 +02:00