| 718 | } |
| 719 | |
| 720 | void ClientInterface::setChatFilePath(const QString &filePath) |
| 721 | { |
| 722 | if (!m_chatFilePath.isEmpty() && m_chatFilePath != filePath) { |
| 723 | const auto providerName = Settings::generalSettings().caProvider(); |
| 724 | auto *provider = PluginLLMCore::ProvidersManager::instance().getProviderByName(providerName); |
| 725 | |
| 726 | if (provider |
| 727 | && provider->capabilities().testFlag(PluginLLMCore::ProviderCapability::Tools) |
| 728 | && provider->toolsManager()) { |
| 729 | if (auto *todoTool = qobject_cast<QodeAssist::Tools::TodoTool *>( |
| 730 | provider->toolsManager()->tool("todo_tool"))) { |
| 731 | todoTool->clearSession(m_chatFilePath); |
| 732 | } |
| 733 | } |
| 734 | } |
| 735 | |
| 736 | m_chatFilePath = filePath; |
| 737 | m_chatModel->setChatFilePath(filePath); |
| 738 | } |
| 739 | |
| 740 | QString ClientInterface::chatFilePath() const |
| 741 | { |
nothing calls this directly
no test coverage detected