diff layer/ImageLayer.cpp @ 307:a66ff2059dae

* Add image layer icon (from GIMP) * If you cancel the dialog that pops up when you click to insert a new image or text point, ensure that the point is not added
author Chris Cannam
date Fri, 05 Oct 2007 16:31:30 +0000
parents 90b9cfb5b0bb
children 6de6f78b13a1
line wrap: on
line diff
--- a/layer/ImageLayer.cpp	Fri Oct 05 16:05:23 2007 +0000
+++ b/layer/ImageLayer.cpp	Fri Oct 05 16:31:30 2007 +0000
@@ -613,7 +613,7 @@
 
     bool ok = false;
 
-    ImageDialog dialog(tr("Select image"), "", tr("<no label>"));
+    ImageDialog dialog(tr("Select image"), "", "");
 
     if (dialog.exec() == QDialog::Accepted) {
 
@@ -623,6 +623,8 @@
 	    new ImageModel::ChangeImageCommand
             (m_model, m_editingPoint, dialog.getImage(), dialog.getLabel());
 	m_editingCommand->addCommand(command);
+    } else {
+        m_editingCommand->deletePoint(m_editingPoint);
     }
 
     m_editingCommand->finish();