- Identify products by the name/profile tuple instead of just the name.
- If the product's profile differs from that of the overall
project, add it to the visual representation.
Change-Id: I4a89db60911277977458370157e435472bbe428f
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
Root cause is trying to set the display name on a FolderNode that
is not in the tree yet.
Allow setting the displayname in the constructor and use that new
constructor where it makes sense.
Task-number: QTCREATORBUG-12897
Change-Id: I907e48cac837966e38524bfe88a87ef17d93f0b2
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
Such build system files must be filtered out, as they do not appear on
the right-hand side of "files" properties and have completely different
remove semantics.
Change-Id: I3963aa853003f4d674392434529dab19749af25b
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
qbs::Group is a reference-counted value-like class, and it makes no
sense to hold it as a pointer. It makes even less sense to compare that
pointer when deciding whether a project node needs an update, as this
comparison will always be false (and technically undefined behavior as
well if the original qbs::ProjectData object no longer exists).
Change-Id: If188f83802bf6cffd04215d192667cf0200e25d3
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
The qbsProjectData() member function always returned the top-level
project data, which messed up a couple of things, for instance
"build sub-projects" and the node tree updates.
Instead, return the project data corresponding to the node.
Change-Id: If40c441c62334f0069a5fe3cb4873cf973baf135
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
The build graph is locked then. Disabling the action in the first place
is nicer than letting the respective qbs API call fail.
Change-Id: Icfb89b454a240253c9ddc7681b452d06ff0393dd
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
Show build system files used by Qbs that are part of the project
hierarchy in the Projects Pane.
Change-Id: Ie7d1f1833fb00376f92c1436bd83e4f0518ae3ac
Reviewed-by: Christian Kandeler <christian.kandeler@digia.com>
qbs knows the effect of adding and removing files. There is no need to
set up the project from scratch.
Change-Id: I8938c7cfb3e3ac2deb3fb0d2175f447391a669cb
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
The current code keeps an instance of QbsProject and of qbs::Project in
every project node, with them being null/invalid everywhere except for
the top-level node. Instead, introduce a dedicated class for the root
node and hold a QbsProject only there. The qbs::Project is held in
QbsProject now.
As a nice side effect, this also fixes QBS-644, presumably because the
dubious-looking use of projectNode() has been removed.
Task-number: QBS-644
Change-Id: I5d36806745b9d67879db6f48aa56bc97868e4f17
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
If the operation fails, people currently don't get any hint as to what
the reason could be. For lack of a better place, log the error message
to the General Messages pane.
Change-Id: I19c48bbee0e0030b2d542425d43c089a29600756
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
Started implementing common functions to add new and existing files to
a project, using the API provided by Qbs. Works for most use cases
already. However, this is still work in progress.
Change-Id: I36ea921c203bd7caad564a45cd40cda408c72b54
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
Rename to runConfigurations() and remove the node argument which is
available as 'this'. Adjust const-ness of node argument in
RunConfigurationFactory::runConfigurationsForNode
Change-Id: Icb63e96a305152f90135a2656536de2581faafaf
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
So that the resource node can override it.
Task-number: QTCREATORBUG-11678
Change-Id: Id30d1b99ee23cc18fc29fc99cf0ad7ca919ed527
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
There may be more than one matching node, so these methods provided
a false sense of reliability.
Change-Id: I6471b74a1d2dd4e8afc7e836fec45355696a0741
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
The reason they were on ProjectNode is that the signals are emitted
on the projectnode, but since I moved addFiles and others to FolderNode,
this makes more sense.
Change-Id: I918ca4d93dab78c8bb93dff03f53d1a6fbe21340
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
By default this simply calls the parent's supportedActions.
Most changes are due to the enum moving.
Change-Id: I25bf21b712cca48450014dbb0f748ac0c461e029
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
Changing it must emit the same signals as does setting path, since the
sorting might change.
Change-Id: Iaf29c0775387d623d2e611e202b63ab52e812140
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
So far the simplified project tree was a flat list of files for qbs
projects. With this change it is a flat list of Products, each
containing a flat list of all files referrenced.
Change-Id: If53e80ca69f595df245a20af9f9ced1121cf30af
Reviewed-by: Christian Kandeler <christian.kandeler@digia.com>
Reviewed-by: Kai Koehne <kai.koehne@digia.com>
Those objects are shared data pointers that can (and should)
be used as values. This is now actually possible due to
the newly introduced public default constructor and
isValid() method.
Change-Id: I989e339bd495aa7581b01f17f00cbffe0b617b9c
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
Use it instead of retrieving this information from the document.
Change-Id: I809fcb2daf59021cf503c371a5d40d75d7448796
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
That is what it actually is, wrt how Qt API calls it.
Change-Id: Ied02055debf6aad75556b0d9d22e8ba2f72be555
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
Use the project filename as a fallback in case qbs parsing fails
without being able to extract the main project data.
Task-number: QTCREATORBUG-9777
Change-Id: Iceedf55c7f5d56a8876c19bcbd94082752c08336
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
The filetype is only relevant for Qt4 projects. But even for Qt4 projects
the file type is insufficient to decide where the file should be added.
So remove the file type from the interface and let the projectmanagers
themselves figure out what they want to do.
Also fix
Task-number: QTCREATORBUG-9688
Change-Id: I02f7b1cd2e05efaf76e36fb9af34b109d4482f88
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
- Make project files buildable with current qbs.
- Update qbs submodule to enable Qt Creator to open these project files.
- Fix an invalid access that caused a soft assert.
Change-Id: I976d19240112d1ff048e51036e6702383735352b
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
Do not use pointers to qbs::(Group|Product|Project)Data. Those are
implicitly shared classes, and now have a isValid method so that
default constructed instances can be spotted.
Change-Id: Icd49fa517f2e17bc60cc82d103f479d3a2e7097a
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
With subprojects the tree is getting too confusing when everything
uses the same icons.
Change-Id: Ib1b8559c5f6e8a3c4299498db67d33c9eb916d66
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
Display line numbers as part of the displayName of nodes in the
Projects view. These are shown for the virtual files we use to
enable navigation to Qbs groups and products and it more clear
that these are actually locations in the build system and not
real files.
Change-Id: If32354ad5ceb79c865cae2951fe470c51718728f
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
Do not emit an updateNode signal for all existing nodes, but only for
those that actually changed state.
Change-Id: I0a906833a6879e224df0d4be05d3813b8e130083
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
* Mark files in FileTreeNode explicitly as the cleanup will fail
otherwise
* Mangle the basedirectory when moving nodes to unconfuse linux
Change-Id: I84186d13d1342453e9cad4065b5989d199f7a9c4
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
The code is simpler now and also fixes a reported bug.
Task-number: QTCREATORBUG-9378
Change-Id: Ibb8cd7b074e840eb413b8d433405e47dcc63ee06
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
Plus some minor adjustments in the qbs project manager to an API change.
Change-Id: I41ea8571fee7ec666344464ecc4f808bf92f13ce
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
This fixes the run options in the context menu.
Change-Id: If4911f7357329fcb843206165e20d53bf6717258
Reviewed-by: Daniel Teske <daniel.teske@digia.com>