#REFACTORING by cg
authorClaus Gittinger <cg@exept.de>
Sat, 20 Jul 2019 07:52:02 +0200
changeset 6645 f7254f12229e
parent 6644 e30cbb8927e2
child 6646 e2c1a572a33e
#REFACTORING by cg class: ListView added: #isLineFullyVisible: #isLineVisible: changed: #lineIsFullyVisible: #lineIsVisible:
ListView.st
--- a/ListView.st	Fri Jul 19 10:49:19 2019 +0200
+++ b/ListView.st	Sat Jul 20 07:52:02 2019 +0200
@@ -3621,6 +3621,25 @@
 "/    ^ (numLines + 1) * fontHeight
 !
 
+isLineFullyVisible:lineNr
+    "is line fully visible?"
+
+    (lineNr >= firstLineShown
+     and:[ lineNr < (firstLineShown + nFullLinesShown) ]) ifTrue:[ ^ true ].
+    ^ false.
+
+    "Created: / 20-07-2019 / 07:48:35 / Claus Gittinger"
+!
+
+isLineVisible:line
+    "is line visible?"
+
+    (line >= firstLineShown and:[ line < (firstLineShown + nLinesShown) ]) ifTrue:[ ^ true ].
+    ^ false.
+
+    "Created: / 20-07-2019 / 07:43:51 / Claus Gittinger"
+!
+
 lastLineShown
     "return the index of the last (possibly partial) visible line"
 
@@ -3683,21 +3702,23 @@
 
 !
 
-lineIsFullyVisible:line
+lineIsFullyVisible:lineNr
+    <resource: #obsolete>
     "is line fully visible?"
 
-    (line >= firstLineShown
-     and:[ line < (firstLineShown + nFullLinesShown) ]) ifTrue:[ ^ true ].
-    ^ false.
-
-    "Created: 26.4.1996 / 14:36:45 / cg"
+    ^ self isLineFullyVisible:lineNr
+
+    "Created: / 26-04-1996 / 14:36:45 / cg"
+    "Modified: / 20-07-2019 / 07:49:00 / Claus Gittinger"
 !
 
 lineIsVisible:line
+    <resource: #obsolete>
     "is line visible?"
 
-    (line >= firstLineShown and:[ line < (firstLineShown + nLinesShown) ]) ifTrue:[ ^ true ].
-    ^ false.
+    ^ self isLineVisible:line
+
+    "Modified: / 20-07-2019 / 07:44:07 / Claus Gittinger"
 !
 
 lineOfCharacterPosition:charPos