ComboView.st
author Michael Beyl <mb@exept.de>
Tue, 08 Apr 2003 16:13:25 +0200
changeset 2477 994d88ef4334
parent 2474 173a07117f56
child 2499 a2b676b9292c
permissions -rw-r--r--
*** empty log message ***
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
1301
93a3ec8c339c OOPS - stefan what happened to your checkin (garbage)
Claus Gittinger <cg@exept.de>
parents: 1294
diff changeset
     1
"
332
78dcd3cacbfd documentation
Claus Gittinger <cg@exept.de>
parents: 331
diff changeset
     2
 COPYRIGHT (c) 1996 by eXept Software AG / Claus Gittinger
78dcd3cacbfd documentation
Claus Gittinger <cg@exept.de>
parents: 331
diff changeset
     3
              All Rights Reserved
78dcd3cacbfd documentation
Claus Gittinger <cg@exept.de>
parents: 331
diff changeset
     4
78dcd3cacbfd documentation
Claus Gittinger <cg@exept.de>
parents: 331
diff changeset
     5
 This software is furnished under a license and may be used
78dcd3cacbfd documentation
Claus Gittinger <cg@exept.de>
parents: 331
diff changeset
     6
 only in accordance with the terms of that license and with the
78dcd3cacbfd documentation
Claus Gittinger <cg@exept.de>
parents: 331
diff changeset
     7
 inclusion of the above copyright notice.   This software may not
78dcd3cacbfd documentation
Claus Gittinger <cg@exept.de>
parents: 331
diff changeset
     8
 be provided or otherwise made available to, or used by, any
78dcd3cacbfd documentation
Claus Gittinger <cg@exept.de>
parents: 331
diff changeset
     9
 other person.  No title to or ownership of the software is
78dcd3cacbfd documentation
Claus Gittinger <cg@exept.de>
parents: 331
diff changeset
    10
 hereby transferred.
78dcd3cacbfd documentation
Claus Gittinger <cg@exept.de>
parents: 331
diff changeset
    11
"
78dcd3cacbfd documentation
Claus Gittinger <cg@exept.de>
parents: 331
diff changeset
    12
78dcd3cacbfd documentation
Claus Gittinger <cg@exept.de>
parents: 331
diff changeset
    13
78dcd3cacbfd documentation
Claus Gittinger <cg@exept.de>
parents: 331
diff changeset
    14
1884
bf33562ea53b use rootWindowId (save a message send)
Claus Gittinger <cg@exept.de>
parents: 1696
diff changeset
    15
"{ Package: 'stx:libwidg2' }"
bf33562ea53b use rootWindowId (save a message send)
Claus Gittinger <cg@exept.de>
parents: 1696
diff changeset
    16
129
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    17
View subclass:#ComboView
1306
56e90a9e5da1 renambe #enableStateChange to #enableStateChanged
Claus Gittinger <cg@exept.de>
parents: 1301
diff changeset
    18
	instanceVariableNames:'field pullDownButton list listHolder listMsg action'
56e90a9e5da1 renambe #enableStateChange to #enableStateChanged
Claus Gittinger <cg@exept.de>
parents: 1301
diff changeset
    19
	classVariableNames:'DefaultButtonForm'
56e90a9e5da1 renambe #enableStateChange to #enableStateChanged
Claus Gittinger <cg@exept.de>
parents: 1301
diff changeset
    20
	poolDictionaries:''
56e90a9e5da1 renambe #enableStateChange to #enableStateChanged
Claus Gittinger <cg@exept.de>
parents: 1301
diff changeset
    21
	category:'Views-Interactors'
129
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    22
!
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    23
263
865b7d99d3f5 added an example for a menu-pull-hook
Claus Gittinger <cg@exept.de>
parents: 247
diff changeset
    24
!ComboView class methodsFor:'documentation'!
129
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    25
332
78dcd3cacbfd documentation
Claus Gittinger <cg@exept.de>
parents: 331
diff changeset
    26
copyright
78dcd3cacbfd documentation
Claus Gittinger <cg@exept.de>
parents: 331
diff changeset
    27
"
78dcd3cacbfd documentation
Claus Gittinger <cg@exept.de>
parents: 331
diff changeset
    28
 COPYRIGHT (c) 1996 by eXept Software AG / Claus Gittinger
78dcd3cacbfd documentation
Claus Gittinger <cg@exept.de>
parents: 331
diff changeset
    29
              All Rights Reserved
78dcd3cacbfd documentation
Claus Gittinger <cg@exept.de>
parents: 331
diff changeset
    30
78dcd3cacbfd documentation
Claus Gittinger <cg@exept.de>
parents: 331
diff changeset
    31
 This software is furnished under a license and may be used
78dcd3cacbfd documentation
Claus Gittinger <cg@exept.de>
parents: 331
diff changeset
    32
 only in accordance with the terms of that license and with the
78dcd3cacbfd documentation
Claus Gittinger <cg@exept.de>
parents: 331
diff changeset
    33
 inclusion of the above copyright notice.   This software may not
78dcd3cacbfd documentation
Claus Gittinger <cg@exept.de>
parents: 331
diff changeset
    34
 be provided or otherwise made available to, or used by, any
78dcd3cacbfd documentation
Claus Gittinger <cg@exept.de>
parents: 331
diff changeset
    35
 other person.  No title to or ownership of the software is
78dcd3cacbfd documentation
Claus Gittinger <cg@exept.de>
parents: 331
diff changeset
    36
 hereby transferred.
78dcd3cacbfd documentation
Claus Gittinger <cg@exept.de>
parents: 331
diff changeset
    37
"
78dcd3cacbfd documentation
Claus Gittinger <cg@exept.de>
parents: 331
diff changeset
    38
78dcd3cacbfd documentation
Claus Gittinger <cg@exept.de>
parents: 331
diff changeset
    39
78dcd3cacbfd documentation
Claus Gittinger <cg@exept.de>
parents: 331
diff changeset
    40
!
78dcd3cacbfd documentation
Claus Gittinger <cg@exept.de>
parents: 331
diff changeset
    41
129
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    42
documentation
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    43
"
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    44
    A ComboView combines some field (typically an enterField or Label)
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    45
    with a drop down list of default inputs;
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    46
    ComboView is abstract, providing protocol common to ComboBoxView and
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    47
    ComboListView. See documentation & examples there.
274
92b51554b1d7 allow form to be specified by styleSheet
Claus Gittinger <cg@exept.de>
parents: 269
diff changeset
    48
92b51554b1d7 allow form to be specified by styleSheet
Claus Gittinger <cg@exept.de>
parents: 269
diff changeset
    49
    [author:]
92b51554b1d7 allow form to be specified by styleSheet
Claus Gittinger <cg@exept.de>
parents: 269
diff changeset
    50
        Claus Gittinger
92b51554b1d7 allow form to be specified by styleSheet
Claus Gittinger <cg@exept.de>
parents: 269
diff changeset
    51
92b51554b1d7 allow form to be specified by styleSheet
Claus Gittinger <cg@exept.de>
parents: 269
diff changeset
    52
    [see also:]
92b51554b1d7 allow form to be specified by styleSheet
Claus Gittinger <cg@exept.de>
parents: 269
diff changeset
    53
        PopUpList
1281
94b22cb9c19f documentation
Claus Gittinger <cg@exept.de>
parents: 1210
diff changeset
    54
        ComboListView ComboBoxView ExtendedComboBox
274
92b51554b1d7 allow form to be specified by styleSheet
Claus Gittinger <cg@exept.de>
parents: 269
diff changeset
    55
        PullDownMenu Label EntryField
129
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    56
"
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    57
!
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    58
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    59
examples
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    60
"
308
922a96deba3e examples removed; cleanup
Claus Gittinger <cg@exept.de>
parents: 304
diff changeset
    61
  see examples in ComboListView and ComboBoxView
129
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    62
"
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    63
! !
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    64
263
865b7d99d3f5 added an example for a menu-pull-hook
Claus Gittinger <cg@exept.de>
parents: 247
diff changeset
    65
!ComboView class methodsFor:'defaults'!
129
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    66
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    67
buttonForm
282
95209b20eaca commentary
Claus Gittinger <cg@exept.de>
parents: 280
diff changeset
    68
    "return the pull-buttons image"
95209b20eaca commentary
Claus Gittinger <cg@exept.de>
parents: 280
diff changeset
    69
1344
100e4d309847 support for disabled-image in pull-button
Claus Gittinger <cg@exept.de>
parents: 1334
diff changeset
    70
    <resource: #style (#'comboView.downForm' 
100e4d309847 support for disabled-image in pull-button
Claus Gittinger <cg@exept.de>
parents: 1334
diff changeset
    71
                       #'comboView.downFormFile')>
274
92b51554b1d7 allow form to be specified by styleSheet
Claus Gittinger <cg@exept.de>
parents: 269
diff changeset
    72
276
8f90ed6c37bc allow either fileName or form to be given by styleSheet
Claus Gittinger <cg@exept.de>
parents: 274
diff changeset
    73
    |fileName form|
129
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    74
525
d0731a41d19f cache the pull-button image
Claus Gittinger <cg@exept.de>
parents: 512
diff changeset
    75
    DefaultButtonForm notNil ifTrue:[
d0731a41d19f cache the pull-button image
Claus Gittinger <cg@exept.de>
parents: 512
diff changeset
    76
        ^ DefaultButtonForm
d0731a41d19f cache the pull-button image
Claus Gittinger <cg@exept.de>
parents: 512
diff changeset
    77
    ].
