LinkButton.st
changeset 4985 818d298db0df
parent 4681 b97620c35200
child 4987 82bb0a9fecdb
child 5010 48191c4158e8
--- a/LinkButton.st	Wed Mar 30 16:10:13 2016 +0200
+++ b/LinkButton.st	Fri Apr 01 22:38:22 2016 +0200
@@ -1,5 +1,9 @@
+"{ Encoding: utf8 }"
+
 "{ Package: 'stx:libwidg2' }"
 
+"{ NameSpace: Smalltalk }"
+
 Button subclass:#LinkButton
 	instanceVariableNames:'labelsAndActions'
 	classVariableNames:'DefaultLinkColor'
@@ -84,6 +88,17 @@
     l foregroundColor:Color blue.
     v open
                                                                     [exEnd]
+    Dialog aboutToOpenBoxNotificationSignal handle:[:ex |
+        |lbl|
+
+        lbl := LinkButton label:(('XXX' 
+                                        colorizeAllWith:Color blue)
+                                        actionForAll:[ Transcript showCR:'xxx' ]).
+        ex box verticalPanel addComponent:lbl.
+    ] do:[
+        self warn:'Bla bla bla'
+    ].
+
 "
 ! !
 
@@ -166,7 +181,7 @@
     labelsAndActions isNil ifTrue:[
         "take action from logo, which is normally a text"
 
-        emphasis := logo emphasisAtPoint:aPoint on:self.
+        emphasis := logo emphasisAtPoint:(aPoint - (labelOriginX@labelOriginY)) on:self. 
         (emphasis isNil or:[emphasis isSymbol]) ifTrue:[
             ^ pressAction.
         ].
@@ -317,10 +332,10 @@
 !LinkButton class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libwidg2/LinkButton.st,v 1.13 2014-12-02 18:35:56 cg Exp $'
+    ^ '$Header$'
 !
 
 version_CVS
-    ^ '$Header: /cvs/stx/stx/libwidg2/LinkButton.st,v 1.13 2014-12-02 18:35:56 cg Exp $'
+    ^ '$Header$'
 ! !