author | Claus Gittinger <cg@exept.de> |
Sat, 12 May 2018 14:23:45 +0200 | |
changeset 4088 | bbf9b58f99c8 |
parent 3271 | 2a9459856e15 |
permissions | -rw-r--r-- |
3263 | 1 |
" |
2 |
COPYRIGHT (c) 2014 by Claus Gittinger |
|
3 |
All Rights Reserved |
|
4 |
||
5 |
This software is furnished under a license and may be used |
|
6 |
only in accordance with the terms of that license and with the |
|
7 |
inclusion of the above copyright notice. This software may not |
|
8 |
be provided or otherwise made available to, or used by, any |
|
9 |
other person. No title to or ownership of the software is |
|
10 |
hereby transferred. |
|
11 |
" |
|
12 |
"{ Package: 'stx:libview2' }" |
|
13 |
||
14 |
ValueHolder subclass:#ValueHolderWithRememberedPreviousValue |
|
15 |
instanceVariableNames:'previousValue' |
|
16 |
classVariableNames:'' |
|
17 |
poolDictionaries:'' |
|
18 |
category:'Interface-Support-Models' |
|
19 |
! |
|
20 |
||
21 |
!ValueHolderWithRememberedPreviousValue class methodsFor:'documentation'! |
|
22 |
||
23 |
copyright |
|
24 |
" |
|
25 |
COPYRIGHT (c) 2014 by Claus Gittinger |
|
26 |
All Rights Reserved |
|
27 |
||
28 |
This software is furnished under a license and may be used |
|
29 |
only in accordance with the terms of that license and with the |
|
30 |
inclusion of the above copyright notice. This software may not |
|
31 |
be provided or otherwise made available to, or used by, any |
|
32 |
other person. No title to or ownership of the software is |
|
33 |
hereby transferred. |
|
34 |
" |
|
35 |
! |
|
36 |
||
37 |
documentation |
|
38 |
" |
|
39 |
I implement a valueHolder which remembers the previous value whenever changed. |
|
40 |
||
41 |
[author:] |
|
42 |
Claus Gittinger |
|
43 |
" |
|
44 |
! ! |
|
45 |
||
46 |
!ValueHolderWithRememberedPreviousValue methodsFor:'accessing'! |
|
47 |
||
3271
2a9459856e15
class: ValueHolderWithRememberedPreviousValue
Claus Gittinger <cg@exept.de>
parents:
3263
diff
changeset
|
48 |
previousValue |
2a9459856e15
class: ValueHolderWithRememberedPreviousValue
Claus Gittinger <cg@exept.de>
parents:
3263
diff
changeset
|
49 |
^ previousValue |
2a9459856e15
class: ValueHolderWithRememberedPreviousValue
Claus Gittinger <cg@exept.de>
parents:
3263
diff
changeset
|
50 |
! |
2a9459856e15
class: ValueHolderWithRememberedPreviousValue
Claus Gittinger <cg@exept.de>
parents:
3263
diff
changeset
|
51 |
|
3263 | 52 |
setValue:anObject |
53 |
"set my value without notification." |
|
54 |
||
55 |
previousValue := value. |
|
56 |
value := anObject. |
|
57 |
! ! |
|
58 |
||
59 |
!ValueHolderWithRememberedPreviousValue class methodsFor:'documentation'! |
|
60 |
||
61 |
version |
|
3271
2a9459856e15
class: ValueHolderWithRememberedPreviousValue
Claus Gittinger <cg@exept.de>
parents:
3263
diff
changeset
|
62 |
^ '$Header: /cvs/stx/stx/libview2/ValueHolderWithRememberedPreviousValue.st,v 1.2 2014-01-13 13:40:04 cg Exp $' |
3263 | 63 |
! |
64 |
||
65 |
version_CVS |
|
3271
2a9459856e15
class: ValueHolderWithRememberedPreviousValue
Claus Gittinger <cg@exept.de>
parents:
3263
diff
changeset
|
66 |
^ '$Header: /cvs/stx/stx/libview2/ValueHolderWithRememberedPreviousValue.st,v 1.2 2014-01-13 13:40:04 cg Exp $' |
3263 | 67 |
! ! |
68 |