MCPcopy Create free account
hub / github.com/baldurk/renderdoc / setRemoteServerLive

Method setRemoteServerLive

qrenderdoc/Windows/Dialogs/RemoteManager.cpp:135–169  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

133}
134
135void RemoteManager::setRemoteServerLive(RDTreeWidgetItem *node, bool live, bool busy)
136{
137 RemoteHost host = getRemoteHost(node);
138
139 if(!host.IsValid())
140 return;
141
142 if(host.IsLocalhost())
143 {
144 node->setIcon(0, QIcon());
145 node->setText(1, QString());
146 }
147 else
148 {
149 QString text = live ? tr("Remote server running") : tr("No remote server");
150
151 if(host.IsConnected())
152 {
153 text += tr(" (Active Context)");
154 }
155 else if(host.IsVersionMismatch())
156 {
157 QString message = host.VersionMismatchError();
158 text += QFormatStr(" (%1)").arg(message);
159 }
160 else if(host.IsBusy())
161 {
162 text += tr(" (Busy)");
163 }
164
165 node->setText(1, text);
166
167 node->setIcon(0, live ? Icons::connect() : Icons::disconnect());
168 }
169}
170
171void RemoteManager::addHost(RemoteHost host)
172{

Callers

nothing calls this directly

Calls 13

connectFunction · 0.85
disconnectFunction · 0.85
QIconFunction · 0.50
QStringFunction · 0.50
trFunction · 0.50
IsValidMethod · 0.45
setIconMethod · 0.45
setTextMethod · 0.45
IsConnectedMethod · 0.45
IsVersionMismatchMethod · 0.45
VersionMismatchErrorMethod · 0.45
argMethod · 0.45

Tested by

no test coverage detected