* refactor: change console base 'component name' to 'default prompt' since that's the only thing it's being used for

0.6.0-stable
Justin Clarke Casey 2008-08-05 17:06:35 +00:00
parent b46e6e2130
commit 32486dcaf5
1 changed files with 13 additions and 4 deletions

View File

@ -42,11 +42,20 @@ namespace OpenSim.Framework.Console
private readonly object m_syncRoot = new object(); private readonly object m_syncRoot = new object();
public conscmd_callback m_cmdParser; public conscmd_callback m_cmdParser;
public string m_componentName;
public ConsoleBase(string componentname, conscmd_callback cmdparser) /// <summary>
/// The default prompt text.
/// </summary>
public string m_defaultPrompt;
/// <summary>
/// Constructor.
/// </summary>
/// <param name="defaultPrompt"></param>
/// <param name="cmdparser"></param>
public ConsoleBase(string defaultPrompt, conscmd_callback cmdparser)
{ {
m_componentName = componentname; m_defaultPrompt = defaultPrompt + "# ";
m_cmdParser = cmdparser; m_cmdParser = cmdparser;
} }
@ -362,7 +371,7 @@ namespace OpenSim.Framework.Console
public void Prompt() public void Prompt()
{ {
string tempstr = CmdPrompt(m_componentName + "# "); string tempstr = CmdPrompt(m_defaultPrompt);
RunCommand(tempstr); RunCommand(tempstr);
} }