forked from qt-creator/qt-creator
LanguageClient: Add context object into connections
Change-Id: I03bc2c1a9fa36d7c629d63a7fb866b919bb2cc20 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: <github-actions-qt-creator@cristianadam.eu> Reviewed-by: David Schulz <david.schulz@qt.io>
This commit is contained in:
@@ -292,10 +292,8 @@ Core::NavigationView CallHierarchyFactory::createWidget()
|
||||
auto button = new QToolButton;
|
||||
button->setIcon(Icons::RELOAD_TOOLBAR.icon());
|
||||
button->setToolTip(Tr::tr("Reloads the call hierarchy for the symbol under cursor position."));
|
||||
connect(button, &QToolButton::clicked, [h](){
|
||||
h->updateHierarchyAtCursorPosition();
|
||||
});
|
||||
return {h,{button}};
|
||||
connect(button, &QToolButton::clicked, this, [h] { h->updateHierarchyAtCursorPosition(); });
|
||||
return {h, {button}};
|
||||
}
|
||||
|
||||
} // namespace LanguageClient
|
||||
|
||||
@@ -590,7 +590,7 @@ void LanguageClientManager::trackClientDeletion(Client *client)
|
||||
{
|
||||
QTC_ASSERT(!m_scheduledForDeletion.contains(client->id()), return);
|
||||
m_scheduledForDeletion.insert(client->id());
|
||||
connect(client, &QObject::destroyed, [this, id = client->id()](){
|
||||
connect(client, &QObject::destroyed, this, [this, id = client->id()] {
|
||||
m_scheduledForDeletion.remove(id);
|
||||
if (isShutdownFinished())
|
||||
emit shutdownFinished();
|
||||
|
||||
Reference in New Issue
Block a user