EnterBoxWithList.st
author Jan Vrany <jan.vrany@labware.com>
Fri, 02 Sep 2022 11:25:39 +0100
branchjv
changeset 6261 9b7eb7159d29
parent 3171 da1db67f1115
permissions -rw-r--r--
Fix loong standing bug with some menus not being translated / resolved This has happened with browser "View" menu when sometimes it had the slice resolved and sometimes not. It turned out that it was because the code disabled resources (and therefore slices) resolution when processing shortcuts, so the menu was created and cached unresolved. This fixes the issue. eXept apparently run into the same problem.
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
1716
0e31e721d4ab copyrights
Claus Gittinger <cg@exept.de>
parents: 1165
diff changeset
     1
"
0e31e721d4ab copyrights
Claus Gittinger <cg@exept.de>
parents: 1165
diff changeset
     2
 COPYRIGHT (c) 1998 by eXept Software AG
0e31e721d4ab copyrights
Claus Gittinger <cg@exept.de>
parents: 1165
diff changeset
     3
              All Rights Reserved
0e31e721d4ab copyrights
Claus Gittinger <cg@exept.de>
parents: 1165
diff changeset
     4
0e31e721d4ab copyrights
Claus Gittinger <cg@exept.de>
parents: 1165
diff changeset
     5
 This software is furnished under a license and may be used
0e31e721d4ab copyrights
Claus Gittinger <cg@exept.de>
parents: 1165
diff changeset
     6
 only in accordance with the terms of that license and with the
0e31e721d4ab copyrights
Claus Gittinger <cg@exept.de>
parents: 1165
diff changeset
     7
 inclusion of the above copyright notice.   This software may not
0e31e721d4ab copyrights
Claus Gittinger <cg@exept.de>
parents: 1165
diff changeset
     8
 be provided or otherwise made available to, or used by, any
0e31e721d4ab copyrights
Claus Gittinger <cg@exept.de>
parents: 1165
diff changeset
     9
 other person.  No title to or ownership of the software is
0e31e721d4ab copyrights
Claus Gittinger <cg@exept.de>
parents: 1165
diff changeset
    10
 hereby transferred.
0e31e721d4ab copyrights
Claus Gittinger <cg@exept.de>
parents: 1165
diff changeset
    11
"
1818
fe99c5c721e9 category changes
Claus Gittinger <cg@exept.de>
parents: 1716
diff changeset
    12
"{ Package: 'stx:libwidg2' }"
fe99c5c721e9 category changes
Claus Gittinger <cg@exept.de>
parents: 1716
diff changeset
    13
1165
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    14
EnterBox subclass:#EnterBoxWithList
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    15
	instanceVariableNames:''
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    16
	classVariableNames:''
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    17
	poolDictionaries:''
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    18
	category:'Views-DialogBoxes'
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    19
!
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    20
1716
0e31e721d4ab copyrights
Claus Gittinger <cg@exept.de>
parents: 1165
diff changeset
    21
!EnterBoxWithList class methodsFor:'documentation'!
0e31e721d4ab copyrights
Claus Gittinger <cg@exept.de>
parents: 1165
diff changeset
    22
0e31e721d4ab copyrights
Claus Gittinger <cg@exept.de>
parents: 1165
diff changeset
    23
copyright
0e31e721d4ab copyrights
Claus Gittinger <cg@exept.de>
parents: 1165
diff changeset
    24
"
0e31e721d4ab copyrights
Claus Gittinger <cg@exept.de>
parents: 1165
diff changeset
    25
 COPYRIGHT (c) 1998 by eXept Software AG
0e31e721d4ab copyrights
Claus Gittinger <cg@exept.de>
parents: 1165
diff changeset
    26
              All Rights Reserved
0e31e721d4ab copyrights
Claus Gittinger <cg@exept.de>
parents: 1165
diff changeset
    27
0e31e721d4ab copyrights
Claus Gittinger <cg@exept.de>
parents: 1165
diff changeset
    28
 This software is furnished under a license and may be used
0e31e721d4ab copyrights
Claus Gittinger <cg@exept.de>
parents: 1165
diff changeset
    29
 only in accordance with the terms of that license and with the
0e31e721d4ab copyrights
Claus Gittinger <cg@exept.de>
parents: 1165
diff changeset
    30
 inclusion of the above copyright notice.   This software may not
0e31e721d4ab copyrights
Claus Gittinger <cg@exept.de>
parents: 1165
diff changeset
    31
 be provided or otherwise made available to, or used by, any
0e31e721d4ab copyrights
Claus Gittinger <cg@exept.de>
parents: 1165
diff changeset
    32
 other person.  No title to or ownership of the software is
0e31e721d4ab copyrights
Claus Gittinger <cg@exept.de>
parents: 1165
diff changeset
    33
 hereby transferred.
0e31e721d4ab copyrights
Claus Gittinger <cg@exept.de>
parents: 1165
diff changeset
    34
"
0e31e721d4ab copyrights
Claus Gittinger <cg@exept.de>
parents: 1165
diff changeset
    35
3171
da1db67f1115 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2122
diff changeset
    36
!
1165
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    37
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    38
examples 
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    39
"
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    40
                                                                        [exBegin]
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    41
        |box|
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    42
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    43
        box := EnterBoxWithList new.
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    44
        box list:#('Jim' 'John' 'Paul').
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    45
        box title:'your name please:'.
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    46
        box action:[:arg | Transcript showCR:'entered: ''' , arg printString , ''''].
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    47
        box open
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    48
                                                                        [exEnd]
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    49
"
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    50
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    51
    "Modified: 16.11.1995 / 21:28:11 / cg"
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    52
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    53
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    54
! !
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    55
1818
fe99c5c721e9 category changes
Claus Gittinger <cg@exept.de>
parents: 1716
diff changeset
    56
!EnterBoxWithList methodsFor:'accessing-contents'!
1165
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    57
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    58
list:aList
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    59
    enterField list:aList.
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    60
! !
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    61
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    62
!EnterBoxWithList methodsFor:'initialization'!
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    63
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    64
createEnterField
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    65
    "here, a ComboBox is created."
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    66
2122
d63e816e2c8b cr-action
Claus Gittinger <cg@exept.de>
parents: 1818
diff changeset
    67
    |widget|
1165
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    68
2122
d63e816e2c8b cr-action
Claus Gittinger <cg@exept.de>
parents: 1818
diff changeset
    69
    widget := ComboBoxView new.
d63e816e2c8b cr-action
Claus Gittinger <cg@exept.de>
parents: 1818
diff changeset
    70
    widget leaveAction:[:key | self okPressed].
d63e816e2c8b cr-action
Claus Gittinger <cg@exept.de>
parents: 1818
diff changeset
    71
    ^ widget
1165
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    72
! !
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    73
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    74
!EnterBoxWithList class methodsFor:'documentation'!
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    75
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    76
version
3171
da1db67f1115 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 2122
diff changeset
    77
    ^ '$Header: /cvs/stx/stx/libwidg2/EnterBoxWithList.st,v 1.5 2007-01-26 14:00:55 cg Exp $'
1165
b375b5831e74 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    78
! !