d0731a41d19f cache the pull-button image
Claus Gittinger <cg@exept.de>
parents: 512
diff changeset
    78
1334
cc79acaebf00 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1325
diff changeset
    79
    form := StyleSheet at:#'comboView.downForm'.
274
92b51554b1d7 allow form to be specified by styleSheet
Claus Gittinger <cg@exept.de>
parents: 269
diff changeset
    80
    form isNil ifTrue:[
1334
cc79acaebf00 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1325
diff changeset
    81
        fileName := StyleSheet at:#'comboView.downFormFile' "default:'ComboDn.14.xbm'".
1622
ea4d9baf568f try bitmaps in package directory
Claus Gittinger <cg@exept.de>
parents: 1560
diff changeset
    82
        fileName notNil ifTrue:[
1633
e3b4e18f4545 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1622
diff changeset
    83
            form := Smalltalk imageFromFileNamed:fileName forClass:self.
2174
ab242e29da64 button init code made publicly available
Claus Gittinger <cg@exept.de>
parents: 2157
diff changeset
    84
            form isNil ifTrue:[
ab242e29da64 button init code made publicly available
Claus Gittinger <cg@exept.de>
parents: 2157
diff changeset
    85
                form := Smalltalk imageFromFileNamed:fileName inPackage:'stx:libwidg'.
ab242e29da64 button init code made publicly available
Claus Gittinger <cg@exept.de>
parents: 2157
diff changeset
    86
            ]
1622
ea4d9baf568f try bitmaps in package directory
Claus Gittinger <cg@exept.de>
parents: 1560
diff changeset
    87
        ].
274
92b51554b1d7 allow form to be specified by styleSheet
Claus Gittinger <cg@exept.de>
parents: 269
diff changeset
    88
    ].
92b51554b1d7 allow form to be specified by styleSheet
Claus Gittinger <cg@exept.de>
parents: 269
diff changeset
    89
    form isNil ifTrue:[
605
a8da1eb4e180 smaller button
Claus Gittinger <cg@exept.de>
parents: 581
diff changeset
    90
        form  := Form width:12 height:12 
274
92b51554b1d7 allow form to be specified by styleSheet
Claus Gittinger <cg@exept.de>
parents: 269
diff changeset
    91
                      fromArray:#[2r00000000 2r00000000
605
a8da1eb4e180 smaller button
Claus Gittinger <cg@exept.de>
parents: 581
diff changeset
    92
                                  "/ 2r00001111 2r00000000
a8da1eb4e180 smaller button
Claus Gittinger <cg@exept.de>
parents: 581
diff changeset
    93
                                  "/ 2r00001111 2r00000000
a8da1eb4e180 smaller button
Claus Gittinger <cg@exept.de>
parents: 581
diff changeset
    94
                                  2r00001111 2r00000000
a8da1eb4e180 smaller button
Claus Gittinger <cg@exept.de>
parents: 581
diff changeset
    95
                                  2r00001111 2r00000000
a8da1eb4e180 smaller button
Claus Gittinger <cg@exept.de>
parents: 581
diff changeset
    96
                                  2r00001111 2r00000000
a8da1eb4e180 smaller button
Claus Gittinger <cg@exept.de>
parents: 581
diff changeset
    97
                                  2r01111111 2r11100000
a8da1eb4e180 smaller button
Claus Gittinger <cg@exept.de>
parents: 581
diff changeset
    98
                                  2r00111111 2r11000000
a8da1eb4e180 smaller button
Claus Gittinger <cg@exept.de>
parents: 581
diff changeset
    99
                                  2r00011111 2r10000000
a8da1eb4e180 smaller button
Claus Gittinger <cg@exept.de>
parents: 581
diff changeset
   100
                                  2r00001111 2r00000000
a8da1eb4e180 smaller button
Claus Gittinger <cg@exept.de>
parents: 581
diff changeset
   101
                                  2r00000110 2r00000000
274
92b51554b1d7 allow form to be specified by styleSheet
Claus Gittinger <cg@exept.de>
parents: 269
diff changeset
   102
                                  2r00000000 2r00000000
605
a8da1eb4e180 smaller button
Claus Gittinger <cg@exept.de>
parents: 581
diff changeset
   103
                                  2r01111111 2r11100000
274
92b51554b1d7 allow form to be specified by styleSheet
Claus Gittinger <cg@exept.de>
parents: 269
diff changeset
   104
                                  2r00000000 2r00000000]
92b51554b1d7 allow form to be specified by styleSheet
Claus Gittinger <cg@exept.de>
parents: 269
diff changeset
   105
                      on:Display.
92b51554b1d7 allow form to be specified by styleSheet
Claus Gittinger <cg@exept.de>
parents: 269
diff changeset
   106
    ].
92b51554b1d7 allow form to be specified by styleSheet
Claus Gittinger <cg@exept.de>
parents: 269
diff changeset
   107
    form notNil ifTrue:[
525
d0731a41d19f cache the pull-button image
Claus Gittinger <cg@exept.de>
parents: 512
diff changeset
   108
        form := DefaultButtonForm := form onDevice:Display.
d0731a41d19f cache the pull-button image
Claus Gittinger <cg@exept.de>
parents: 512
diff changeset
   109
        ^ form
274
92b51554b1d7 allow form to be specified by styleSheet
Claus Gittinger <cg@exept.de>
parents: 269
diff changeset
   110
    ].
92b51554b1d7 allow form to be specified by styleSheet
Claus Gittinger <cg@exept.de>
parents: 269
diff changeset
   111
    ^ nil
92b51554b1d7 allow form to be specified by styleSheet
Claus Gittinger <cg@exept.de>
parents: 269
diff changeset
   112
1344
100e4d309847 support for disabled-image in pull-button
Claus Gittinger <cg@exept.de>
parents: 1334
diff changeset
   113
    "Modified: / 28.4.1999 / 12:49:42 / cg"
304
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   114
!
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   115
2174
ab242e29da64 button init code made publicly available
Claus Gittinger <cg@exept.de>
parents: 2157
diff changeset
   116
comboButtonFor:anInstance
ab242e29da64 button init code made publicly available
Claus Gittinger <cg@exept.de>
parents: 2157
diff changeset
   117
    <resource: #style (#'comboView.disabledDownForm' 
ab242e29da64 button init code made publicly available
Claus Gittinger <cg@exept.de>
parents: 2157
diff changeset
   118
                       #'comboView.disabledDownFormFile'
2176
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   119
                       #'comboView.activeDownFormFile'
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   120
                       #'comboView.button.activeForegroundColor'
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   121
                       #'comboView.button.activeBackgroundColor'
2174
ab242e29da64 button init code made publicly available
Claus Gittinger <cg@exept.de>
parents: 2157
diff changeset
   122
                       #'comboView.button.activeLevel'
ab242e29da64 button init code made publicly available
Claus Gittinger <cg@exept.de>
parents: 2157
diff changeset
   123
                       #'comboView.button.passiveLevel'  )>
ab242e29da64 button init code made publicly available
Claus Gittinger <cg@exept.de>
parents: 2157
diff changeset
   124
2176
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   125
    |pullDownButton fn logo disabledLogo activeLogo enteredLogo lvl clr|
2174
ab242e29da64 button init code made publicly available
Claus Gittinger <cg@exept.de>
parents: 2157
diff changeset
   126
ab242e29da64 button init code made publicly available
Claus Gittinger <cg@exept.de>
parents: 2157
diff changeset
   127
    pullDownButton := ComboBoxButton in:anInstance.
ab242e29da64 button init code made publicly available
Claus Gittinger <cg@exept.de>
parents: 2157
diff changeset
   128
    pullDownButton controller beTriggerOnDown.
2176
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   129
    pullDownButton logo:(logo := self buttonForm).
2174
ab242e29da64 button init code made publicly available
Claus Gittinger <cg@exept.de>
parents: 2157
diff changeset
   130
2176
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   131
    disabledLogo := StyleSheet at:#'comboView.disabledDownForm'.
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   132
    disabledLogo isNil ifTrue:[
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   133
        fn := StyleSheet at:#'comboView.disabledDownFormFile'.
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   134
        fn notNil ifTrue:[
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   135
            disabledLogo := Smalltalk imageFromFileNamed:fn forClass:self.
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   136
            disabledLogo isNil ifTrue:[
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   137
                disabledLogo := Smalltalk imageFromFileNamed:fn inPackage:'stx:libwidg'.
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   138
            ]
2174
ab242e29da64 button init code made publicly available
Claus Gittinger <cg@exept.de>
parents: 2157
diff changeset
   139
        ]
ab242e29da64 button init code made publicly available
Claus Gittinger <cg@exept.de>
parents: 2157
diff changeset
   140
    ].    
2176
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   141
    disabledLogo notNil ifTrue:[
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   142
        pullDownButton passiveLogo:logo.
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   143
        pullDownButton activeLogo:logo.
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   144
        pullDownButton disabledLogo:disabledLogo.
2174
ab242e29da64 button init code made publicly available
Claus Gittinger <cg@exept.de>
parents: 2157
diff changeset
   145
    ].
