UIPainterView.st
changeset 2951 c2b24bf7b967
parent 2853 1eadca551eed
child 2963 7df17046fc89
--- a/UIPainterView.st	Mon Jan 21 14:47:47 2013 +0100
+++ b/UIPainterView.st	Mon Jan 21 14:48:16 2013 +0100
@@ -15,7 +15,8 @@
 	instanceVariableNames:'treeView listHolder superclassName className methodName
 		categoryName handleColorBlack handleColorWhite handleMasterColor
 		sketchPainter listOfAspectsHolder'
-	classVariableNames:'HandCursor RedefineAspectMethods AspectsAsInstances'
+	classVariableNames:'HandCursor RedefineAspectMethods AspectsAsInstances
+		ClipboardContents'
 	poolDictionaries:''
 	category:'Interface-UIPainter'
 !
@@ -363,8 +364,12 @@
     ]. 
 
     clipboard := self getClipboardObject.
-    sel := self pasteSpecifications:clipboard keepLayout:true "(clipboard size > 1)".
-    self changeSelectionAfterPasteOf:sel.
+    clipboard isString ifTrue:[
+        Dialog warn:'can only paste widgets here'.
+    ] ifFalse:[
+        sel := self pasteSpecifications:clipboard keepLayout:true "(clipboard size > 1)".
+        self changeSelectionAfterPasteOf:sel.
+    ].
 !
 
 pasteKeepingPosition
@@ -444,7 +449,7 @@
         self enabled ifTrue:[
             Dialog warn:'Cannot paste into selected component (not a container ?)'.
         ] ifFalse:[
-            Dialog warn:'Operation currently disabled (In Geometry test mode)'.
+            Dialog warn:'Operation currently disabled (In geometry test mode)'.
         ]. 
         ^ nil
     ].
@@ -3095,4 +3100,5 @@
     ^ '$Header$'
 ! !
 
+
 UIPainterView initialize!