aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/projectexplorer/targetsettingspanel.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Target Selector: Do not repeat kit name in context menuChristian Kandeler2020-06-261-5/+4
| | | | | | | | | | | Kit names can get rather unwieldy, and there is no point in repeating them in this particular context menu, where the user clicked pretty much right on the kit name. Fixes: QTCREATORBUG-24242 Change-Id: I04d96e53ece24fd6c54d8aa225d13a0c7354acd0 Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Eike Ziller <eike.ziller@qt.io>
* TargetSetupPage: Improve reporting on invalid kitsTobias Hunger2020-02-061-10/+10
| | | | | | | | | | | | | Give the reason for a kit being disabled in the tooltip. E.g. for a CMake project you will now get "Kit is invalid: No CMake tool set." instead of a generic error message about the kit being invalid. Change-Id: Ic776dc24149d65ebf27163b605ec2e52a3a504a7 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* ProjectExplorer: Add action to enable a kit for all projectsChristian Kandeler2020-01-301-0/+24
| | | | | | Fixes: QTCREATORBUG-22964 Change-Id: Ife27bae6422043c3cde4e7995947e97a5f1cfd4d Reviewed-by: hjk <hjk@qt.io>
* Target setup page: Un-queue another connection to kit managerChristian Kandeler2019-10-311-2/+1
| | | | | | | | | Amends 6fd29da2cb, which caused a regression in that a newly activated target was not selected anymore, so when switching to project mode, the build configuration was not shown without user intervention. Change-Id: If723fe886f3e478cbdbcd7a77cd7fb71eca69813 Reviewed-by: Christian Stenger <christian.stenger@qt.io>
* Target setup page: Un-queue connection to kit managerChristian Kandeler2019-10-211-3/+5
| | | | | | | | | | | | | | | | | If we have a project with two enabled targets and we remove both of the associated kits, one of the targets temporarily becomes the active one. If the activeTargetChanged() signal gets queued, then the receiver will be called with an invalid target pointer, as the target has been removed in the meantime. It is unclear why the signal was queued in the first place. Presumably the original reasoning is no longer applicable after various refactorings. This amends (and effectively reverts) commit c13b20f160. Task-number: QTCREATORBUG-23075 Change-Id: I3c63c763319734a4d52b3bb221919b20fd123dbe Reviewed-by: hjk <hjk@qt.io> Reviewed-by: Christian Stenger <christian.stenger@qt.io>
* Port setMargins to setContentsMarginsLaurent Montel2019-10-161-1/+1
| | | | | Change-Id: Ie6b3f3e4dddbbf4bcc7ea7561ec348ff2c666907 Reviewed-by: hjk <hjk@qt.io>
* Target setup page: Do not dereference potentially invalid Target pointerChristian Kandeler2019-10-151-4/+2
| | | | | | Fixes: QTCREATORBUG-23075 Change-Id: I60d332b3ff18cf7c83e63cb87730b44ee2a47502 Reviewed-by: Christian Stenger <christian.stenger@qt.io>
* TargetSetupPage: More improvementsChristian Kandeler2019-10-111-47/+0
| | | | | | | | | | | | - Do not claim we are parsing unconfigured projects. - Use our concept of a "usable" kit in some places that still used just the kit's "valid" attribute. - Merge two labels that belong together. - Get rid of unneeded state and indirections. Fixes: QTCREATORBUG-22963 Change-Id: I2481439435e92e98b7e0ba5053a1e8843a961aec Reviewed-by: Christian Stenger <christian.stenger@qt.io>
* Remove usages of deprecated APIsSona Kurazyan2019-09-031-1/+1
| | | | | | | | | | | | Replaced: QPalette::ColorRole::Background -> QPalette::ColorRole::Window QPalette::ColorRole::Foreground -> QPalette::ColorRole::WindowText Qt::ItemDataRole::TextColorRole -> Qt::ItemDataRole::ForegroundRole QFontMetrics::width() -> QFontMetrics::horizontalAdvance() Task-number: QTBUG-76491 Change-Id: I1302e6b569e725daa6f7be1428ffe055657fc644 Reviewed-by: Eike Ziller <eike.ziller@qt.io>
* Remove usages of deprecated APIs of QLayoutSona Kurazyan2019-09-021-3/+3
| | | | | | | | | | Replaced: QLayout::setMargin() -> QLayout::setContentsMargins() QLayout::margin() -> QLayout::getContentsMargins() Task-number: QTBUG-76491 Change-Id: If28ef6910b3afe5d04e4746b74f9362a3e3b3c8e Reviewed-by: Eike Ziller <eike.ziller@qt.io>
* ProjectExplorer: Add convenience Project::addTargetFor{Default,}Kithjk2019-08-011-3/+2
| | | | | | | Less noise on the user side. Change-Id: I5cdf4af4910a3cc1ee0af1b43fcbc7329a6d59db Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* Merge remote-tracking branch 'origin/4.10'Eike Ziller2019-07-251-4/+4
|\ | | | | | | | | | | | | Conflicts: src/plugins/baremetal/iarewtoolchain.cpp Change-Id: I483e81d7e920e724fb7cde84a8f6fa9bce4cd518
| * PE: Do not let user enable a kit that has errorsChristian Stenger2019-07-241-4/+4
| | | | | | | | | | | | | | | | | | If a kit has errors it still could get enabled by using its context menu on the Project view. Avoid this and its side effects. Change-Id: I2434cd3c540c1f3c287b84258391450693df986a Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* | Avoid warning on empty expressionshjk2019-07-231-2/+2
| | | | | | | | | | | | | | | | For some reason, Q_UNUSED includes already a semicolon, adding one on the user side creates an additional empty statement. Change-Id: I9c5e8fac381345a60792cb75e2938fd53958d3b0 Reviewed-by: Christian Stenger <christian.stenger@qt.io>
* | Merge remote-tracking branch 'origin/4.10'Tim Jenssen2019-07-041-1/+3
|\| | | | | | | | | | | | | | | | | | | | | | | Conflicts: qbs/modules/qtc/qtc.qbs qtcreator_ide_branding.pri src/libs/utils/synchronousprocess.cpp src/plugins/baremetal/iarewtoolchain.cpp src/plugins/cmakeprojectmanager/cmakeproject.cpp tests/unit/unittest/CMakeLists.txt Change-Id: I124ad492df403286751e175d27fe36487ddf6d07
| * ProjectExplorer: Prevent inadvertant "configure" in target setup pageChristian Kandeler2019-07-011-1/+3
| | | | | | | | | | | | | | | | | | When the user presses the return key, this must only lead to project setup if clicking the "Configure Project" button would have been possible. Otherwise the prerequisites are not met. Change-Id: I247b9ff3a0600798667c7f95a99e7b61e7171706 Reviewed-by: Christian Stenger <christian.stenger@qt.io>
* | ProjectExplorer etc: More FilePath usagehjk2019-06-261-1/+1
|/ | | | | | | Mostly for project files. Change-Id: Icb6059f80758865e42cc9f9c092ec6782770dfd7 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* PE: Avoid possible nullptr accessChristian Stenger2019-06-181-0/+3
| | | | | Change-Id: Ib96ce9763dd9710cc4365978241d5d1d3ac1c0db Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* ProjectExplorer: Improve "import project" keyboard event handlingChristian Kandeler2019-06-121-0/+2
| | | | | | | | | Pressing return in the path chooser used to activate the "Configure" button, which is not what users intend. Fixes: QTCREATORBUG-17471 Change-Id: I86bc0dd9c976da35026654c7873dc4b63e45593c Reviewed-by: hjk <hjk@qt.io>
* ProjectExplorer: Introduce a alias for QList<Tasks>hjk2019-05-281-2/+2
| | | | | Change-Id: I91391ad22b420926b0f512cac23cfe009048b218 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* ProjectExplorer: Make sure the target setup page does not persistChristian Kandeler2019-04-121-32/+48
| | | | | | | | | | | The TargetSetupPage is not designed to stay around after setupProject() has been called. So let's throw it away in the TargetSetupPageWrapper and create a new one on demand. Fixes: QTCREATORBUG-21242 Change-Id: I1d6f4214e7bfdfef9d58593007728612642b90d6 Reviewed-by: hjk <hjk@qt.io> Reviewed-by: Christian Stenger <christian.stenger@qt.io>
* ProjectExplorer: Modernize even moreTobias Hunger2018-07-241-8/+5
| | | | | | | | Use unique_ptr for all *Private classes, except for those in singletons. Change-Id: Ib56c31ddedc6e9cf321f15de1f1e697a27ad4089 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* ProjectExplorer: ModernizeAlessandro Portale2018-07-161-4/+4
| | | | | | | | | | | | | | 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>
* ProjectExplorer: Hide invalid kits from Project ModeTobias Hunger2018-06-131-1/+1
| | | | | | | | | | Hide the build/runconfigurations of invalid kits in Project mode. This keeps the custom information around for the time being, and also provides for a nicer UI than what we had before. Change-Id: Id43e6be8b964665bcbc8b2e3e4be9c41cc52c92c Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* Projects: Fix capitalization in messagesLeena Miettinen2018-06-081-1/+1
| | | | | Change-Id: I1928fe11a3a23c0577ecc941d259d310a211e86f Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* ProjectExplorer: Fix possible crash in Projects modeTobias Hunger2018-06-011-3/+4
| | | | | | Change-Id: Ic57dac0487d03d88e0d9d37f67c55ae36e84af4d Reviewed-by: Tim Jenssen <tim.jenssen@qt.io> Reviewed-by: hjk <hjk@qt.io>
* ProjectExplorer: Fix "Click to activate:" tooltip in target setupAlessandro Portale2018-05-031-1/+1
| | | | | | | | | The kit information needs to be shown in the tooltip. Amends 460fdc02e058100baabdc5cdb658bbb9790a46ca Change-Id: Id661318d97244c6c35c5880842788fa265cc0098 Reviewed-by: hjk <hjk@qt.io> Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* ProjectExplorer: Hide build page for projects that do not buildTobias Hunger2018-04-191-1/+2
| | | | | Change-Id: I56feaab67690b5ece7379a9c1f676392230de107 Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
* ProjectExplorer: Report project-specific kit errors/warningsTobias Hunger2018-04-191-20/+27
| | | | | | | | | Report project-specific warnings about the kit used in Project Mode. E.g. a python project should not complain about missing toolchains, while a qmake project should. Change-Id: I5ce6742683cdeffc7ff3f1a3e8f0b89aee9aa0b4 Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
* Improve translated strings and make them consistentRobert Loehning2018-01-221-1/+1
| | | | | Change-Id: I88a6e6ceaa44b22539449037faa788caa9f349fc Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
* Drop unused variables and lambda capturesUlf Hermann2017-09-081-2/+2
| | | | | | | | | Also, add context to connect() expressions where we are or were capturing "this". Change-Id: I6e006ba6f83d532478018550d148ee93eca59605 Reviewed-by: Tim Jenssen <tim.jenssen@qt.io> Reviewed-by: hjk <hjk@qt.io>
* app_version.h: Make IDE name configurableTobias Hunger2017-09-051-4/+8
| | | | | | Change-Id: I993f452c8d09cf89e9a2958fc8e36b7d2c17ee6f Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* Project explorer: Fix UI text capitalizationLeena Miettinen2017-04-051-1/+1
| | | | | Change-Id: I59c391b1d910ad74e30592217451a956463bd804 Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* Utils: Introduce TreeItem::{begin,end}hjk2017-02-081-2/+2
| | | | | | | | | | | ... and use this to reduce the number of explicit uses of m_children. Despite of being shorter code by itself it is a step towards having an explicit LeafItem object that doesn't explicitly store a(n empty) vector of child nodes. Change-Id: If8db85e2f1134dd1578a78d31235bf57a28f863a Reviewed-by: Eike Ziller <eike.ziller@qt.io>
* Merge remote-tracking branch 'origin/4.2'Eike Ziller2017-01-231-1/+1
|\ | | | | | | Change-Id: Ib3073a0a3d80c99cf97b9839480dbf9583fa10de
| * ProjectExplorer: Disable copying steps to inactive kitshjk2017-01-191-1/+1
| | | | | | | | | | | | | | This fixes a hard crash due to a Target nullptr. Change-Id: I3065ac61bc950413d8958bcad5420f5868afd35c Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* | KitManager: Get rid of KitMatcher classTobias Hunger2017-01-181-9/+10
| | | | | | | | | | | | | | | | Use std::function instead. Clean up API while at it. Change-Id: I6e401ab57f5375e36710c30508c596af3f4b3385 Reviewed-by: Tim Jenssen <tim.jenssen@qt.io> Reviewed-by: Eike Ziller <eike.ziller@qt.io>
* | Merge remote-tracking branch 'origin/4.2'Eike Ziller2017-01-121-0/+4
|\| | | | | | | Change-Id: If9b3a860d7efb561bb710d49396d6bbe13809aa1
| * ProjectExplorer: Do not leak targetsetuppagesTobias Hunger2017-01-111-0/+4
| | | | | | | | | | | | | | | | | | | | Leaving these around can lead to a crash when updating a kit after the project has been closed. Task-number: QTCREATORBUG-17571 Change-Id: Ie4be99a665b072f3c920e3f365f5b20949436850 Reviewed-by: hjk <hjk@qt.io> Reviewed-by: Eike Ziller <eike.ziller@qt.io>
* | ProjectWindow: Remove one level of layout in build and run settingshjk2016-12-201-16/+6
| | | | | | | | | | | | | | This does not make a visual difference. Change-Id: Ic88dea0e0905be74733603a1ae24caa3afa6113d Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* | ProjectWindow: Add a PanelsWidget convenience constructorhjk2016-12-151-15/+8
|/ | | | | | | | ... combining default construction plus a single invocation of addPropertiesPanel(), the only way it is ever used. Change-Id: I2080e8b8fa25a2d7e429b7c18f5272466bc4eb79 Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* ProjectWindow: Delay panel update after target addinghjk2016-12-051-1/+1
| | | | | | | | | Parts of the machinery are not yet done when the signal arrives, waiting for next event loop iteration suffices to get a context enabling us to show the proper panel. Change-Id: Icbf33a4f5a900058ecc89ac125eb43313e12b74f Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* ProjectExplorer: Use Build by default in Build & Run settingsOrgad Shaneh2016-10-261-2/+2
| | | | | | | | This preserves the behavior of 4.1. Change-Id: I071ef1c6bf0be88aa7b9787114cbac5292910125 Reviewed-by: Tobias Hunger <tobias.hunger@qt.io> Reviewed-by: hjk <hjk@qt.io>
* ProjectExplorer: "Build" and "Run" icons for the projects mode treeAlessandro Portale2016-10-191-2/+14
| | | | | | | Task-number: QTCREATORBUG-17127 Change-Id: I5db19d65eaf7bf69c39ab39bb35e7e4f34e91a6f Reviewed-by: Florian Apolloner <florian@apolloner.eu> Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* ProjectExplorer: Revive project importerhjk2016-10-171-55/+4
| | | | | | | | | | Fixes a regression introduced in recent changes. Import project from build is now available again on the target setup page (shown when no kit is active) and in the context menu of the left pane. Task-number: QTCREATORBUG-17046 Change-Id: I5a1285624084f0cb6e0947560516ae88d4b3e376 Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* ProjectExplorer: Filter out unusable kitshjk2016-10-141-3/+19
| | | | | | | | | As side-effect, fix missing expansion of subitems in some cases. Task-number: QTCREATORBUG-17110 Change-Id: Ib0c74e968d6d814f9dadbb37b323c8ac68cda310 Reviewed-by: Robert Loehning <robert.loehning@qt.io> Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* ProjectWindow: More tree polishhjk2016-10-101-2/+10
| | | | | | | | | | | | | | | | | | | - Remove 'panel memory effect' when switching kits Previously, each target entry memorized when its Build or Run page was used, and when switching to the target, that page came up. Now, don't use that when switching targets, but instead take the same page as is selected on the target we are switching from. - Disable selection of the Build&Run and Project Settings "group entries" Change-Id: I2214f8edc38be2e76a50f8984aa75d8f78b62026 Reviewed-by: Tobias Hunger <tobias.hunger@qt.io> Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
* ProjectExplorer: Show kit warnings and errors as overlayAlessandro Portale2016-10-071-17/+42
| | | | | | | Instead of having kits just a big warning or error icon Change-Id: I5b1c72c3c6ddd4cb646125c70d979431166d31f2 Reviewed-by: hjk <hjk@qt.io>
* ProjectWindow: Fix crash in TargetSetupPagehjk2016-10-051-12/+13
| | | | | | | | | Move ownership of the ProjectImporter to the Project. Task-number: QTCREATORBUG-16744 Change-Id: I7fc217ce8058287c5435b259bdc5300a926f8098 Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io> Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* ProjectExplorer: Remove PropertiesPanel structhjk2016-10-041-16/+7
| | | | | | | | | Parameter structs are convenient if they get passed around a lot or are regularly changed. This isn't the case here, so make the user code more compact instead. Change-Id: Idd5e5cc1f70b1547607532cd3e6515c27983c169 Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>