ab242e29da64 button init code made publicly available
Claus Gittinger <cg@exept.de>
parents: 2157
diff changeset
   146
    pullDownButton showLamp:false.
ab242e29da64 button init code made publicly available
Claus Gittinger <cg@exept.de>
parents: 2157
diff changeset
   147
2176
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   148
    activeLogo := StyleSheet at:#'comboView.activeDownForm'.
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   149
    activeLogo isNil ifTrue:[
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   150
        fn := StyleSheet at:#'comboView.activeDownFormFile'.
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   151
        fn notNil ifTrue:[
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   152
            activeLogo := Smalltalk imageFromFileNamed:fn forClass:self.
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   153
            activeLogo isNil ifTrue:[
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   154
                activeLogo := Smalltalk imageFromFileNamed:fn inPackage:'stx:libwidg'.
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   155
            ]
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   156
        ]
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   157
    ].    
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   158
    activeLogo notNil ifTrue:[
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   159
        pullDownButton activeLogo:activeLogo.
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   160
        pullDownButton passiveLogo:logo.
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   161
        pullDownButton logo:logo.
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   162
    ].
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   163
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   164
    enteredLogo := StyleSheet at:#'comboView.enteredDownForm'.
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   165
    enteredLogo isNil ifTrue:[
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   166
        fn := StyleSheet at:#'comboView.enteredDownFormFile'.
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   167
        fn notNil ifTrue:[
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   168
            enteredLogo := Smalltalk imageFromFileNamed:fn forClass:self.
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   169
            enteredLogo isNil ifTrue:[
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   170
                enteredLogo := Smalltalk imageFromFileNamed:fn inPackage:'stx:libwidg'.
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   171
            ]
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   172
        ]
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   173
    ].    
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   174
    enteredLogo notNil ifTrue:[
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   175
        pullDownButton enteredLogo:enteredLogo.
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   176
    ].
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   177
2174
ab242e29da64 button init code made publicly available
Claus Gittinger <cg@exept.de>
parents: 2157
diff changeset
   178
    (lvl := StyleSheet at:#'comboView.button.activeLevel') notNil ifTrue:[
ab242e29da64 button init code made publicly available
Claus Gittinger <cg@exept.de>
parents: 2157
diff changeset
   179
        pullDownButton activeLevel:lvl
ab242e29da64 button init code made publicly available
Claus Gittinger <cg@exept.de>
parents: 2157
diff changeset
   180
    ].
ab242e29da64 button init code made publicly available
Claus Gittinger <cg@exept.de>
parents: 2157
diff changeset
   181
    (lvl := StyleSheet at:#'comboView.button.passiveLevel') notNil ifTrue:[
ab242e29da64 button init code made publicly available
Claus Gittinger <cg@exept.de>
parents: 2157
diff changeset
   182
        pullDownButton passiveLevel:lvl
ab242e29da64 button init code made publicly available
Claus Gittinger <cg@exept.de>
parents: 2157
diff changeset
   183
    ].
ab242e29da64 button init code made publicly available
Claus Gittinger <cg@exept.de>
parents: 2157
diff changeset
   184
2176
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   185
    (clr := StyleSheet colorAt:#'comboView.button.activeForegroundColor') notNil ifTrue:[
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   186
        pullDownButton activeForegroundColor:clr
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   187
    ].
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   188
    (clr := StyleSheet colorAt:#'comboView.button.activeBackgroundColor') notNil ifTrue:[
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   189
        pullDownButton activeBackgroundColor:clr
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   190
    ].
a4ddd3e25bee background from styleSheet
Claus Gittinger <cg@exept.de>
parents: 2174
diff changeset
   191
2174
ab242e29da64 button init code made publicly available
Claus Gittinger <cg@exept.de>
parents: 2157
diff changeset
   192
    pullDownButton activeLevel == pullDownButton passiveLevel ifTrue:[
ab242e29da64 button init code made publicly available
Claus Gittinger <cg@exept.de>
parents: 2157
diff changeset
   193
        pullDownButton activeLevel:0.
ab242e29da64 button init code made publicly available
Claus Gittinger <cg@exept.de>
parents: 2157
diff changeset
   194
    ].
ab242e29da64 button init code made publicly available
Claus Gittinger <cg@exept.de>
parents: 2157
diff changeset
   195
    ^ pullDownButton.
ab242e29da64 button init code made publicly available
Claus Gittinger <cg@exept.de>
parents: 2157
diff changeset
   196
!
ab242e29da64 button init code made publicly available
Claus Gittinger <cg@exept.de>
parents: 2157
diff changeset
   197
415
82d22b1ce5f5 defaultFont
Claus Gittinger <cg@exept.de>
parents: 411
diff changeset
   198
defaultFont
82d22b1ce5f5 defaultFont
Claus Gittinger <cg@exept.de>
parents: 411
diff changeset
   199
    "/ for now - should come from the styleSheet
82d22b1ce5f5 defaultFont
Claus Gittinger <cg@exept.de>
parents: 411
diff changeset
   200
82d22b1ce5f5 defaultFont
Claus Gittinger <cg@exept.de>
parents: 411
diff changeset
   201
    ^ SelectionInListView defaultFont.
82d22b1ce5f5 defaultFont
Claus Gittinger <cg@exept.de>
parents: 411
diff changeset
   202
82d22b1ce5f5 defaultFont
Claus Gittinger <cg@exept.de>
parents: 411
diff changeset
   203
    "Created: 4.6.1997 / 15:44:17 / cg"
82d22b1ce5f5 defaultFont
Claus Gittinger <cg@exept.de>
parents: 411
diff changeset
   204
!
82d22b1ce5f5 defaultFont
Claus Gittinger <cg@exept.de>
parents: 411
diff changeset
   205
304
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   206
defaultListMessage
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   207
    ^ #list
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   208
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   209
    "Created: 26.2.1997 / 19:34:50 / cg"
605
a8da1eb4e180 smaller button
Claus Gittinger <cg@exept.de>
parents: 581
diff changeset
   210
!
a8da1eb4e180 smaller button
Claus Gittinger <cg@exept.de>
parents: 581
diff changeset
   211
a8da1eb4e180 smaller button
Claus Gittinger <cg@exept.de>
parents: 581
diff changeset
   212
updateStyleCache
a8da1eb4e180 smaller button
Claus Gittinger <cg@exept.de>
parents: 581
diff changeset
   213
    DefaultButtonForm := nil
a8da1eb4e180 smaller button
Claus Gittinger <cg@exept.de>
parents: 581
diff changeset
   214
a8da1eb4e180 smaller button
Claus Gittinger <cg@exept.de>
parents: 581
diff changeset
   215
    "Created: / 3.11.1997 / 15:28:48 / cg"
304
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   216
! !
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   217
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   218
!ComboView methodsFor:'accessing-behavior'!
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   219
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   220
action:aBlock
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   221
    "specify, a block, which is evaluated when the lists selection changes.
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   222
     This is an additional hook - normally, you would communicate with the model
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   223
     alone"
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   224
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   225
    action := aBlock.
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   226
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   227
    "Created: 26.7.1996 / 17:44:18 / cg"
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   228
    "Modified: 26.2.1997 / 19:37:18 / cg"
411
5a32b4247011 delegate font:
ca
parents: 332
diff changeset
   229
!
5a32b4247011 delegate font:
ca
parents: 332
diff changeset
   230
5a32b4247011 delegate font:
ca
parents: 332
diff changeset
   231
enabled
5a32b4247011 delegate font:
ca
parents: 332
diff changeset
   232
    "return true, if is enabled
5a32b4247011 delegate font:
ca
parents: 332
diff changeset
   233
    "
1207
9019fe235f32 do not share my enableChannel with my buttons channel
tm
parents: 1183
diff changeset
   234
    enableChannel isNil ifTrue:[^ true].
1294
36a0e9dcd813 Move common channels to View.
Stefan Vogel <sv@exept.de>
parents: 1291
diff changeset
   235
    ^ enableChannel value
36a0e9dcd813 Move common channels to View.
Stefan Vogel <sv@exept.de>
parents: 1291
diff changeset
   236
!
36a0e9dcd813 Move common channels to View.
Stefan Vogel <sv@exept.de>
parents: 1291
diff changeset
   237
36a0e9dcd813 Move common channels to View.
Stefan Vogel <sv@exept.de>
parents: 1291
diff changeset
   238
enabled:aBoolean
36a0e9dcd813 Move common channels to View.
Stefan Vogel <sv@exept.de>
parents: 1291
diff changeset
   239
    "enable/disable components"
36a0e9dcd813 Move common channels to View.
Stefan Vogel <sv@exept.de>
parents: 1291
diff changeset
   240
36a0e9dcd813 Move common channels to View.
Stefan Vogel <sv@exept.de>
parents: 1291
diff changeset
   241
    self enableChannel value:aBoolean.
36a0e9dcd813 Move common channels to View.
Stefan Vogel <sv@exept.de>
parents: 1291
diff changeset
   242
36a0e9dcd813 Move common channels to View.
Stefan Vogel <sv@exept.de>
parents: 1291
diff changeset
   243
    "Modified: / 30.3.1999 / 14:56:18 / stefan"
411
5a32b4247011 delegate font:
ca
parents: 332
diff changeset
   244
! !
5a32b4247011 delegate font:
ca
parents: 332
diff changeset
   245
5a32b4247011 delegate font:
ca
parents: 332
diff changeset
   246
