Update color scheme and key bindings list correctly after creating a new scheme/list. Save new schemes / bindings lists under a different name from the one used as a template. Get/set the description in the key binding editor.

svn path=/branches/work/konsole-split-view/; revision=661569
This commit is contained in:
Robert Knight
2007-05-06 00:03:54 +00:00
parent 19a29d182a
commit fe5f371635
6 changed files with 177 additions and 113 deletions

View File

@@ -34,6 +34,9 @@ KeyBindingEditor::KeyBindingEditor(QWidget* parent)
_ui = new Ui::KeyBindingEditor();
_ui->setupUi(this);
// description edit
connect( _ui->descriptionEdit , SIGNAL(textChanged(const QString&)) , this , SLOT(setDescription(const QString&)) );
// key bindings table
_ui->keyBindingTable->setColumnCount(2);
@@ -50,6 +53,21 @@ KeyBindingEditor::~KeyBindingEditor()
delete _ui;
}
void KeyBindingEditor::setDescription(const QString& newDescription)
{
if ( description() != newDescription )
{
_ui->descriptionEdit->setText(newDescription);
if ( _translator )
_translator->setDescription(newDescription);
}
}
QString KeyBindingEditor::description() const
{
return _ui->descriptionEdit->text();
}
void KeyBindingEditor::setup(const KeyboardTranslator* translator)
{
if ( _translator )