forked from qt-creator/qt-creator
Copilot: remove unused client instance function
Change-Id: I84c3d674bae1011a7b0bff070c2d3d5d89675147 Reviewed-by: <github-actions-qt-creator@cristianadam.eu> Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
This commit is contained in:
@@ -3,8 +3,6 @@
|
||||
|
||||
#include "copilotclient.h"
|
||||
|
||||
#include "copilotsettings.h"
|
||||
|
||||
#include <languageclient/languageclientinterface.h>
|
||||
#include <languageclient/languageclientmanager.h>
|
||||
#include <languageclient/languageclientsettings.h>
|
||||
@@ -35,13 +33,6 @@ static LanguageClient::BaseClientInterface *clientInterface(const FilePath &node
|
||||
return interface;
|
||||
}
|
||||
|
||||
static CopilotClient *currentInstance = nullptr;
|
||||
|
||||
CopilotClient *CopilotClient::instance()
|
||||
{
|
||||
return currentInstance;
|
||||
}
|
||||
|
||||
CopilotClient::CopilotClient(const FilePath &nodePath, const FilePath &distPath)
|
||||
: LanguageClient::Client(clientInterface(nodePath, distPath))
|
||||
{
|
||||
@@ -69,7 +60,6 @@ CopilotClient::CopilotClient(const FilePath &nodePath, const FilePath &distPath)
|
||||
|
||||
for (Core::IDocument *doc : Core::DocumentModel::openedDocuments())
|
||||
openDoc(doc);
|
||||
currentInstance = this;
|
||||
}
|
||||
|
||||
void CopilotClient::openDocument(TextDocument *document)
|
||||
|
@@ -25,8 +25,6 @@ class CopilotClient : public LanguageClient::Client
|
||||
public:
|
||||
explicit CopilotClient(const Utils::FilePath &nodePath, const Utils::FilePath &distPath);
|
||||
|
||||
static CopilotClient *instance();
|
||||
|
||||
void openDocument(TextEditor::TextDocument *document) override;
|
||||
|
||||
void scheduleRequest(TextEditor::TextEditorWidget *editor);
|
||||
|
Reference in New Issue
Block a user