!ComboView methodsFor:'accessing-channels'!
5a32b4247011 delegate font:
ca
parents: 332
diff changeset
   247
5a32b4247011 delegate font:
ca
parents: 332
diff changeset
   248
enableChannel 
5a32b4247011 delegate font:
ca
parents: 332
diff changeset
   249
    "return a valueHolder for enable/disable
5a32b4247011 delegate font:
ca
parents: 332
diff changeset
   250
    "
1207
9019fe235f32 do not share my enableChannel with my buttons channel
tm
parents: 1183
diff changeset
   251
    enableChannel isNil ifTrue:[
1294
36a0e9dcd813 Move common channels to View.
Stefan Vogel <sv@exept.de>
parents: 1291
diff changeset
   252
        self enableChannel:(true asValue).
411
5a32b4247011 delegate font:
ca
parents: 332
diff changeset
   253
    ].
1207
9019fe235f32 do not share my enableChannel with my buttons channel
tm
parents: 1183
diff changeset
   254
    ^ enableChannel
411
5a32b4247011 delegate font:
ca
parents: 332
diff changeset
   255
1294
36a0e9dcd813 Move common channels to View.
Stefan Vogel <sv@exept.de>
parents: 1291
diff changeset
   256
    "Modified: / 30.3.1999 / 16:20:25 / stefan"
129
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   257
! !
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   258
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   259
!ComboView methodsFor:'accessing-components'!
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   260
1560
8abb4de4f8f5 added access to field.
Claus Gittinger <cg@exept.de>
parents: 1544
diff changeset
   261
field
8abb4de4f8f5 added access to field.
Claus Gittinger <cg@exept.de>
parents: 1544
diff changeset
   262
    "return the field (input or label) component.
8abb4de4f8f5 added access to field.
Claus Gittinger <cg@exept.de>
parents: 1544
diff changeset
   263
     For knowledgable users only."
8abb4de4f8f5 added access to field.
Claus Gittinger <cg@exept.de>
parents: 1544
diff changeset
   264
8abb4de4f8f5 added access to field.
Claus Gittinger <cg@exept.de>
parents: 1544
diff changeset
   265
    ^ field
8abb4de4f8f5 added access to field.
Claus Gittinger <cg@exept.de>
parents: 1544
diff changeset
   266
8abb4de4f8f5 added access to field.
Claus Gittinger <cg@exept.de>
parents: 1544
diff changeset
   267
    "Created: / 26.9.1999 / 13:33:15 / cg"
8abb4de4f8f5 added access to field.
Claus Gittinger <cg@exept.de>
parents: 1544
diff changeset
   268
!
8abb4de4f8f5 added access to field.
Claus Gittinger <cg@exept.de>
parents: 1544
diff changeset
   269
129
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   270
menuButton
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   271
    "return the menuButton component"
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   272
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   273
    ^ pullDownButton
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   274
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   275
    "Created: 28.2.1996 / 15:03:14 / cg"
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   276
! !
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   277
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   278
!ComboView methodsFor:'accessing-contents'!
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   279
181
31e8f8ab2fb8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 166
diff changeset
   280
contents
304
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   281
    "get the contents of my field"
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   282
181
31e8f8ab2fb8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 166
diff changeset
   283
    ^ field model value
31e8f8ab2fb8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 166
diff changeset
   284
31e8f8ab2fb8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 166
diff changeset
   285
    "Created: 14.5.1996 / 13:05:16 / cg"
304
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   286
    "Modified: 26.2.1997 / 16:55:43 / cg"
181
31e8f8ab2fb8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 166
diff changeset
   287
!
31e8f8ab2fb8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 166
diff changeset
   288
31e8f8ab2fb8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 166
diff changeset
   289
contents:something
304
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   290
    "set the contents of my field; questionable"
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   291
214
328a09259794 get list from model
Claus Gittinger <cg@exept.de>
parents: 184
diff changeset
   292
    |m|
328a09259794 get list from model
Claus Gittinger <cg@exept.de>
parents: 184
diff changeset
   293
328a09259794 get list from model
Claus Gittinger <cg@exept.de>
parents: 184
diff changeset
   294
    (m := field model) notNil ifTrue:[
304
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   295
        m value:something
214
328a09259794 get list from model
Claus Gittinger <cg@exept.de>
parents: 184
diff changeset
   296
    ]
181
31e8f8ab2fb8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 166
diff changeset
   297
31e8f8ab2fb8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 166
diff changeset
   298
    "Created: 14.5.1996 / 13:05:33 / cg"
304
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   299
    "Modified: 26.2.1997 / 16:56:08 / cg"
181
31e8f8ab2fb8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 166
diff changeset
   300
!
31e8f8ab2fb8 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 166
diff changeset
   301
889
7879fffb4810 oops #list returned wrong list
Claus Gittinger <cg@exept.de>
parents: 869
diff changeset
   302
list
7879fffb4810 oops #list returned wrong list
Claus Gittinger <cg@exept.de>
parents: 869
diff changeset
   303
    "return the list"
7879fffb4810 oops #list returned wrong list
Claus Gittinger <cg@exept.de>
parents: 869
diff changeset
   304
7879fffb4810 oops #list returned wrong list
Claus Gittinger <cg@exept.de>
parents: 869
diff changeset
   305
    ^ list
7879fffb4810 oops #list returned wrong list
Claus Gittinger <cg@exept.de>
parents: 869
diff changeset
   306
7879fffb4810 oops #list returned wrong list
Claus Gittinger <cg@exept.de>
parents: 869
diff changeset
   307
    "Created: / 18.5.1998 / 18:58:08 / cg"
7879fffb4810 oops #list returned wrong list
Claus Gittinger <cg@exept.de>
parents: 869
diff changeset
   308
!
7879fffb4810 oops #list returned wrong list
Claus Gittinger <cg@exept.de>
parents: 869
diff changeset
   309
129
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   310
list:aList
304
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   311
    "set the list explicitely; used internally or 
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   312
     to be send from the outside if no model/listHolder is used."
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   313
129
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   314
    list := aList.
2477
994d88ef4334 *** empty log message ***
Michael Beyl <mb@exept.de>
parents: 2474
diff changeset
   315
    (list isNil or:[list isSequenceable]) ifFalse:[
2474
173a07117f56 trap if assigned list is not sequenceable
martin
parents: 2406
diff changeset
   316
        self error:'Need an ordered collection' mayProceed:true.
173a07117f56 trap if assigned list is not sequenceable
martin
parents: 2406
diff changeset
   317
    ].
1306
56e90a9e5da1 renambe #enableStateChange to #enableStateChanged
Claus Gittinger <cg@exept.de>
parents: 1301
diff changeset
   318
    self enableStateChanged.
1294
36a0e9dcd813 Move common channels to View.
Stefan Vogel <sv@exept.de>
parents: 1291
diff changeset
   319
36a0e9dcd813 Move common channels to View.
Stefan Vogel <sv@exept.de>
parents: 1291
diff changeset
   320
    "Modified: / 30.3.1999 / 14:17:38 / stefan"
129
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   321
! !
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   322
853
e7e1c2bbd6f1 color selectors
tz
parents: 683
diff changeset
   323
!ComboView methodsFor:'accessing-look'!
e7e1c2bbd6f1 color selectors
tz
parents: 683
diff changeset
   324
e7e1c2bbd6f1 color selectors
tz
parents: 683
diff changeset
   325
backgroundColor
e7e1c2bbd6f1 color selectors
tz
parents: 683
diff changeset
   326
e7e1c2bbd6f1 color selectors
tz
parents: 683
diff changeset
   327
    ^field backgroundColor
e7e1c2bbd6f1 color selectors
tz
parents: 683
diff changeset
   328
!
e7e1c2bbd6f1 color selectors
tz
parents: 683
diff changeset
   329
e7e1c2bbd6f1 color selectors
tz
parents: 683
diff changeset
   330
backgroundColor:aColor
e7e1c2bbd6f1 color selectors
tz
parents: 683
diff changeset
   331
e7e1c2bbd6f1 color selectors
tz
parents: 683
diff changeset
   332
    field backgroundColor:aColor
e7e1c2bbd6f1 color selectors
tz
parents: 683
diff changeset
   333
!
e7e1c2bbd6f1 color selectors
tz
parents: 683
diff changeset
   334
e7e1c2bbd6f1 color selectors
tz
parents: 683
diff changeset
   335
font:aFont
e7e1c2bbd6f1 color selectors
tz
parents: 683
diff changeset
   336
e7e1c2bbd6f1 color selectors
tz
parents: 683
diff changeset
   337
    super font:aFont.
1183
667132091c2f ComboBox's inputField ought to use its default font.
Claus Gittinger <cg@exept.de>
parents: 1126
diff changeset
   338
    self setFieldsFont:aFont.
853
e7e1c2bbd6f1 color selectors
tz
parents: 683
diff changeset
   339
!
e7e1c2bbd6f1 color selectors
tz
parents: 683
diff changeset
   340
e7e1c2bbd6f1 color selectors
tz
parents: 683
diff changeset
   341
foregroundColor
e7e1c2bbd6f1 color selectors
tz
parents: 683
diff changeset
   342
e7e1c2bbd6f1 color selectors
tz
parents: 683
diff changeset
   343
    ^field foregroundColor
