#QUALITY by cg
class: ActiveHelp
class definition
changed:
#handleMouseIn:x:y:
#interestedIn:
#processEvent:
class: ActiveHelp class
changed: #initialize
--- a/ActiveHelp.st Fri Jun 15 11:16:09 2018 +0200
+++ b/ActiveHelp.st Tue Jun 19 14:43:47 2018 +0200
@@ -1,3 +1,5 @@
+"{ Encoding: utf8 }"
+
"
COPYRIGHT (c) 1995 by Claus Gittinger
All Rights Reserved
@@ -16,7 +18,7 @@
EventListener subclass:#ActiveHelp
instanceVariableNames:'lastHelpText listeningForAll applicationsOrTopViewsWithHelp
lastHelpWidget lastPointerPosition pointerPositionAtShowTime'
- classVariableNames:'Debugging DebuggingHelpText'
+ classVariableNames:'Debugging DebuggingHelpText DebuggingEvents'
poolDictionaries:''
category:'Interface-Help'
!
@@ -225,9 +227,10 @@
initialize
Debugging := false.
+ DebuggingEvents := false.
DebuggingHelpText := false.
- "Modified: / 11-06-2018 / 10:30:00 / Claus Gittinger"
+ "Modified: / 19-06-2018 / 12:53:36 / Claus Gittinger"
! !
!ActiveHelp class methodsFor:'accessing'!
@@ -431,9 +434,11 @@
"handle motion events - if the mousepointer left the
previous helped view, hide the help"
+ "/ Debugging := true.
+ "/ Debugging := false.
Debugging ifTrue:['mouse in' infoPrintCR].
(self interestedIn:aView) ifFalse:[
- Debugging ifTrue:['not interested 0' infoPrintCR].
+ Debugging ifTrue:[Timestamp now infoPrint. ' - not interested 0' infoPrintCR].
^ self
].
@@ -469,7 +474,8 @@
]
].
- "Modified (format): / 08-06-2018 / 10:17:12 / Claus Gittinger"
+ "Modified: / 19-06-2018 / 12:54:25 / Claus Gittinger"
+ "Modified (comment): / 19-06-2018 / 14:43:10 / Claus Gittinger"
!
keyPress:key x:x y:y view:view
@@ -504,7 +510,7 @@
!
processEvent:ev
- Debugging ifTrue:[
+ DebuggingEvents == true ifTrue:[
'event: ' infoPrint. ev class nameWithoutPrefix infoPrint.
' view:' infoPrint. ev view infoPrintCR.
].
@@ -516,6 +522,7 @@
^ false
"Created: / 29-06-2011 / 18:22:43 / cg"
+ "Modified: / 19-06-2018 / 12:53:28 / Claus Gittinger"
! !
!ActiveHelp methodsFor:'help texts'!
@@ -660,8 +667,20 @@
aViewsTopView := aView topView.
UserPreferences current onlyShowTooltipsForActiveWindow ifTrue:[
- aViewsTopView isActive ifFalse:[
- Debugging ifTrue:[ 'topview inactive' infoPrintCR].
+ aViewsTopView isActive ifFalse:[
+ Debugging ifTrue:[
+ |graphicsDevice focusVw|
+
+ 'topview inactive' infoPrintCR.
+ graphicsDevice := aViewsTopView graphicsDevice.
+ graphicsDevice notNil ifTrue:[
+ focusVw := graphicsDevice focusView.
+ 'focusView: ' infoPrint. focusVw infoPrintCR.
+ focusVw notNil ifTrue:[
+ 'wGroup: ' infoPrint. focusVw windowGroup infoPrintCR.
+ ]
+ ]
+ ].
^ false
].
@@ -684,13 +703,17 @@
].
(applicationsOrTopViewsWithHelp includesIdentical:aViewsTopView) ifTrue:[^ true].
app := aViewsTopView application.
- app notNil ifTrue:[
- (applicationsOrTopViewsWithHelp includesIdentical:app) ifTrue:[^ true]
+ app isNil ifTrue:[
+ Debugging ifTrue:['no app' infoPrintCR].
+ ^ false.
].
+ (applicationsOrTopViewsWithHelp includesIdentical:app) ifTrue:[^ true].
+ Debugging ifTrue:['not in list of apps I am interested in' infoPrintCR].
^ false
- "Created: / 26.10.1997 / 23:28:52 / cg"
- "Modified: / 8.8.1998 / 13:36:19 / cg"
+ "Created: / 26-10-1997 / 23:28:52 / cg"
+ "Modified: / 08-08-1998 / 13:36:19 / cg"
+ "Modified: / 19-06-2018 / 12:58:39 / Claus Gittinger"
!
targetViewInitiatesHelpViaSensor