Skip to content

Commit

Permalink
Shell: Cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
skyjake committed Jan 25, 2013
1 parent f0b4d22 commit 9d7882c
Showing 1 changed file with 12 additions and 13 deletions.
25 changes: 12 additions & 13 deletions doomsday/tools/shell/shell-text/src/commandlinewidget.cpp
Expand Up @@ -63,6 +63,18 @@ struct CommandLineWidget::Instance
return history[historyPos];
}

void updateCommandFromEditor()
{
command().text = self.text();
command().cursor = self.cursor();
}

void updateEditor()
{
self.setText(command().text);
self.setCursor(command().cursor);
}

bool navigateHistory(int offset)
{
if((offset < 0 && historyPos >= -offset) ||
Expand All @@ -79,18 +91,6 @@ struct CommandLineWidget::Instance
}
return false;
}

void updateCommandFromEditor()
{
command().text = self.text();
command().cursor = self.cursor();
}

void updateEditor()
{
self.setText(command().text);
self.setCursor(command().cursor);
}
};

CommandLineWidget::CommandLineWidget(de::String const &name)
Expand Down Expand Up @@ -170,4 +170,3 @@ bool CommandLineWidget::handleEvent(Event const *event)
return TextEditWidget::handleEvent(event);
}
}

0 comments on commit 9d7882c

Please sign in to comment.