e7e1c2bbd6f1 color selectors
tz
parents: 683
diff changeset
   344
!
e7e1c2bbd6f1 color selectors
tz
parents: 683
diff changeset
   345
e7e1c2bbd6f1 color selectors
tz
parents: 683
diff changeset
   346
foregroundColor:aColor
e7e1c2bbd6f1 color selectors
tz
parents: 683
diff changeset
   347
e7e1c2bbd6f1 color selectors
tz
parents: 683
diff changeset
   348
    field foregroundColor:aColor
e7e1c2bbd6f1 color selectors
tz
parents: 683
diff changeset
   349
! !
e7e1c2bbd6f1 color selectors
tz
parents: 683
diff changeset
   350
214
328a09259794 get list from model
Claus Gittinger <cg@exept.de>
parents: 184
diff changeset
   351
!ComboView methodsFor:'accessing-mvc'!
328a09259794 get list from model
Claus Gittinger <cg@exept.de>
parents: 184
diff changeset
   352
277
44eadbccc2b7 added support for a separate listHolder
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
   353
listHolder:aValueHolder
44eadbccc2b7 added support for a separate listHolder
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
   354
    "set the listHolder.
44eadbccc2b7 added support for a separate listHolder
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
   355
     If not set, the list is supposed to be set explicitely"
44eadbccc2b7 added support for a separate listHolder
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
   356
44eadbccc2b7 added support for a separate listHolder
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
   357
    listHolder notNil ifTrue:[
304
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   358
        listHolder removeDependent:self.
277
44eadbccc2b7 added support for a separate listHolder
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
   359
    ].
44eadbccc2b7 added support for a separate listHolder
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
   360
    listHolder := aValueHolder.
44eadbccc2b7 added support for a separate listHolder
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
   361
    listHolder notNil ifTrue:[
304
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   362
        aValueHolder addDependent:self.
277
44eadbccc2b7 added support for a separate listHolder
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
   363
    ].
304
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   364
    realized ifTrue:[
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   365
        self getListFromModel.
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   366
    ]
277
44eadbccc2b7 added support for a separate listHolder
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
   367
304
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   368
    "Modified: 26.2.1997 / 19:32:09 / cg"
277
44eadbccc2b7 added support for a separate listHolder
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
   369
!
44eadbccc2b7 added support for a separate listHolder
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
   370
44eadbccc2b7 added support for a separate listHolder
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
   371
listMessage:aSymbol
44eadbccc2b7 added support for a separate listHolder
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
   372
    "define the message selector sent to the model, to fetch
44eadbccc2b7 added support for a separate listHolder
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
   373
     the list. If not defined, #list is used"
44eadbccc2b7 added support for a separate listHolder
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
   374
304
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   375
    listMsg := aSymbol
277
44eadbccc2b7 added support for a separate listHolder
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
   376
44eadbccc2b7 added support for a separate listHolder
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
   377
    "Created: 14.2.1997 / 19:16:52 / cg"
304
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   378
    "Modified: 26.2.1997 / 19:33:09 / cg"
277
44eadbccc2b7 added support for a separate listHolder
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
   379
!
44eadbccc2b7 added support for a separate listHolder
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
   380
214
328a09259794 get list from model
Claus Gittinger <cg@exept.de>
parents: 184
diff changeset
   381
model:aModel
304
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   382
    "set the model, which is supposed to provide the boxes value.
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   383
     If a listMessage was defined, it is also responsible for providing
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   384
     the list"
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   385
214
328a09259794 get list from model
Claus Gittinger <cg@exept.de>
parents: 184
diff changeset
   386
    super model:aModel.
328a09259794 get list from model
Claus Gittinger <cg@exept.de>
parents: 184
diff changeset
   387
314
6ff49c930c71 fetch models value when a model is assigned;
Claus Gittinger <cg@exept.de>
parents: 312
diff changeset
   388
    self getListFromModel.
6ff49c930c71 fetch models value when a model is assigned;
Claus Gittinger <cg@exept.de>
parents: 312
diff changeset
   389
    self getValueFromModel.
304
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   390
314
6ff49c930c71 fetch models value when a model is assigned;
Claus Gittinger <cg@exept.de>
parents: 312
diff changeset
   391
    "Modified: 28.2.1997 / 19:08:45 / cg"
310
15ef4f52f8cf comments
Claus Gittinger <cg@exept.de>
parents: 308
diff changeset
   392
! !
15ef4f52f8cf comments
Claus Gittinger <cg@exept.de>
parents: 308
diff changeset
   393
15ef4f52f8cf comments
Claus Gittinger <cg@exept.de>
parents: 308
diff changeset
   394
!ComboView methodsFor:'change & update'!
214
328a09259794 get list from model
Claus Gittinger <cg@exept.de>
parents: 184
diff changeset
   395
328a09259794 get list from model
Claus Gittinger <cg@exept.de>
parents: 184
diff changeset
   396
update:something with:aParameter from:changedObject
1207
9019fe235f32 do not share my enableChannel with my buttons channel
tm
parents: 1183
diff changeset
   397
214
328a09259794 get list from model
Claus Gittinger <cg@exept.de>
parents: 184
diff changeset
   398
    changedObject == model ifTrue:[
310
15ef4f52f8cf comments
Claus Gittinger <cg@exept.de>
parents: 308
diff changeset
   399
        listHolder isNil ifTrue:[
15ef4f52f8cf comments
Claus Gittinger <cg@exept.de>
parents: 308
diff changeset
   400
            self getListFromModel.
15ef4f52f8cf comments
Claus Gittinger <cg@exept.de>
parents: 308
diff changeset
   401
        ].
15ef4f52f8cf comments
Claus Gittinger <cg@exept.de>
parents: 308
diff changeset
   402
        self getValueFromModel.
15ef4f52f8cf comments
Claus Gittinger <cg@exept.de>
parents: 308
diff changeset
   403
        ^ self
214
328a09259794 get list from model
Claus Gittinger <cg@exept.de>
parents: 184
diff changeset
   404
    ].
310
15ef4f52f8cf comments
Claus Gittinger <cg@exept.de>
parents: 308
diff changeset
   405
    changedObject == listHolder ifTrue:[
15ef4f52f8cf comments
Claus Gittinger <cg@exept.de>
parents: 308
diff changeset
   406
        self getListFromModel.
15ef4f52f8cf comments
Claus Gittinger <cg@exept.de>
parents: 308
diff changeset
   407
        ^ self
15ef4f52f8cf comments
Claus Gittinger <cg@exept.de>
parents: 308
diff changeset
   408
    ].
15ef4f52f8cf comments
Claus Gittinger <cg@exept.de>
parents: 308
diff changeset
   409
214
328a09259794 get list from model
Claus Gittinger <cg@exept.de>
parents: 184
diff changeset
   410
    super update:something with:aParameter from:changedObject
328a09259794 get list from model
Claus Gittinger <cg@exept.de>
parents: 184
diff changeset
   411
1294
36a0e9dcd813 Move common channels to View.
Stefan Vogel <sv@exept.de>
parents: 1291
diff changeset
   412
    "Created: / 15.7.1996 / 12:26:49 / cg"
36a0e9dcd813 Move common channels to View.
Stefan Vogel <sv@exept.de>
parents: 1291
diff changeset
   413
    "Modified: / 28.2.1997 / 13:48:51 / cg"
36a0e9dcd813 Move common channels to View.
Stefan Vogel <sv@exept.de>
parents: 1291
diff changeset
   414
    "Modified: / 30.3.1999 / 14:17:55 / stefan"
214
328a09259794 get list from model
Claus Gittinger <cg@exept.de>
parents: 184
diff changeset
   415
! !
328a09259794 get list from model
Claus Gittinger <cg@exept.de>
parents: 184
diff changeset
   416
869
a1838cce9641 popup menu on space or return
Claus Gittinger <cg@exept.de>
parents: 853
diff changeset
   417
!ComboView methodsFor:'event handling'!
a1838cce9641 popup menu on space or return
Claus Gittinger <cg@exept.de>
parents: 853
diff changeset
   418
1306
56e90a9e5da1 renambe #enableStateChange to #enableStateChanged
Claus Gittinger <cg@exept.de>
parents: 1301
diff changeset
   419
enableStateChanged
1294
36a0e9dcd813 Move common channels to View.
Stefan Vogel <sv@exept.de>
parents: 1291
diff changeset
   420
    "the enable state has changed - pass this to my field and pullDownButton"
36a0e9dcd813 Move common channels to View.
Stefan Vogel <sv@exept.de>
parents: 1291
diff changeset
   421
36a0e9dcd813 Move common channels to View.
Stefan Vogel <sv@exept.de>
parents: 1291
diff changeset
   422
    |msg|
36a0e9dcd813 Move common channels to View.
Stefan Vogel <sv@exept.de>
parents: 1291
diff changeset
   423
36a0e9dcd813 Move common channels to View.
Stefan Vogel <sv@exept.de>
parents: 1291
diff changeset
   424
    (enableChannel isNil or:[enableChannel value]) ifTrue:[
36a0e9dcd813 Move common channels to View.
Stefan Vogel <sv@exept.de>
parents: 1291
diff changeset
   425
        msg := #enable
36a0e9dcd813 Move common channels to View.
Stefan Vogel <sv@exept.de>
parents: 1291
diff changeset
   426
    ] ifFalse:[
36a0e9dcd813 Move common channels to View.
Stefan Vogel <sv@exept.de>
parents: 1291
diff changeset
   427
        msg := #disable
36a0e9dcd813 Move common channels to View.
Stefan Vogel <sv@exept.de>
parents: 1291
diff changeset
   428
    ].
