ActivityNotification.st
author ca
Fri, 04 Jun 2004 15:22:43 +0200
changeset 8371 4493f5ac7405
parent 8329 1828c8969866
child 10515 af20fca71049
permissions -rw-r--r--
*** empty log message ***
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
8329
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
     1
"
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
     2
 COPYRIGHT (c) 2003 by eXept Software AG
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
     3
              All Rights Reserved
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
     4
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
     5
 This software is furnished under a license and may be used
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
     6
 only in accordance with the terms of that license and with the
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
     7
 inclusion of the above copyright notice.   This software may not
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
     8
 be provided or otherwise made available to, or used by, any
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
     9
 other person.  No title to or ownership of the software is
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    10
 hereby transferred.
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    11
"
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    12
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    13
"{ Package: 'stx:libbasic' }"
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    14
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    15
UserNotification subclass:#ActivityNotification
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    16
	instanceVariableNames:''
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    17
	classVariableNames:''
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    18
	poolDictionaries:''
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    19
	category:'Kernel-Exceptions'
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    20
!
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    21
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    22
!ActivityNotification class methodsFor:'documentation'!
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    23
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    24
copyright
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    25
"
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    26
 COPYRIGHT (c) 2003 by eXept Software AG
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    27
              All Rights Reserved
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    28
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    29
 This software is furnished under a license and may be used
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    30
 only in accordance with the terms of that license and with the
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    31
 inclusion of the above copyright notice.   This software may not
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    32
 be provided or otherwise made available to, or used by, any
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    33
 other person.  No title to or ownership of the software is
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    34
 hereby transferred.
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    35
"
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    36
!
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    37
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    38
documentation
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    39
"    
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    40
    ActivityNotification can be raised from deeply nested methods, which are going to perform
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    41
    some long-time activity.
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    42
8371
4493f5ac7405 *** empty log message ***
ca
parents: 8329
diff changeset
    43
    If there is a handler for the ActivityNotification, that one is called,
8329
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    44
    passing the argument. The handler should show this message whereever it likes,
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    45
    and proceed. If there is no handler, ActivityNotification is simply ignored.
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    46
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    47
    This is very useful to pass busy messages up to some higher level (typically a view)
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    48
    which likes to display that message in its label or a busy-box.
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    49
    It could also be put into some logfile or printed on the standard output/error.
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    50
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    51
    It produces an info box with the message on the screen. 
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    52
    If no display is available, the message is written 
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    53
    to the Transcript.
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    54
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    55
    [see also:]
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    56
        Signal
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    57
"
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    58
! !
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    59
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    60
!ActivityNotification class methodsFor:'initialization'!
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    61
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    62
initialize
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    63
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    64
    NotifierString := 'activity'.
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    65
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    66
    "
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    67
     self initialize
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    68
    "
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    69
! !
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    70
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    71
!ActivityNotification class methodsFor:'documentation'!
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    72
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    73
version
8371
4493f5ac7405 *** empty log message ***
ca
parents: 8329
diff changeset
    74
    ^ '$Header: /cvs/stx/stx/libbasic/ActivityNotification.st,v 1.2 2004-06-04 13:22:14 ca Exp $'
8329
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    75
! !
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    76
1828c8969866 initial checkin
Stefan Vogel <sv@exept.de>
parents:
diff changeset
    77
ActivityNotification initialize!