Exemple #1
0
bool CmdHelp::onClient(DebuggerClient *client) {
  if (DebuggerCommand::onClient(client)) return true;

  if (client->argCount() == 0) {
    HelpAll(client);
    return true;
  }

  if (client->arg(1, "start")) {
    HelpStarted(client);
    return true;
  }

  if (client->arg(1, "tutorial")) {
    if (!processTutorial(client)) {
      return help(client);
    }
  }

  client->swapHelp();
  if (client->process()) {
    return true;
  }

  return help(client);
}
Exemple #2
0
void CmdHelp::onClientImpl(DebuggerClient &client) {
  if (DebuggerCommand::displayedHelp(client)) return;
  if (client.argCount() == 0) {
    HelpAll(client);
   } else if (client.arg(1, "start")) {
    HelpStarted(client);
  } else if (client.arg(1, "tutorial")) {
    if (!processTutorial(client)) {
      help(client);
    }
  } else {
    client.swapHelp();
    if (!client.process()) {
      help(client);
    }
  }
}