Commit 32687bb2 authored by Jean-Baptiste Kempf's avatar Jean-Baptiste Kempf

Revert "Qt: fix crashes possible in Hotkey settings."

This reverts commit f5d10727.
parent 93387674
...@@ -1248,7 +1248,6 @@ void KeySelectorControl::finish() ...@@ -1248,7 +1248,6 @@ void KeySelectorControl::finish()
void KeySelectorControl::select1Key() void KeySelectorControl::select1Key()
{ {
QTreeWidgetItem *keyItem = table->currentItem(); QTreeWidgetItem *keyItem = table->currentItem();
if( !keyItem ) return;
shortcutValue->setText( keyItem->text( 1 ) ); shortcutValue->setText( keyItem->text( 1 ) );
shortcutValue->setValue( keyItem->data( 1, Qt::UserRole ).toInt() ); shortcutValue->setValue( keyItem->data( 1, Qt::UserRole ).toInt() );
} }
...@@ -1294,7 +1293,6 @@ void KeySelectorControl::selectKey( QTreeWidgetItem *keyItem ) ...@@ -1294,7 +1293,6 @@ void KeySelectorControl::selectKey( QTreeWidgetItem *keyItem )
void KeySelectorControl::setTheKey() void KeySelectorControl::setTheKey()
{ {
if( !table->currentItem() ) return;
table->currentItem()->setText( 1, shortcutValue->text() ); table->currentItem()->setText( 1, shortcutValue->text() );
table->currentItem()->setData( 1, Qt::UserRole, shortcutValue->getValue() ); table->currentItem()->setData( 1, Qt::UserRole, shortcutValue->getValue() );
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment