forked from qt-creator/qt-creator
LanguageClient: add a human readable version of client state
Change-Id: I650e4b4932f32ad86505e9be2fc85eef6bcd6edd Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
This commit is contained in:
@@ -340,6 +340,19 @@ Client::State Client::state() const
|
||||
return m_state;
|
||||
}
|
||||
|
||||
QString Client::stateString() const
|
||||
{
|
||||
switch (m_state){
|
||||
case Uninitialized: return tr("uninitialized");
|
||||
case InitializeRequested: return tr("initialize requested");
|
||||
case Initialized: return tr("initialized");
|
||||
case ShutdownRequested: return tr("shutdown requested");
|
||||
case Shutdown: return tr("shutdown");
|
||||
case Error: return tr("error");
|
||||
}
|
||||
return {};
|
||||
}
|
||||
|
||||
ClientCapabilities Client::defaultClientCapabilities()
|
||||
{
|
||||
return generateClientCapabilities();
|
||||
|
||||
Reference in New Issue
Block a user