36a0e9dcd813 Move common channels to View.
Stefan Vogel <sv@exept.de>
parents: 1291
diff changeset
   429
    field perform:msg ifNotUnderstood:nil.
36a0e9dcd813 Move common channels to View.
Stefan Vogel <sv@exept.de>
parents: 1291
diff changeset
   430
36a0e9dcd813 Move common channels to View.
Stefan Vogel <sv@exept.de>
parents: 1291
diff changeset
   431
    (list size == 0) ifTrue:[
36a0e9dcd813 Move common channels to View.
Stefan Vogel <sv@exept.de>
parents: 1291
diff changeset
   432
        msg := #disable
36a0e9dcd813 Move common channels to View.
Stefan Vogel <sv@exept.de>
parents: 1291
diff changeset
   433
    ].
36a0e9dcd813 Move common channels to View.
Stefan Vogel <sv@exept.de>
parents: 1291
diff changeset
   434
    pullDownButton perform:msg ifNotUnderstood:nil.
36a0e9dcd813 Move common channels to View.
Stefan Vogel <sv@exept.de>
parents: 1291
diff changeset
   435
36a0e9dcd813 Move common channels to View.
Stefan Vogel <sv@exept.de>
parents: 1291
diff changeset
   436
    "Modified: / 22.2.1999 / 00:47:46 / cg"
36a0e9dcd813 Move common channels to View.
Stefan Vogel <sv@exept.de>
parents: 1291
diff changeset
   437
    "Modified: / 30.3.1999 / 14:17:10 / stefan"
36a0e9dcd813 Move common channels to View.
Stefan Vogel <sv@exept.de>
parents: 1291
diff changeset
   438
!
36a0e9dcd813 Move common channels to View.
Stefan Vogel <sv@exept.de>
parents: 1291
diff changeset
   439
869
a1838cce9641 popup menu on space or return
Claus Gittinger <cg@exept.de>
parents: 853
diff changeset
   440
keyPress:key x:x y:y
2025
cf30d2acc776 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2023
diff changeset
   441
    <resource: #keyboard (#Return)>
cf30d2acc776 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2023
diff changeset
   442
