# HG changeset patch # User ca # Date 872609811 -7200 # Node ID 1fd3867c08ccb001e3527488183fa2e6a0e45140 # Parent 1428bab2aa680799b314e19d2493247d4cf77673 an empty selection now is specified by 0 diff -r 1428bab2aa68 -r 1fd3867c08cc UISelectionPanel.st --- a/UISelectionPanel.st Tue Aug 26 17:36:19 1997 +0200 +++ b/UISelectionPanel.st Tue Aug 26 17:36:51 1997 +0200 @@ -1349,7 +1349,7 @@ isClipBoard "returns true if current view is clip board " - majorSelection notNil ifTrue:[ + majorSelection ~~ 0 ifTrue:[ ^ (self majorList at:majorSelection) startsWith:'Clip' ]. ^ false @@ -1358,7 +1358,7 @@ isUserBoard "returns true if current view is clip board " - majorSelection notNil ifTrue:[ + majorSelection ~~ 0 ifTrue:[ ^ (self majorList at:majorSelection) startsWith:'User' ]. ^ false @@ -1367,13 +1367,13 @@ !UISelectionPanel methodsFor:'selection'! majorSelection - ^ majorSelection + ^ majorSelection ? 0 ! majorSelection:aSelection |spec channel| - (majorSelection == aSelection or:[aSelection isNil]) ifTrue:[ + (majorSelection == aSelection or:[aSelection == 0]) ifTrue:[ ^ self ]. (self builder componentAt:#gallery) builder:nil. @@ -1420,6 +1420,11 @@ "Modified: 28.7.1997 / 09:44:40 / cg" ! +initialize + super initialize. + majorSelection := 0. +! + openWindow "setup default values "