Commit c1a661c2 authored by Matthias Möller's avatar Matthias Möller

remove new/delete

git-svn-id: http://www.openflipper.org/svnrepo/OpenFlipper/branches/Free@19199 383ad7c9-94d9-4d36-a494-682f7c89f535
parent 6439cd4b
...@@ -135,12 +135,10 @@ void CoreWidget::keyPressEvent(QKeyEvent* _e) ...@@ -135,12 +135,10 @@ void CoreWidget::keyPressEvent(QKeyEvent* _e)
// Map event to the plugins key and modifier. // Map event to the plugins key and modifier.
// Call it with the mapped event. // Call it with the mapped event.
// ================================================================================= // =================================================================================
QKeyEvent* mappedEvent = new QKeyEvent(_e->type(),binding.key, binding.modifiers, QKeyEvent mappedEvent(_e->type(),binding.key, binding.modifiers,
_e->text(), _e->isAutoRepeat(), _e->count() ); _e->text(), _e->isAutoRepeat(), _e->count() );
keyPlugin->slotKeyEvent(mappedEvent);
delete mappedEvent ; keyPlugin->slotKeyEvent(&mappedEvent);
} }
//if its not a multiUse key we are ready //if its not a multiUse key we are ready
...@@ -194,12 +192,10 @@ void CoreWidget::keyReleaseEvent(QKeyEvent* _e) { ...@@ -194,12 +192,10 @@ void CoreWidget::keyReleaseEvent(QKeyEvent* _e) {
// Call the plugin with the mapped event. // Call the plugin with the mapped event.
// ================================================================================= // =================================================================================
QKeyEvent* mappedEvent = new QKeyEvent(_e->type(),binding.key, binding.modifiers, QKeyEvent mappedEvent (_e->type(),binding.key, binding.modifiers,
_e->text(), _e->isAutoRepeat(), _e->count() ); _e->text(), _e->isAutoRepeat(), _e->count() );
keyPlugin->slotKeyReleaseEvent(mappedEvent);
delete mappedEvent; keyPlugin->slotKeyReleaseEvent(&mappedEvent);
} }
//if its not a multiUse key we are ready //if its not a multiUse key we are ready
......
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