869
a1838cce9641 popup menu on space or return
Claus Gittinger <cg@exept.de>
parents: 853
diff changeset
   443
    (key == Character space
a1838cce9641 popup menu on space or return
Claus Gittinger <cg@exept.de>
parents: 853
diff changeset
   444
    or:[key == #Return]) ifTrue:[
a1838cce9641 popup menu on space or return
Claus Gittinger <cg@exept.de>
parents: 853
diff changeset
   445
        self pullMenu.
a1838cce9641 popup menu on space or return
Claus Gittinger <cg@exept.de>
parents: 853
diff changeset
   446
        ^ self.
a1838cce9641 popup menu on space or return
Claus Gittinger <cg@exept.de>
parents: 853
diff changeset
   447
    ].
a1838cce9641 popup menu on space or return
Claus Gittinger <cg@exept.de>
parents: 853
diff changeset
   448
a1838cce9641 popup menu on space or return
Claus Gittinger <cg@exept.de>
parents: 853
diff changeset
   449
    ^ super keyPress:key x:x y:y
a1838cce9641 popup menu on space or return
Claus Gittinger <cg@exept.de>
parents: 853
diff changeset
   450
a1838cce9641 popup menu on space or return
Claus Gittinger <cg@exept.de>
parents: 853
diff changeset
   451
    "Modified: / 21.4.1998 / 20:10:05 / cg"
a1838cce9641 popup menu on space or return
Claus Gittinger <cg@exept.de>
parents: 853
diff changeset
   452
! !
a1838cce9641 popup menu on space or return
Claus Gittinger <cg@exept.de>
parents: 853
diff changeset
   453
1325
3e36f7c5373b category change
Claus Gittinger <cg@exept.de>
parents: 1306
diff changeset
   454
!ComboView methodsFor:'initialize / release'!
129
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   455
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   456
initialize
1696
f1bae6d68ffe eliminated styleSheet name = win95 queries
Claus Gittinger <cg@exept.de>
parents: 1633
diff changeset
   457
    |prefExt leftInset rightInset prefWidth halfSpacing l nm|
129
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   458
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   459
    super initialize.
308
922a96deba3e examples removed; cleanup
Claus Gittinger <cg@exept.de>
parents: 304
diff changeset
   460
304
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   461
    listMsg := self class defaultListMessage.
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   462
    aspectMsg := self class defaultAspectMessage.
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   463
    changeMsg := self class defaultChangeMessage.
129
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   464
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   465
    self initializeField.
431
c6c92bef604a fixed origin of editField
Claus Gittinger <cg@exept.de>
parents: 415
diff changeset
   466
    field origin:0@0 corner:1.0@1.0.
2136
6e2d9f16e7e3 shadowColor setup fixed
Claus Gittinger <cg@exept.de>
parents: 2131
diff changeset
   467
    self shadowColor:(field shadowColor).
129
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   468
331
d6fad4b27a9a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 321
diff changeset
   469
    self initializeButton.
2174
ab242e29da64 button init code made publicly available
Claus Gittinger <cg@exept.de>
parents: 2157
diff changeset
   470
    pullDownButton pressAction:[self pullMenu].
280
3936f0839b64 nicer spacing
Claus Gittinger <cg@exept.de>
parents: 277
diff changeset
   471
    prefExt := pullDownButton preferredExtent.
3936f0839b64 nicer spacing
Claus Gittinger <cg@exept.de>
parents: 277
diff changeset
   472
    prefWidth := prefExt x.
3936f0839b64 nicer spacing
Claus Gittinger <cg@exept.de>
parents: 277
diff changeset
   473
129
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   474
    pullDownButton origin:1.0@0.0 corner:1.0@1.0.
217
82971d8b3938 care for 2D styles
Claus Gittinger <cg@exept.de>
parents: 214
diff changeset
   475
    styleSheet is3D ifTrue:[
280
3936f0839b64 nicer spacing
Claus Gittinger <cg@exept.de>
parents: 277
diff changeset
   476
        halfSpacing := ViewSpacing // 2.
3936f0839b64 nicer spacing
Claus Gittinger <cg@exept.de>
parents: 277
diff changeset
   477
        leftInset := rightInset := prefWidth + halfSpacing.
1334
cc79acaebf00 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1325
diff changeset
   478
        (l := styleSheet at:#'comboView.level' default:nil) notNil ifTrue:[
331
d6fad4b27a9a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 321
diff changeset
   479
            self level:l.
319
920ef16160ae w95 style fixes
Claus Gittinger <cg@exept.de>
parents: 314
diff changeset
   480
            field level:0.
920ef16160ae w95 style fixes
Claus Gittinger <cg@exept.de>
parents: 314
diff changeset
   481
            field rightInset:margin.
920ef16160ae w95 style fixes
Claus Gittinger <cg@exept.de>
parents: 314
diff changeset
   482
        ] ifFalse:[
920ef16160ae w95 style fixes
Claus Gittinger <cg@exept.de>
parents: 314
diff changeset
   483
            pullDownButton rightInset:halfSpacing.
920ef16160ae w95 style fixes
Claus Gittinger <cg@exept.de>
parents: 314
diff changeset
   484
            field leftInset:halfSpacing
920ef16160ae w95 style fixes
Claus Gittinger <cg@exept.de>
parents: 314
diff changeset
   485
        ].
217
82971d8b3938 care for 2D styles
Claus Gittinger <cg@exept.de>
parents: 214
diff changeset
   486
    ] ifFalse:[
280
3936f0839b64 nicer spacing
Claus Gittinger <cg@exept.de>
parents: 277
diff changeset
   487
        leftInset := prefWidth + pullDownButton borderWidth.
3936f0839b64 nicer spacing
Claus Gittinger <cg@exept.de>
parents: 277
diff changeset
   488
        rightInset := prefWidth.
217
82971d8b3938 care for 2D styles
Claus Gittinger <cg@exept.de>
parents: 214
diff changeset
   489
    ].
1125
6bb8029bbc29 geometry beautified
Claus Gittinger <cg@exept.de>
parents: 889
diff changeset
   490
1696
f1bae6d68ffe eliminated styleSheet name = win95 queries
Claus Gittinger <cg@exept.de>
parents: 1633
diff changeset
   491
    nm := styleSheet name.
f1bae6d68ffe eliminated styleSheet name = win95 queries
Claus Gittinger <cg@exept.de>
parents: 1633
diff changeset
   492
    (nm = #win95
f1bae6d68ffe eliminated styleSheet name = win95 queries
Claus Gittinger <cg@exept.de>
parents: 1633
diff changeset
   493
    or:[nm = #win98
f1bae6d68ffe eliminated styleSheet name = win95 queries
Claus Gittinger <cg@exept.de>
parents: 1633
diff changeset
   494
    or:[nm = #st80]]) ifTrue:[
1125
6bb8029bbc29 geometry beautified
Claus Gittinger <cg@exept.de>
parents: 889
diff changeset
   495
        field level:0.
6bb8029bbc29 geometry beautified
Claus Gittinger <cg@exept.de>
parents: 889
diff changeset
   496
        self level:-1.
6bb8029bbc29 geometry beautified
Claus Gittinger <cg@exept.de>
parents: 889
diff changeset
   497
        pullDownButton rightInset:0.
1696
f1bae6d68ffe eliminated styleSheet name = win95 queries
Claus Gittinger <cg@exept.de>
parents: 1633
diff changeset
   498
        nm ~= #st80 ifTrue:[
1125
6bb8029bbc29 geometry beautified
Claus Gittinger <cg@exept.de>
parents: 889
diff changeset
   499
            leftInset := (ArrowButton new preferredExtent x).
1126
dc790a73ac4d checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1125
diff changeset
   500
            rightInset := leftInset.
1125
6bb8029bbc29 geometry beautified
Claus Gittinger <cg@exept.de>
parents: 889
diff changeset
   501
        ].
6bb8029bbc29 geometry beautified
Claus Gittinger <cg@exept.de>
parents: 889
diff changeset
   502
        field origin:0.0@0.0.
6bb8029bbc29 geometry beautified
Claus Gittinger <cg@exept.de>
parents: 889
diff changeset
   503
        field leftInset:0
6bb8029bbc29 geometry beautified
Claus Gittinger <cg@exept.de>
parents: 889
diff changeset
   504
"/        field topInset:1; bottomInset:1.
6bb8029bbc29 geometry beautified
Claus Gittinger <cg@exept.de>
parents: 889
diff changeset
   505
    ].
1126
dc790a73ac4d checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1125
diff changeset
   506
    field rightInset:rightInset.
280
3936f0839b64 nicer spacing
Claus Gittinger <cg@exept.de>
parents: 277
diff changeset
   507
    pullDownButton leftInset:leftInset negated.
129
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   508
247
a974233a33c1 use new #initialHeight:
dq
parents: 229
diff changeset
   509
    self initialHeight:field preferredExtent y + ViewSpacing.
129
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   510
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   511
    "
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   512
     |b|
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   513
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   514
     b := ComboBoxView new.
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   515
     b list:#('hello' 'world' 'this' 'is' 'st/x').
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   516
     b open
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   517
    "
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   518
1125
6bb8029bbc29 geometry beautified
Claus Gittinger <cg@exept.de>
parents: 889
diff changeset
   519
    "Created: / 28.2.1996 / 15:03:17 / cg"
6bb8029bbc29 geometry beautified
Claus Gittinger <cg@exept.de>
parents: 889
diff changeset
   520
    "Modified: / 8.9.1998 / 20:33:22 / cg"
331
d6fad4b27a9a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 321
diff changeset
   521
!
d6fad4b27a9a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 321
diff changeset
   522
d6fad4b27a9a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 321
diff changeset
   523
initializeButton
2174
ab242e29da64 button init code made publicly available
Claus Gittinger <cg@exept.de>
parents: 2157
diff changeset
   524
    pullDownButton := self class comboButtonFor:self.
331
d6fad4b27a9a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 321
diff changeset
   525
    pullDownButton disable.
d6fad4b27a9a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 321
diff changeset
   526
!
d6fad4b27a9a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 321
diff changeset
   527
d6fad4b27a9a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 321
diff changeset
   528
initializeField
d6fad4b27a9a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 321
diff changeset
   529
    self subclassResponsibility
d6fad4b27a9a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 321
diff changeset
   530
d6fad4b27a9a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 321
diff changeset
   531
    "Created: 29.3.1997 / 11:17:14 / cg"
2157
6cfdf247519a destroy - release
Claus Gittinger <cg@exept.de>
parents: 2136
diff changeset
   532
!
6cfdf247519a destroy - release
Claus Gittinger <cg@exept.de>
parents: 2136
diff changeset
   533
6cfdf247519a destroy - release
Claus Gittinger <cg@exept.de>
parents: 2136
diff changeset
   534
release
6cfdf247519a destroy - release
Claus Gittinger <cg@exept.de>
parents: 2136
diff changeset
   535
    listHolder notNil ifTrue:[
6cfdf247519a destroy - release
Claus Gittinger <cg@exept.de>
parents: 2136
diff changeset
   536
        listHolder removeDependent:self.
6cfdf247519a destroy - release
Claus Gittinger <cg@exept.de>
parents: 2136
diff changeset
   537
        listHolder := nil.
6cfdf247519a destroy - release
Claus Gittinger <cg@exept.de>
parents: 2136
diff changeset
   538
    ].
6cfdf247519a destroy - release
Claus Gittinger <cg@exept.de>
parents: 2136
diff changeset
   539
    super release
129
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   540
! !
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   541
2406
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   542
!ComboView methodsFor:'menu interaction'!
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   543
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   544
createPullDownMenuForList:aList
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   545
    "pull the menu - triggered from the button"
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   546
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   547
    |menu index|
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   548
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   549
    menu := MenuPanel labels:aList.
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   550
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   551
    index := 1.
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   552
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   553
    menu do:[:el |
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   554
        el value:#select: argument:index.
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   555
        index := index + 1.
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   556
    ].
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   557
    menu receiver:self.
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   558
    menu font:font.
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   559
    menu preferredWidth:(self width).
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   560
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   561
    ^ menu
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   562
!
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   563
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   564
pullMenu
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   565
    "pull the menu - triggered from the button"
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   566
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   567
    |menu origin|
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   568
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   569
    self getListFromModel.
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   570
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   571
    list notEmptyOrNil ifTrue:[
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   572
        menu := self createPullDownMenuForList:list.
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   573
        origin := device translatePoint:(0 @ self height) fromView:self toView:nil.
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   574
        menu showAt:origin.
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   575
    ].
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   576
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   577
    pullDownButton turnOff.
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   578
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   579
    "Created: / 10.10.2001 / 14:47:25 / cg"
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   580
    "Modified: / 10.10.2001 / 15:04:44 / cg"
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   581
!
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   582
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   583
select:anIndex
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   584
    "sent from the popped menu, when an item was selected"
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   585
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   586
    self subclassResponsibility
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   587
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   588
    "Modified: 27.2.1997 / 15:19:07 / cg"
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   589
! !
2ea7cf110e58 category change
penk
parents: 2405
diff changeset
   590
129
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   591
!ComboView methodsFor:'message delegation'!
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   592
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   593
doesNotUnderstand:aMessage
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   594
    (field respondsTo:aMessage selector) ifTrue:[
1207
9019fe235f32 do not share my enableChannel with my buttons channel
tm
parents: 1183
diff changeset
   595
        ^ aMessage sendTo:field
129
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   596
    ].
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   597
    ^ super doesNotUnderstand:aMessage
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   598
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   599
    "Created: 28.2.1996 / 15:03:17 / cg"
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   600
    "Modified: 28.2.1996 / 15:06:09 / cg"
166
19f08c13b299 Forward respondsTo: message.
Stefan Vogel <sv@exept.de>
parents: 129
diff changeset
   601
!
19f08c13b299 Forward respondsTo: message.
Stefan Vogel <sv@exept.de>
parents: 129
diff changeset
   602
2300
c3d1ba5c884e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2176
diff changeset
   603
flash
c3d1ba5c884e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2176
diff changeset
   604
    field flash
c3d1ba5c884e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2176
diff changeset
   605
!
c3d1ba5c884e *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2176
diff changeset
   606
166
19f08c13b299 Forward respondsTo: message.
Stefan Vogel <sv@exept.de>
parents: 129
diff changeset
   607
respondsTo:aSymbol
19f08c13b299 Forward respondsTo: message.
Stefan Vogel <sv@exept.de>
parents: 129
diff changeset
   608
    ^ (field respondsTo:aSymbol) or:[super respondsTo:aSymbol]
19f08c13b299 Forward respondsTo: message.
Stefan Vogel <sv@exept.de>
parents: 129
diff changeset
   609
19f08c13b299 Forward respondsTo: message.
Stefan Vogel <sv@exept.de>
parents: 129
diff changeset
   610
    "Created: 2.5.1996 / 16:57:34 / stefan"
129
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   611
! !
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   612
214
328a09259794 get list from model
Claus Gittinger <cg@exept.de>
parents: 184
diff changeset
   613
!ComboView methodsFor:'private'!
328a09259794 get list from model
Claus Gittinger <cg@exept.de>
parents: 184
diff changeset
   614
328a09259794 get list from model
Claus Gittinger <cg@exept.de>
parents: 184
diff changeset
   615
getListFromModel
277
44eadbccc2b7 added support for a separate listHolder
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
   616
    "fetch the list - either from the listHolder, or
44eadbccc2b7 added support for a separate listHolder
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
   617
     from the model. If no listMessage was defined, fetch it
44eadbccc2b7 added support for a separate listHolder
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
   618
     using #list."
44eadbccc2b7 added support for a separate listHolder
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
   619
44eadbccc2b7 added support for a separate listHolder
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
   620
    listHolder notNil ifTrue:[
44eadbccc2b7 added support for a separate listHolder
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
   621
        self list:listHolder value
44eadbccc2b7 added support for a separate listHolder
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
   622
    ] ifFalse:[
304
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   623
        (model notNil and:[listMsg notNil]) ifTrue:[
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   624
            (model respondsTo:listMsg) ifTrue:[
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   625
                self list:(model perform:listMsg)
277
44eadbccc2b7 added support for a separate listHolder
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
   626
            ]
44eadbccc2b7 added support for a separate listHolder
Claus Gittinger <cg@exept.de>
parents: 276
diff changeset
   627
        ]
214
328a09259794 get list from model
Claus Gittinger <cg@exept.de>
parents: 184
diff changeset
   628
    ].
328a09259794 get list from model
Claus Gittinger <cg@exept.de>
parents: 184
diff changeset
   629
328a09259794 get list from model
Claus Gittinger <cg@exept.de>
parents: 184
diff changeset
   630
    "Created: 15.7.1996 / 12:22:56 / cg"
304
7ee03df31561 cleaned up model interface
Claus Gittinger <cg@exept.de>
parents: 302
diff changeset
   631
    "Modified: 26.2.1997 / 19:40:58 / cg"
214
328a09259794 get list from model
Claus Gittinger <cg@exept.de>
parents: 184
diff changeset
   632
!
328a09259794 get list from model
Claus Gittinger <cg@exept.de>
parents: 184
diff changeset
   633
328a09259794 get list from model
Claus Gittinger <cg@exept.de>
parents: 184
diff changeset
   634
getValueFromModel
328a09259794 get list from model
Claus Gittinger <cg@exept.de>
parents: 184
diff changeset
   635
328a09259794 get list from model
Claus Gittinger <cg@exept.de>
parents: 184
diff changeset
   636
    "Modified: 15.7.1996 / 12:28:59 / cg"
1183
667132091c2f ComboBox's inputField ought to use its default font.
Claus Gittinger <cg@exept.de>
parents: 1126
diff changeset
   637
!
667132091c2f ComboBox's inputField ought to use its default font.
Claus Gittinger <cg@exept.de>
parents: 1126
diff changeset
   638
1210
55f2c4209f94 oops - only pull-button is disabled with empty list;
Claus Gittinger <cg@exept.de>
parents: 1207
diff changeset
   639
setFieldsFont:aFont
55f2c4209f94 oops - only pull-button is disabled with empty list;
Claus Gittinger <cg@exept.de>
parents: 1207
diff changeset
   640
    field font:aFont.
214
328a09259794 get list from model
Claus Gittinger <cg@exept.de>
parents: 184
diff changeset
   641
! !
328a09259794 get list from model
Claus Gittinger <cg@exept.de>
parents: 184
diff changeset
   642
129
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   643
!ComboView methodsFor:'queries'!
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   644
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   645
preferredExtent
285
a33d83de3849 commentary
Claus Gittinger <cg@exept.de>
parents: 283
diff changeset
   646
    "compute & return the boxes preferredExtent from the components' preferrences"
a33d83de3849 commentary
Claus Gittinger <cg@exept.de>
parents: 283
diff changeset
   647
683
a2593b4a3ce1 fixed preferredExtent to also look into the menus list
ca
parents: 605
diff changeset
   648
    |fieldPref buttonPref m menuPrefX menuPrefY w h|
129
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   649
312
ec32b0a6259a explicit preferredExtent
ca
parents: 310
diff changeset
   650
    "/ If I have an explicit preferredExtent ..
ec32b0a6259a explicit preferredExtent
ca
parents: 310
diff changeset
   651
ec32b0a6259a explicit preferredExtent
ca
parents: 310
diff changeset
   652
    preferredExtent notNil ifTrue:[
ec32b0a6259a explicit preferredExtent
ca
parents: 310
diff changeset
   653
        ^ preferredExtent
ec32b0a6259a explicit preferredExtent
ca
parents: 310
diff changeset
   654
    ].
ec32b0a6259a explicit preferredExtent
ca
parents: 310
diff changeset
   655
129
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   656
    list isNil ifTrue:[
308
922a96deba3e examples removed; cleanup
Claus Gittinger <cg@exept.de>
parents: 304
diff changeset
   657
        self getListFromModel
922a96deba3e examples removed; cleanup
Claus Gittinger <cg@exept.de>
parents: 304
diff changeset
   658
    ].
922a96deba3e examples removed; cleanup
Claus Gittinger <cg@exept.de>
parents: 304
diff changeset
   659
922a96deba3e examples removed; cleanup
Claus Gittinger <cg@exept.de>
parents: 304
diff changeset
   660
    list isNil ifTrue:[
683
a2593b4a3ce1 fixed preferredExtent to also look into the menus list
ca
parents: 605
diff changeset
   661
        menuPrefX := menuPrefY := 0
129
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   662
    ] ifFalse:[
1544
d8290e5a0b05 Speedup
Stefan Vogel <sv@exept.de>
parents: 1348
diff changeset
   663
        m := (MenuView onDevice:device ? Screen current) labels:list.
302
8af5f51ce7a5 preferredExtent is sum of menu + button
Claus Gittinger <cg@exept.de>
parents: 285
diff changeset
   664
        menuPrefX := m preferredExtent x.
1348
b4bf740ec2fc fixed pref. extent
Claus Gittinger <cg@exept.de>
parents: 1344
diff changeset
   665
b4bf740ec2fc fixed pref. extent
Claus Gittinger <cg@exept.de>
parents: 1344
diff changeset
   666
        "/ the menuView returns rubbish ...
b4bf740ec2fc fixed pref. extent
Claus Gittinger <cg@exept.de>
parents: 1344
diff changeset
   667
"/        menuPrefY := (m preferredExtentForLines:1 cols:10) y
b4bf740ec2fc fixed pref. extent
Claus Gittinger <cg@exept.de>
parents: 1344
diff changeset
   668
        
b4bf740ec2fc fixed pref. extent
Claus Gittinger <cg@exept.de>
parents: 1344
diff changeset
   669
        "/ any non-strings ?
b4bf740ec2fc fixed pref. extent
Claus Gittinger <cg@exept.de>
parents: 1344
diff changeset
   670
        menuPrefY := list 
b4bf740ec2fc fixed pref. extent
Claus Gittinger <cg@exept.de>
parents: 1344
diff changeset
   671
            inject:('X' heightOn:self) 
b4bf740ec2fc fixed pref. extent
Claus Gittinger <cg@exept.de>
parents: 1344
diff changeset
   672
            into:[:max :el | el isString ifTrue:[
b4bf740ec2fc fixed pref. extent
Claus Gittinger <cg@exept.de>
parents: 1344
diff changeset
   673
                                max
b4bf740ec2fc fixed pref. extent
Claus Gittinger <cg@exept.de>
parents: 1344
diff changeset
   674
                              ] ifFalse:[
b4bf740ec2fc fixed pref. extent
Claus Gittinger <cg@exept.de>
parents: 1344
diff changeset
   675
                                max max:(el heightOn:self) 
b4bf740ec2fc fixed pref. extent
Claus Gittinger <cg@exept.de>
parents: 1344
diff changeset
   676
                              ]
b4bf740ec2fc fixed pref. extent
Claus Gittinger <cg@exept.de>
parents: 1344
diff changeset
   677
                 ].
129
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   678
    ].
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   679
302
8af5f51ce7a5 preferredExtent is sum of menu + button
Claus Gittinger <cg@exept.de>
parents: 285
diff changeset
   680
    fieldPref := field preferredExtent.
8af5f51ce7a5 preferredExtent is sum of menu + button
Claus Gittinger <cg@exept.de>
parents: 285
diff changeset
   681
    buttonPref := pullDownButton preferredExtent.
8af5f51ce7a5 preferredExtent is sum of menu + button
Claus Gittinger <cg@exept.de>
parents: 285
diff changeset
   682
319
920ef16160ae w95 style fixes
Claus Gittinger <cg@exept.de>
parents: 314
diff changeset
   683
    w := ((fieldPref x max:menuPrefX) max:50) + buttonPref x.
920ef16160ae w95 style fixes
Claus Gittinger <cg@exept.de>
parents: 314
diff changeset
   684
    w := w + margin + margin.
683
a2593b4a3ce1 fixed preferredExtent to also look into the menus list
ca
parents: 605
diff changeset
   685
    h := (fieldPref y max:buttonPref y) max:menuPrefY.
319
920ef16160ae w95 style fixes
Claus Gittinger <cg@exept.de>
parents: 314
diff changeset
   686
    h := h + margin + margin.
920ef16160ae w95 style fixes
Claus Gittinger <cg@exept.de>
parents: 314
diff changeset
   687
    ^ w @ h
129
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   688
1348
b4bf740ec2fc fixed pref. extent
Claus Gittinger <cg@exept.de>
parents: 1344
diff changeset
   689
    "Created: / 28.2.1996 / 15:03:17 / cg"
b4bf740ec2fc fixed pref. extent
Claus Gittinger <cg@exept.de>
parents: 1344
diff changeset
   690
    "Modified: / 29.4.1999 / 11:27:54 / cg"
129
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   691
! !
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   692
263
865b7d99d3f5 added an example for a menu-pull-hook
Claus Gittinger <cg@exept.de>
parents: 247
diff changeset
   693
!ComboView class methodsFor:'documentation'!
129
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   694
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   695
version
2477
994d88ef4334 *** empty log message ***
Michael Beyl <mb@exept.de>
parents: 2474
diff changeset
   696
    ^ '$Header: /cvs/stx/stx/libwidg2/ComboView.st,v 1.74 2003-04-08 14:13:25 mb Exp $'
129
a680f0b7508f intitial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   697
! !