Files
QodeAssist/chat/NavigationPanel.cpp
Ivan Lebedev 9bb6d55687 refactor: Uses single QML engine for all QML code (#323)
* refactor: Uses single QML engine for all QML code

* fix: Adds missing `QPointer` include

* Parents QML engine instance to plugin instance.

---------

Co-authored-by: Ivan Lebedev <ilebedev@flightpath3d.com>
Co-authored-by: Ivan Lebedev <ilebedev1988@gmail.com>
2026-04-28 16:33:03 +02:00

27 lines
614 B
C++

// Copyright (C) 2024-2026 Petr Mironychev
// SPDX-License-Identifier: GPL-3.0-or-later
#include "NavigationPanel.hpp"
#include "ChatView/ChatWidget.hpp"
namespace QodeAssist::Chat {
NavigationPanel::NavigationPanel(QQmlEngine* engine)
: m_engine{engine}
{
setDisplayName(tr("QodeAssist Chat"));
setPriority(500);
setId("QodeAssistChat");
setActivationSequence(QKeySequence(Qt::CTRL | Qt::ALT | Qt::Key_C));
}
NavigationPanel::~NavigationPanel() {}
Core::NavigationView NavigationPanel::createWidget()
{
return {.widget = new ChatWidget{m_engine}};
}
} // namespace QodeAssist::Chat