Commit Graph

8 Commits

Author SHA1 Message Date
Christian Kandeler
966f4ea6a9 ProjectExplorer: Rework the build step run interface
Originally, the build manager used to run all build steps in a dedicated
thread. Communication between the step and the manager happened via a
QFutureInterface that was passed into the step's run() function.
Later, new steps were added that operated asynchronously, so the build
manager had to differentiate between the different kinds of steps for
starting and stopping.
These days, almost all build and deploy steps work asynchronously, which
made the QFuture-based interface look increasingly odd.
With this patch, all build steps are expected to work asynchronously, so
the build manager no longer needs to differentiate. Steps are started
and requested to stop via the run() and cancel() functions,
respectively, and emit the finished() signal when they are done. Build
step implementors no longer have to deal with a QFutureInterface. For
steps whose implementation is inherently synchronous, the BuildStep base
class offers a runInThread() function.

Change-Id: If905c68b234c5a669f6e19f43142eaa57d594803
Reviewed-by: hjk <hjk@qt.io>
2019-01-31 16:10:01 +00:00
hjk
f007bc7593 ProjectExplorer: Simplify BuildStep::init() signature
The extra parameter was always computed but used only in one place,
and that use got removed lately.

Change-Id: Ie10c0107ca70ee97ce03f83294992aab8d1a3ffe
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2019-01-18 09:11:37 +00:00
hjk
f44e73b858 ProjectExplorer: Simplify BuildStepFactory
De-QObject-ify class, tr contexts are now the product's
context, which was the case in some BuildStepFactories already,
and is current state in {Run,DeployConfiguration}Factory.
One spurious object name removed.

De-virtualize canHandle(), it was never overloaded and is not
intended to be overloaded anymore.

Remove unused clone() function.

Change-Id: Iff7fba5f707505f868f94458084a18650535fa23
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2018-05-31 10:15:42 +00:00
hjk
673aacc67c Nim: Move a few factories to their product's compilation units
There's several hundred kBytes extra for the separate .o in a
debug build, this doesn't scale well for a handful lines of code.

As the Nim plugin is a nice template for others elsewise, it would
be nice to use scalable patterns only.

Change-Id: I78e473d28a6a63d458dcbe06a77d93221867417f
Reviewed-by: Filippo Cucchetto <filippocucchetto@gmail.com>
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2018-01-19 07:11:39 +00:00
Christian Kandeler
c05a3fdb3d Give the values of BuildStep::OutputFormat better names
The old ones did not convey their meaning very well. In particular,
NormalOutput and MessageOutput were easily confused.

Change-Id: Ia0a8c1b1c366ab3f5c59f751b37b8b1f68f6831d
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2017-01-19 16:08:57 +00:00
Christian Kandeler
182c56b64f Nim: Fix usage of Buildstep::Outputformat
Change-Id: I2b017e6a14509fe61114929c4ac889c032f8c271
Reviewed-by: Filippo Cucchetto <filippocucchetto@gmail.com>
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2017-01-12 16:20:49 +00:00
Orgad Shaneh
c74a366df3 Nim: Cleanup includes and qbs dependencies
Change-Id: I1b6ef9d875a2b0c440e52148340337a3e3c25477
Reviewed-by: Filippo Cucchetto <filippocucchetto@gmail.com>
Reviewed-by: hjk <hjk@theqtcompany.com>
2016-06-15 07:58:51 +00:00
Filippo Cucchetto
94fdd4d900 Added plugin for supporting the Nim programming language
The plugin support:
- basic syntax highlighting
- indentation
- project management
- run and build configuration
- debugging
- code style

Change-Id: Idfbb02a11ed570c90149a54b726beb956712e2bd
Reviewed-by: David Schulz <david.schulz@theqtcompany.com>
Reviewed-by: hjk <hjk@theqtcompany.com>
2016-06-07 07:17:55 +00:00