ProjectView.st
author Claus Gittinger <cg@exept.de>
Fri, 23 Apr 1999 14:47:08 +0200
changeset 2118 15936084e52b
parent 2109 a0fe5f821c3a
child 2302 8266e9ad23c7
permissions -rw-r--r--
category change
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
88
a38a2e87687b *** empty log message ***
claus
parents: 85
diff changeset
     1
"
a38a2e87687b *** empty log message ***
claus
parents: 85
diff changeset
     2
 COPYRIGHT (c) 1994 by Claus Gittinger
a38a2e87687b *** empty log message ***
claus
parents: 85
diff changeset
     3
	      All Rights Reserved
a38a2e87687b *** empty log message ***
claus
parents: 85
diff changeset
     4
a38a2e87687b *** empty log message ***
claus
parents: 85
diff changeset
     5
 This software is furnished under a license and may be used
a38a2e87687b *** empty log message ***
claus
parents: 85
diff changeset
     6
 only in accordance with the terms of that license and with the
a38a2e87687b *** empty log message ***
claus
parents: 85
diff changeset
     7
 inclusion of the above copyright notice.   This software may not
a38a2e87687b *** empty log message ***
claus
parents: 85
diff changeset
     8
 be provided or otherwise made available to, or used by, any
a38a2e87687b *** empty log message ***
claus
parents: 85
diff changeset
     9
 other person.  No title to or ownership of the software is
a38a2e87687b *** empty log message ***
claus
parents: 85
diff changeset
    10
 hereby transferred.
a38a2e87687b *** empty log message ***
claus
parents: 85
diff changeset
    11
"
a38a2e87687b *** empty log message ***
claus
parents: 85
diff changeset
    12
0
571fd5eee315 Initial revision
claus
parents:
diff changeset
    13
StandardSystemView subclass:#ProjectView
278
9d33deca396c better message (nationalized)
Claus Gittinger <cg@exept.de>
parents: 272
diff changeset
    14
	instanceVariableNames:'myProject toggle'
9d33deca396c better message (nationalized)
Claus Gittinger <cg@exept.de>
parents: 272
diff changeset
    15
	classVariableNames:'ActiveProjectView'
9d33deca396c better message (nationalized)
Claus Gittinger <cg@exept.de>
parents: 272
diff changeset
    16
	poolDictionaries:''
9d33deca396c better message (nationalized)
Claus Gittinger <cg@exept.de>
parents: 272
diff changeset
    17
	category:'Interface-Smalltalk'
0
571fd5eee315 Initial revision
claus
parents:
diff changeset
    18
!
571fd5eee315 Initial revision
claus
parents:
diff changeset
    19
796
b8edcbceaa18 XtHTML is no longer there ...
Claus Gittinger <cg@exept.de>
parents: 692
diff changeset
    20
!ProjectView class methodsFor:'documentation'!
88
a38a2e87687b *** empty log message ***
claus
parents: 85
diff changeset
    21
a38a2e87687b *** empty log message ***
claus
parents: 85
diff changeset
    22
copyright
a38a2e87687b *** empty log message ***
claus
parents: 85
diff changeset
    23
"
a38a2e87687b *** empty log message ***
claus
parents: 85
diff changeset
    24
 COPYRIGHT (c) 1994 by Claus Gittinger
a38a2e87687b *** empty log message ***
claus
parents: 85
diff changeset
    25
	      All Rights Reserved
a38a2e87687b *** empty log message ***
claus
parents: 85
diff changeset
    26
a38a2e87687b *** empty log message ***
claus
parents: 85
diff changeset
    27
 This software is furnished under a license and may be used
a38a2e87687b *** empty log message ***
claus
parents: 85
diff changeset
    28
 only in accordance with the terms of that license and with the
a38a2e87687b *** empty log message ***
claus
parents: 85
diff changeset
    29
 inclusion of the above copyright notice.   This software may not
a38a2e87687b *** empty log message ***
claus
parents: 85
diff changeset
    30
 be provided or otherwise made available to, or used by, any
a38a2e87687b *** empty log message ***
claus
parents: 85
diff changeset
    31
 other person.  No title to or ownership of the software is
a38a2e87687b *** empty log message ***
claus
parents: 85
diff changeset
    32
 hereby transferred.
a38a2e87687b *** empty log message ***
claus
parents: 85
diff changeset
    33
"
272
9eeb8aa5d1d7 commentary
Claus Gittinger <cg@exept.de>
parents: 265
diff changeset
    34
!
9eeb8aa5d1d7 commentary
Claus Gittinger <cg@exept.de>
parents: 265
diff changeset
    35
9eeb8aa5d1d7 commentary
Claus Gittinger <cg@exept.de>
parents: 265
diff changeset
    36
documentation
9eeb8aa5d1d7 commentary
Claus Gittinger <cg@exept.de>
parents: 265
diff changeset
    37
"
9eeb8aa5d1d7 commentary
Claus Gittinger <cg@exept.de>
parents: 265
diff changeset
    38
    ProjectViews basically offer two functionalities:
9eeb8aa5d1d7 commentary
Claus Gittinger <cg@exept.de>
parents: 265
diff changeset
    39
9eeb8aa5d1d7 commentary
Claus Gittinger <cg@exept.de>
parents: 265
diff changeset
    40
      - keep a group of windows in order to organize the desktop
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
    41
	(I am not sure, if this is really a useful feature, now that we
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
    42
	 have modern windowManagers which have multiple desktops as well).
272
9eeb8aa5d1d7 commentary
Claus Gittinger <cg@exept.de>
parents: 265
diff changeset
    43
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
    44
	All views as created while a project is active are remembered
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
    45
	and can be hidden/shown altogether.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
    46
	(this has nothing to do with windowGroups)
272
9eeb8aa5d1d7 commentary
Claus Gittinger <cg@exept.de>
parents: 265
diff changeset
    47
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
    48
	Also, it is possible to close down all those windows (by destroying the project).
272
9eeb8aa5d1d7 commentary
Claus Gittinger <cg@exept.de>
parents: 265
diff changeset
    49
9eeb8aa5d1d7 commentary
Claus Gittinger <cg@exept.de>
parents: 265
diff changeset
    50
      - keep defaults for various system activities:
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
    51
		- the fileOut directory (i.e. where the SystemBrowser creates fileOut sources)
272
9eeb8aa5d1d7 commentary
Claus Gittinger <cg@exept.de>
parents: 265
diff changeset
    52
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
    53
		- keep the source module/package
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
    54
		    thats the default offered when classes are checkedIn the very first time
278
9d33deca396c better message (nationalized)
Claus Gittinger <cg@exept.de>
parents: 272
diff changeset
    55
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
    56
		- keep a default package-identifier assigned when classes/methods are created/modified.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
    57
		    thats mostly useful to browse all classes/methods that have been touched
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
    58
		    in a projects context
272
9eeb8aa5d1d7 commentary
Claus Gittinger <cg@exept.de>
parents: 265
diff changeset
    59
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
    60
		- keep a per-project changeList
278
9d33deca396c better message (nationalized)
Claus Gittinger <cg@exept.de>
parents: 272
diff changeset
    61
9d33deca396c better message (nationalized)
Claus Gittinger <cg@exept.de>
parents: 272
diff changeset
    62
      - allow opening a browser on all classes/methods which were created or modified
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
    63
	while a project was active.
272
9eeb8aa5d1d7 commentary
Claus Gittinger <cg@exept.de>
parents: 265
diff changeset
    64
278
9d33deca396c better message (nationalized)
Claus Gittinger <cg@exept.de>
parents: 272
diff changeset
    65
      - allow opening a browser on this projects changeList (which contains the subset of changes
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
    66
	 which were done while this project was active)
278
9d33deca396c better message (nationalized)
Claus Gittinger <cg@exept.de>
parents: 272
diff changeset
    67
9d33deca396c better message (nationalized)
Claus Gittinger <cg@exept.de>
parents: 272
diff changeset
    68
      - allow removal of all classes/methods which have the current projects packageIdentifier
955
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
    69
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
    70
    [author:]
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
    71
	Claus Gittinger
955
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
    72
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
    73
    [see also:]
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
    74
	Project
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
    75
	Namespace
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
    76
	CVSSourceCodemanager
272
9eeb8aa5d1d7 commentary
Claus Gittinger <cg@exept.de>
parents: 265
diff changeset
    77
"
955
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
    78
88
a38a2e87687b *** empty log message ***
claus
parents: 85
diff changeset
    79
! !
a38a2e87687b *** empty log message ***
claus
parents: 85
diff changeset
    80
796
b8edcbceaa18 XtHTML is no longer there ...
Claus Gittinger <cg@exept.de>
parents: 692
diff changeset
    81
!ProjectView class methodsFor:'instance creation'!
0
571fd5eee315 Initial revision
claus
parents:
diff changeset
    82
571fd5eee315 Initial revision
claus
parents:
diff changeset
    83
for:aProject
955
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
    84
    "create & open a new projectView on some project"
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
    85
0
571fd5eee315 Initial revision
claus
parents:
diff changeset
    86
    |newView|
571fd5eee315 Initial revision
claus
parents:
diff changeset
    87
571fd5eee315 Initial revision
claus
parents:
diff changeset
    88
    newView := super new.
571fd5eee315 Initial revision
claus
parents:
diff changeset
    89
    newView setProject:aProject.
571fd5eee315 Initial revision
claus
parents:
diff changeset
    90
    ^ newView
571fd5eee315 Initial revision
claus
parents:
diff changeset
    91
955
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
    92
    "
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
    93
     ProjectView for:(Project new)
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
    94
    "
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
    95
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
    96
    "Modified: 14.2.1997 / 13:46:07 / cg"
0
571fd5eee315 Initial revision
claus
parents:
diff changeset
    97
! !
571fd5eee315 Initial revision
claus
parents:
diff changeset
    98
2118
15936084e52b category change
Claus Gittinger <cg@exept.de>
parents: 2109
diff changeset
    99
!ProjectView methodsFor:'initialize / release'!
217
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   100
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   101
addToCurrentProject
955
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   102
    "add this view to the current projects set of views.
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   103
     Ignored here - ProjectViews are global."
217
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   104
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   105
    ^ self
955
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   106
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   107
    "Modified: 14.2.1997 / 13:35:58 / cg"
217
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   108
!
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   109
2118
15936084e52b category change
Claus Gittinger <cg@exept.de>
parents: 2109
diff changeset
   110
destroy
15936084e52b category change
Claus Gittinger <cg@exept.de>
parents: 2109
diff changeset
   111
    "Let user confirm, then close all of my views, and get rid of the changeList.
15936084e52b category change
Claus Gittinger <cg@exept.de>
parents: 2109
diff changeset
   112
     However, methods and classes are not restored to their
15936084e52b category change
Claus Gittinger <cg@exept.de>
parents: 2109
diff changeset
   113
     previous state."
15936084e52b category change
Claus Gittinger <cg@exept.de>
parents: 2109
diff changeset
   114
15936084e52b category change
Claus Gittinger <cg@exept.de>
parents: 2109
diff changeset
   115
    |views|
15936084e52b category change
Claus Gittinger <cg@exept.de>
parents: 2109
diff changeset
   116
15936084e52b category change
Claus Gittinger <cg@exept.de>
parents: 2109
diff changeset
   117
    myProject notNil ifTrue:[
15936084e52b category change
Claus Gittinger <cg@exept.de>
parents: 2109
diff changeset
   118
        views := myProject views.
15936084e52b category change
Claus Gittinger <cg@exept.de>
parents: 2109
diff changeset
   119
        (views size > 0) ifTrue:[
15936084e52b category change
Claus Gittinger <cg@exept.de>
parents: 2109
diff changeset
   120
            |box|
15936084e52b category change
Claus Gittinger <cg@exept.de>
parents: 2109
diff changeset
   121
15936084e52b category change
Claus Gittinger <cg@exept.de>
parents: 2109
diff changeset
   122
            box := YesNoBox new.
15936084e52b category change
Claus Gittinger <cg@exept.de>
parents: 2109
diff changeset
   123
            box title:(resources string:'PROJECT_DESTROY') withCRs.
15936084e52b category change
Claus Gittinger <cg@exept.de>
parents: 2109
diff changeset
   124
            box okText:(resources string:'yes').
15936084e52b category change
Claus Gittinger <cg@exept.de>
parents: 2109
diff changeset
   125
            (box confirm) ifFalse:[^ self]
15936084e52b category change
Claus Gittinger <cg@exept.de>
parents: 2109
diff changeset
   126
        ].
15936084e52b category change
Claus Gittinger <cg@exept.de>
parents: 2109
diff changeset
   127
    ].
15936084e52b category change
Claus Gittinger <cg@exept.de>
parents: 2109
diff changeset
   128
    self doDestroy
15936084e52b category change
Claus Gittinger <cg@exept.de>
parents: 2109
diff changeset
   129
15936084e52b category change
Claus Gittinger <cg@exept.de>
parents: 2109
diff changeset
   130
    "Modified: 14.2.1997 / 13:39:03 / cg"
15936084e52b category change
Claus Gittinger <cg@exept.de>
parents: 2109
diff changeset
   131
!
15936084e52b category change
Claus Gittinger <cg@exept.de>
parents: 2109
diff changeset
   132
217
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   133
initialize
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   134
    super initialize.
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   135
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   136
    "/
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   137
    "/ create the toggle ...
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   138
    "/
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   139
    toggle := Toggle in:self.
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   140
    toggle borderWidth:0.
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   141
    toggle pressAction:[self showProject].
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   142
    toggle releaseAction:[self hideProject].
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   143
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   144
    "/
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   145
    "/ and give it a menu
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   146
    "/
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   147
1001
b7dc91d2499d added 'browse redefined'
Claus Gittinger <cg@exept.de>
parents: 963
diff changeset
   148
    toggle menuHolder:self; menuMessage:#projectMenu.
217
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   149
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   150
    "Created: 25.11.1995 / 18:06:32 / cg"
1001
b7dc91d2499d added 'browse redefined'
Claus Gittinger <cg@exept.de>
parents: 963
diff changeset
   151
    "Modified: 27.1.1997 / 11:53:18 / cg"
217
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   152
!
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   153
1001
b7dc91d2499d added 'browse redefined'
Claus Gittinger <cg@exept.de>
parents: 963
diff changeset
   154
projectMenu
b7dc91d2499d added 'browse redefined'
Claus Gittinger <cg@exept.de>
parents: 963
diff changeset
   155
    "return a popUpMenu"
b7dc91d2499d added 'browse redefined'
Claus Gittinger <cg@exept.de>
parents: 963
diff changeset
   156
468
66637cf315a5 added fileOutClasses menu entry
Claus Gittinger <cg@exept.de>
parents: 278
diff changeset
   157
    |labels selectors m|
217
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   158
468
66637cf315a5 added fileOutClasses menu entry
Claus Gittinger <cg@exept.de>
parents: 278
diff changeset
   159
    labels := #(
1468
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   160
                    'class documentation'
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   161
                    '-'
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   162
                    'show'
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   163
                    'hide'
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   164
                    '-'
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   165
                    'changes'
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   166
                    'browse'
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   167
                    'browse redefined'
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   168
                    'fileOut classes'
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   169
                    '-'
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   170
                    'fileOut directory ...'
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   171
                    'repository defaults ...'
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   172
                    'package name ...'
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   173
                    'default nameSpace for fileIn ...'
217
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   174
"/                        '-'
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   175
"/                        'save project code'
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   176
"/                        'build'
1468
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   177
                    '-'
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   178
                    'remove package code'
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   179
                    'remove project'
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   180
                    '-'
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   181
                    'rename ...'
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   182
               ).
217
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   183
468
66637cf315a5 added fileOutClasses menu entry
Claus Gittinger <cg@exept.de>
parents: 278
diff changeset
   184
     selectors := #(        
1468
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   185
                    showClassDocumentation
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   186
                    nil
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   187
                    showProject
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   188
                    hideProject
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   189
                    nil
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   190
                    browseChanges
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   191
                    browsePackage
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   192
                    browseRedefined
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   193
                    fileOutClasses
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   194
                    nil
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   195
                    projectDirectory
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   196
                    projectRepositoryAndModule
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   197
                    projectPackage
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   198
                    projectNameSpace
217
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   199
"/                        nil
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   200
"/                        saveProjectFiles
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   201
"/                        buildProject
1468
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   202
                    nil
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   203
                    removePackage
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   204
                    destroy
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   205
                    nil
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   206
                    renameProject
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   207
                ).
468
66637cf315a5 added fileOutClasses menu entry
Claus Gittinger <cg@exept.de>
parents: 278
diff changeset
   208
66637cf315a5 added fileOutClasses menu entry
Claus Gittinger <cg@exept.de>
parents: 278
diff changeset
   209
    m := PopUpMenu
1468
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   210
                labels:(resources array:labels)
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   211
                selectors:selectors
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   212
                receiver:self.
468
66637cf315a5 added fileOutClasses menu entry
Claus Gittinger <cg@exept.de>
parents: 278
diff changeset
   213
66637cf315a5 added fileOutClasses menu entry
Claus Gittinger <cg@exept.de>
parents: 278
diff changeset
   214
    SourceCodeManager isNil ifTrue:[
1468
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   215
        m disableAll:#(#projectRepository #projectRepositoryAndModule).
217
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   216
    ].
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   217
1001
b7dc91d2499d added 'browse redefined'
Claus Gittinger <cg@exept.de>
parents: 963
diff changeset
   218
    ^ m
217
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   219
1468
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   220
    "Created: / 27.1.1997 / 11:53:30 / cg"
65852291e1c4 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1348
diff changeset
   221
    "Modified: / 6.2.1998 / 12:57:21 / cg"
217
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   222
! !
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   223
57
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   224
!ProjectView methodsFor:'menu actions'!
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   225
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   226
browseChanges
955
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   227
    "open a changeBrowser showing all changes made in this project
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   228
     (i.e. while this project was the active project)"
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   229
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   230
    |changes b|
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   231
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   232
    changes := myProject changeSet.
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   233
    changes size == 0 ifTrue:[
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   234
	self warn:(resources string:'no changes made in this project (yet)').
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   235
	^ self
955
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   236
    ].
57
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   237
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   238
    b := ChangeSetBrowser openOn:(myProject changeSet).
278
9d33deca396c better message (nationalized)
Claus Gittinger <cg@exept.de>
parents: 272
diff changeset
   239
    b label:(resources string:'Changes in %1' with:myProject name)
955
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   240
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   241
    "Modified: 14.2.1997 / 13:36:40 / cg"
57
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   242
!
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   243
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   244
browsePackage
278
9d33deca396c better message (nationalized)
Claus Gittinger <cg@exept.de>
parents: 272
diff changeset
   245
    "launch browsers for all classes/methods which are defined in this package
9d33deca396c better message (nationalized)
Claus Gittinger <cg@exept.de>
parents: 272
diff changeset
   246
     (i.e. whose packageIdentifier is the same as my Projects packageIdentifier)"
57
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   247
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   248
    self topView withWaitCursorDo:[
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   249
	|classes packageName methods methodList anyClasses anyMethods ignoredClasses|
278
9d33deca396c better message (nationalized)
Claus Gittinger <cg@exept.de>
parents: 272
diff changeset
   250
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   251
	anyMethods := anyClasses := false.
57
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   252
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   253
	packageName := myProject packageName.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   254
	classes := myProject classes.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   255
	(classes notNil and:[classes notEmpty]) ifTrue:[
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   256
	    anyClasses := true.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   257
	].
57
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   258
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   259
	methods := myProject individualMethods.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   260
	methods notEmpty ifTrue:[
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   261
	    anyMethods := true.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   262
	    SystemBrowser browseMethods:methods
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   263
				  title:(resources string:'individual methods in package %1' with:packageName).
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   264
	].
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   265
	anyClasses ifTrue:[
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   266
	    SystemBrowser browseClasses:classes
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   267
				  title:(resources string:'classes in package %1' with:packageName).
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   268
	].
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   269
	(anyClasses or:[anyMethods]) ifFalse:[
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   270
	    self information:(resources string:'no classes or methods in this project (yet)')
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   271
	]
57
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   272
    ]
265
3b1d5710e4a5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 259
diff changeset
   273
3b1d5710e4a5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 259
diff changeset
   274
    "Created: 10.12.1995 / 00:08:58 / cg"
278
9d33deca396c better message (nationalized)
Claus Gittinger <cg@exept.de>
parents: 272
diff changeset
   275
    "Modified: 12.12.1995 / 16:35:07 / cg"
57
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   276
!
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   277
217
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   278
browseProps
955
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   279
    "show the projects properties.
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   280
     This is not yet finished ...
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   281
     ... and will look better, once property inspector runs ..."
217
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   282
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   283
    myProject properties inspect
955
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   284
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   285
    "Modified: 14.2.1997 / 13:37:15 / cg"
217
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   286
!
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   287
1001
b7dc91d2499d added 'browse redefined'
Claus Gittinger <cg@exept.de>
parents: 963
diff changeset
   288
browseRedefined
b7dc91d2499d added 'browse redefined'
Claus Gittinger <cg@exept.de>
parents: 963
diff changeset
   289
    "launch browsers for all redefined methods.
b7dc91d2499d added 'browse redefined'
Claus Gittinger <cg@exept.de>
parents: 963
diff changeset
   290
     Thats methods which existed before and were redefined by package methods"
b7dc91d2499d added 'browse redefined'
Claus Gittinger <cg@exept.de>
parents: 963
diff changeset
   291
b7dc91d2499d added 'browse redefined'
Claus Gittinger <cg@exept.de>
parents: 963
diff changeset
   292
    self topView withWaitCursorDo:[
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   293
	|redefined methods|
1001
b7dc91d2499d added 'browse redefined'
Claus Gittinger <cg@exept.de>
parents: 963
diff changeset
   294
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   295
	redefined := myProject overwrittenMethods.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   296
	redefined notNil ifTrue:[
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   297
	    methods := redefined values.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   298
	].
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   299
	methods size > 0 ifTrue:[
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   300
	    SystemBrowser browseMethods:methods
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   301
				  title:(resources string:'redefined methods in package %1' with:myProject packageName).
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   302
	] ifFalse:[
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   303
	    self information:(resources string:'no redefined methods in this project (yet)')
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   304
	]
1001
b7dc91d2499d added 'browse redefined'
Claus Gittinger <cg@exept.de>
parents: 963
diff changeset
   305
    ]
b7dc91d2499d added 'browse redefined'
Claus Gittinger <cg@exept.de>
parents: 963
diff changeset
   306
b7dc91d2499d added 'browse redefined'
Claus Gittinger <cg@exept.de>
parents: 963
diff changeset
   307
    "Created: 27.1.1997 / 11:57:03 / cg"
b7dc91d2499d added 'browse redefined'
Claus Gittinger <cg@exept.de>
parents: 963
diff changeset
   308
    "Modified: 27.1.1997 / 11:58:06 / cg"
b7dc91d2499d added 'browse redefined'
Claus Gittinger <cg@exept.de>
parents: 963
diff changeset
   309
!
b7dc91d2499d added 'browse redefined'
Claus Gittinger <cg@exept.de>
parents: 963
diff changeset
   310
217
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   311
buildProject
955
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   312
    "build the project; this is not yet finished ...
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   313
     ... and will eventually create all sources, makefile and
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   314
     build what is to be built: either a classLibrary or an application"
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   315
217
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   316
    self topView withWaitCursorDo:[
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   317
	|dir|
217
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   318
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   319
	self saveProjectFiles.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   320
	(self confirm:'make object files in: ' ,  dir , ' ?') ifTrue:[
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   321
	    myProject buildProject.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   322
	]
217
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   323
    ].
955
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   324
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   325
    "Modified: 14.2.1997 / 13:38:06 / cg"
217
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   326
!
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   327
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   328
doDestroy
955
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   329
    "close all of my views, and get rid of the changeList.
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   330
     However, methods and classes are not restored to their
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   331
     previous state.
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   332
     No confiramtion here."
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   333
217
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   334
    self hideProject.
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   335
    myProject := nil.
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   336
    super destroy
955
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   337
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   338
    "Modified: 14.2.1997 / 13:39:18 / cg"
217
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   339
!
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   340
468
66637cf315a5 added fileOutClasses menu entry
Claus Gittinger <cg@exept.de>
parents: 278
diff changeset
   341
fileOutClasses
66637cf315a5 added fileOutClasses menu entry
Claus Gittinger <cg@exept.de>
parents: 278
diff changeset
   342
    "fileout all classes belonging to that package.
66637cf315a5 added fileOutClasses menu entry
Claus Gittinger <cg@exept.de>
parents: 278
diff changeset
   343
     CAVEAT: individual methods are not yet supported."
66637cf315a5 added fileOutClasses menu entry
Claus Gittinger <cg@exept.de>
parents: 278
diff changeset
   344
66637cf315a5 added fileOutClasses menu entry
Claus Gittinger <cg@exept.de>
parents: 278
diff changeset
   345
    self topView withWaitCursorDo:[
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   346
	|classes packageName methods methodList anyClasses anyMethods ignoredClasses|
468
66637cf315a5 added fileOutClasses menu entry
Claus Gittinger <cg@exept.de>
parents: 278
diff changeset
   347
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   348
	anyMethods := anyClasses := false.
468
66637cf315a5 added fileOutClasses menu entry
Claus Gittinger <cg@exept.de>
parents: 278
diff changeset
   349
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   350
	packageName := myProject packageName.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   351
	classes := myProject classes.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   352
	(classes notNil and:[classes notEmpty]) ifTrue:[
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   353
	    anyClasses := true.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   354
	].
468
66637cf315a5 added fileOutClasses menu entry
Claus Gittinger <cg@exept.de>
parents: 278
diff changeset
   355
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   356
	methods := myProject individualMethods.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   357
	methods notEmpty ifTrue:[
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   358
	    anyMethods := true.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   359
	    self warn:'individual methods are currently not handled'
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   360
	].
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   361
	anyClasses ifTrue:[
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   362
	    classes do:[:aClass |
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   363
		Transcript showCR:'fileOut: ' , aClass name , ' ...'.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   364
		aClass fileOut
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   365
	    ].
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   366
	].
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   367
	(anyClasses or:[anyMethods]) ifFalse:[
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   368
	    self information:(resources string:'no classes or methods in this project (yet)')
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   369
	]
468
66637cf315a5 added fileOutClasses menu entry
Claus Gittinger <cg@exept.de>
parents: 278
diff changeset
   370
    ]
66637cf315a5 added fileOutClasses menu entry
Claus Gittinger <cg@exept.de>
parents: 278
diff changeset
   371
66637cf315a5 added fileOutClasses menu entry
Claus Gittinger <cg@exept.de>
parents: 278
diff changeset
   372
    "Created: 11.4.1996 / 19:29:50 / cg"
66637cf315a5 added fileOutClasses menu entry
Claus Gittinger <cg@exept.de>
parents: 278
diff changeset
   373
!
66637cf315a5 added fileOutClasses menu entry
Claus Gittinger <cg@exept.de>
parents: 278
diff changeset
   374
217
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   375
hideProject
955
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   376
    "hide all views belonging to that project and switch
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   377
     to the default project"
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   378
1980
e7719fbe4293 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1490
diff changeset
   379
    myProject notNil ifTrue:[
e7719fbe4293 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1490
diff changeset
   380
        myProject hideViews.
e7719fbe4293 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1490
diff changeset
   381
    ].
217
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   382
    ActiveProjectView := nil.
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   383
    toggle turnOff.
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   384
    Project setDefaultProject.
955
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   385
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   386
    "Modified: 14.2.1997 / 13:39:43 / cg"
217
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   387
!
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   388
57
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   389
projectDirectory
955
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   390
    "ask for the default directory, where fileOut will write
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   391
     its files. Will eventually also be the place, where makefiles
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   392
     and additional stuff is saved, for project building."
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   393
57
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   394
    |box d|
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   395
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   396
    box := FilenameEnterBox new.
85
d9713a3ca092 *** empty log message ***
claus
parents: 57
diff changeset
   397
    box directoriesOnly.
278
9d33deca396c better message (nationalized)
Claus Gittinger <cg@exept.de>
parents: 272
diff changeset
   398
    box title:(resources string:'PROJECT_DIRECTPORY') withCRs.
57
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   399
    (d := myProject directory) notNil ifTrue:[
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   400
	box initialText:d
57
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   401
    ].
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   402
    box action:[:dirName |
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   403
	(OperatingSystem isDirectory:dirName) ifFalse:[
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   404
	    (OperatingSystem isValidPath:dirName) ifTrue:[
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   405
		self warn:(resources string:'%1 is not a valid directory' with:dirName).
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   406
		^ self
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   407
	    ].
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   408
	    (self confirm:(resources string:'%1 does not exist\\create ?' with:dirName) withCRs) ifTrue:[
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   409
		(OperatingSystem recursiveCreateDirectory:dirName) ifFalse:[
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   410
		    self warn:(resources string:'cannot create %1' with:dirName)
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   411
		]
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   412
	    ].
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   413
	].
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   414
	"did it work ?"
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   415
	(OperatingSystem isDirectory:dirName) ifTrue:[
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   416
	    myProject directory:dirName
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   417
	].
57
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   418
    ].
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   419
    box showAtPointer
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   420
955
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   421
    "Modified: 14.2.1997 / 13:44:59 / cg"
265
3b1d5710e4a5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 259
diff changeset
   422
!
3b1d5710e4a5 checkin from browser
Claus Gittinger <cg@exept.de>
parents: 259
diff changeset
   423
893
39307a122c30 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 796
diff changeset
   424
projectNameSpace
955
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   425
    "ask for the default nameSpace, into which new classes
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   426
     are loaded while this project is active.
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   427
     Useful before filing in alien code, to make certain that loaded
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   428
     classes do not conflict with existing ones ..."
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   429
893
39307a122c30 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 796
diff changeset
   430
    self topView withWaitCursorDo:[
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   431
	|box allNameSpaces|
893
39307a122c30 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 796
diff changeset
   432
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   433
	allNameSpaces := Namespace allNamespaces collect:[:ns | ns name].
893
39307a122c30 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 796
diff changeset
   434
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   435
	box := ListSelectionBox title:(resources string:'default nameSpace:') withCRs.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   436
	box list:(allNameSpaces asOrderedCollection sort).
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   437
	box action:[:nsName |
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   438
	    |ns|
893
39307a122c30 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 796
diff changeset
   439
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   440
	    "/ only create topLevel nameSpaces here
963
3d9083fde09f provide Smalltalk as homeNameSpace, when defining the projects
Claus Gittinger <cg@exept.de>
parents: 955
diff changeset
   441
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   442
	    Class nameSpaceQuerySignal 
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   443
	    answer:Smalltalk
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   444
	    do:[
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   445
		ns := Namespace name:nsName.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   446
	    ].    
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   447
	    myProject defaultNameSpace:ns
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   448
	].
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   449
	box showAtPointer
893
39307a122c30 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 796
diff changeset
   450
    ]
39307a122c30 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 796
diff changeset
   451
39307a122c30 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 796
diff changeset
   452
    "Created: 9.12.1995 / 16:50:45 / cg"
963
3d9083fde09f provide Smalltalk as homeNameSpace, when defining the projects
Claus Gittinger <cg@exept.de>
parents: 955
diff changeset
   453
    "Modified: 16.1.1997 / 01:00:06 / cg"
893
39307a122c30 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 796
diff changeset
   454
!
39307a122c30 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 796
diff changeset
   455
57
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   456
projectPackage
955
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   457
    "ask for the package identifier of this project.
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   458
     New classes and methods get this identifier, to find them
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   459
     quickly later."
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   460
57
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   461
    self topView withWaitCursorDo:[
2108
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   462
        |box p existingPackages allClasses|
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   463
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   464
        existingPackages := Set new.
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   465
        (allClasses := Smalltalk allClasses) do:[:aClass |
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   466
            |p|
259
c651fecef457 better defaults when creating a container
Claus Gittinger <cg@exept.de>
parents: 217
diff changeset
   467
2109
a0fe5f821c3a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2108
diff changeset
   468
            (aClass isNamespace 
a0fe5f821c3a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2108
diff changeset
   469
"/            or:[aClass isLoaded not]
a0fe5f821c3a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2108
diff changeset
   470
            ) ifFalse:[
2108
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   471
                p := aClass package.
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   472
                p size == 0 ifTrue:[
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   473
                    p := 'no package'.
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   474
                ].
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   475
                existingPackages add:(p asString).
57
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   476
2108
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   477
                aClass methodDictionary do:[:aMethod |
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   478
                    p := aMethod package.
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   479
                    p size == 0 ifTrue:[
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   480
                        p := 'no package'.
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   481
                    ].
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   482
                    existingPackages add:(p asString).
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   483
                ].
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   484
                aClass class methodDictionary do:[:aMethod |
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   485
                    p := aMethod package.
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   486
                    p size == 0 ifTrue:[
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   487
                        p := 'no package'.
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   488
                    ].
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   489
                    existingPackages add:(p asString).
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   490
                ].
2109
a0fe5f821c3a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 2108
diff changeset
   491
            ].
2108
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   492
        ].
259
c651fecef457 better defaults when creating a container
Claus Gittinger <cg@exept.de>
parents: 217
diff changeset
   493
2108
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   494
        box := ListSelectionBox title:(resources string:'PROJECT_PACKAGENAME') withCRs.
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   495
        box list:(existingPackages asOrderedCollection sort).
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   496
        (p := myProject packageName) notNil ifTrue:[
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   497
            box initialText:p
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   498
        ].
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   499
        box action:[:packageName |
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   500
            |someClass module directory|
57
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   501
2108
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   502
            "/ (try) to extract the module & repository directory from someClass which
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   503
            "/ is already contained in that package
259
c651fecef457 better defaults when creating a container
Claus Gittinger <cg@exept.de>
parents: 217
diff changeset
   504
2108
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   505
            Smalltalk allClasses 
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   506
                detect:[:cls | 
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   507
                                |info|
57
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   508
2108
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   509
                                (cls package = packageName) ifTrue:[
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   510
                                    (info := cls packageSourceCodeInfo) notNil ifTrue:[
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   511
                                        module := info at:#module ifAbsent:nil.
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   512
                                        directory := info at:#directory ifAbsent:nil.
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   513
                                    ]
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   514
                                ].
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   515
                                module notNil and:[directory notNil].
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   516
                        ]
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   517
                ifNone:nil.
259
c651fecef457 better defaults when creating a container
Claus Gittinger <cg@exept.de>
parents: 217
diff changeset
   518
2108
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   519
            module notNil ifTrue:[
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   520
                myProject repositoryModule:module
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   521
            ].
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   522
            directory notNil ifTrue:[
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   523
                myProject repositoryDirectory:directory
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   524
            ].
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   525
            myProject packageName:packageName.
259
c651fecef457 better defaults when creating a container
Claus Gittinger <cg@exept.de>
parents: 217
diff changeset
   526
2108
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   527
        ].
bb5caa5f014a checkin from browser
Claus Gittinger <cg@exept.de>
parents: 1980
diff changeset
   528
        box showAtPointer
57
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   529
    ]
259
c651fecef457 better defaults when creating a container
Claus Gittinger <cg@exept.de>
parents: 217
diff changeset
   530
c651fecef457 better defaults when creating a container
Claus Gittinger <cg@exept.de>
parents: 217
diff changeset
   531
    "Created: 9.12.1995 / 16:50:45 / cg"
1326
aab1605ad945 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1013
diff changeset
   532
    "Modified: 19.9.1997 / 10:55:19 / cg"
110
claus
parents: 106
diff changeset
   533
!
57
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   534
955
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   535
projectRepositoryAndModule
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   536
    "ask for a default module and package directory.
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   537
     This is offered as default, when new containers are
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   538
     created. However, when creating, these can still be changed"
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   539
1490
f26cf3c5f39f removed unused local
Claus Gittinger <cg@exept.de>
parents: 1468
diff changeset
   540
    |box moduleHolder dirHolder|
955
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   541
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   542
    box := DialogBox new.
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   543
    (box addTextLabel:(resources string:'PROJECT_MODULEANDDIR') withCRs)
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   544
	adjust:#left.
955
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   545
    box addHorizontalLine.
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   546
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   547
    moduleHolder := myProject repositoryModule asValue.
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   548
    dirHolder := myProject repositoryDirectory asValue.
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   549
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   550
    (box addTextLabel:(resources string:'PROJECT_MODULEDIR') withCRs)
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   551
	adjust:#left.
955
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   552
    box addFilenameInputFieldOn:moduleHolder in:nil tabable:true.
217
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   553
1490
f26cf3c5f39f removed unused local
Claus Gittinger <cg@exept.de>
parents: 1468
diff changeset
   554
    box addVerticalSpace; addHorizontalLine; addVerticalSpace.
955
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   555
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   556
    (box addTextLabel:(resources string:'PROJECT_PACKAGEDIR') withCRs)
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   557
	adjust:#left.
955
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   558
    box addFilenameInputFieldOn:dirHolder in:nil tabable:true.
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   559
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   560
    box addAbortButton; addOkButton.
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   561
    box showAtPointer.
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   562
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   563
    box accepted ifTrue:[
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   564
	myProject repositoryModule:moduleHolder value.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   565
	myProject repositoryDirectory:dirHolder value.
217
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   566
    ].
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   567
955
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   568
    box destroy.
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   569
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   570
    "Modified: 14.2.1997 / 13:42:05 / cg"
217
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   571
!
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   572
110
claus
parents: 106
diff changeset
   573
removePackage
claus
parents: 106
diff changeset
   574
    "remove all classes and individual methods from the system.
claus
parents: 106
diff changeset
   575
     Currently, this cannot fully restore the state to before
claus
parents: 106
diff changeset
   576
     the time the package was loaded (redefined methods are lost).
claus
parents: 106
diff changeset
   577
     In the future, we may keep a backref of overwritten methods
claus
parents: 106
diff changeset
   578
     and restore them from their source ..."
57
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   579
110
claus
parents: 106
diff changeset
   580
    |classesToRemove methodsToRemove theProject|
claus
parents: 106
diff changeset
   581
claus
parents: 106
diff changeset
   582
    (myProject isNil
claus
parents: 106
diff changeset
   583
    or:[(theProject := myProject packageName) isNil]) ifTrue:[
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   584
	self warn:(resources string:'No current package.').
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   585
	^ self
110
claus
parents: 106
diff changeset
   586
    ].
claus
parents: 106
diff changeset
   587
claus
parents: 106
diff changeset
   588
    classesToRemove := IdentitySet new.
claus
parents: 106
diff changeset
   589
    methodsToRemove := IdentitySet new.
claus
parents: 106
diff changeset
   590
claus
parents: 106
diff changeset
   591
    Smalltalk allClassesDo:[:aClass |
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   592
	|p|
110
claus
parents: 106
diff changeset
   593
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   594
	(p := aClass package) notNil ifTrue:[
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   595
	    p = theProject  ifTrue:[
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   596
		classesToRemove add:aClass
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   597
	    ]
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   598
	].
110
claus
parents: 106
diff changeset
   599
    ].
claus
parents: 106
diff changeset
   600
    Smalltalk allClassesDo:[:aClass |
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   601
	|p|
110
claus
parents: 106
diff changeset
   602
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   603
	(classesToRemove includes:aClass) ifFalse:[
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   604
	    aClass methodDictionary keysAndValuesDo:[:sel :aMethod |
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   605
		(p := aMethod package) notNil ifTrue:[
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   606
		    p = theProject  ifTrue:[
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   607
			methodsToRemove add:aMethod
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   608
		    ]
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   609
		]
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   610
	    ].
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   611
	    aClass class methodDictionary keysAndValuesDo:[:sel :aMethod |
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   612
		(p := aMethod package) notNil ifTrue:[
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   613
		    p = theProject  ifTrue:[
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   614
			methodsToRemove add:aMethod
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   615
		    ]
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   616
		]
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   617
	    ].
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   618
	].
110
claus
parents: 106
diff changeset
   619
    ].
claus
parents: 106
diff changeset
   620
claus
parents: 106
diff changeset
   621
    (classesToRemove isEmpty
claus
parents: 106
diff changeset
   622
    and:[methodsToRemove isEmpty]) ifTrue:[
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   623
	self warn:(resources string:'No classes or methods found in %1' with:theProject).
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   624
	^ self
110
claus
parents: 106
diff changeset
   625
    ].
claus
parents: 106
diff changeset
   626
278
9d33deca396c better message (nationalized)
Claus Gittinger <cg@exept.de>
parents: 272
diff changeset
   627
    (self confirm:(resources
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   628
			string:'About to remove %1 classes and %2 additional methods.\\Are you certain you want this ?'
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   629
			with:classesToRemove size
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   630
			with:methodsToRemove size) withCRs)
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   631
	ifTrue:[
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   632
	    classesToRemove do:[:aClass |
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   633
		('PROJECT: removing ' , aClass name) infoPrintNL.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   634
		Smalltalk removeClass:aClass.   
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   635
	    ].
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   636
	    methodsToRemove do:[:aMethod |
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   637
		|where|
110
claus
parents: 106
diff changeset
   638
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   639
		('PROJECT: removing ' , aMethod displayString) infoPrintNL.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   640
		where := aMethod who.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   641
		where isNil ifTrue:[
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   642
		    'PROJECT: oops, some method is gone' infoPrintNL.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   643
		] ifFalse:[
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   644
		    (where at:1) removeSelector:(where at:2)
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   645
		]
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   646
	    ]
110
claus
parents: 106
diff changeset
   647
    ].
57
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   648
!
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   649
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   650
renameProject
955
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   651
    "give that project another name - has no semantic meaning,
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   652
     and does not affect any class/method"
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   653
57
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   654
    |box|
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   655
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   656
    box := EnterBox new.
278
9d33deca396c better message (nationalized)
Claus Gittinger <cg@exept.de>
parents: 272
diff changeset
   657
    box title:(resources string:'new name of project:').
9d33deca396c better message (nationalized)
Claus Gittinger <cg@exept.de>
parents: 272
diff changeset
   658
    box okText:(resources string:'rename').
57
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   659
    box initialText:(myProject name).
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   660
    box action:[:newName |
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   661
	myProject name:newName.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   662
	self setProject:myProject.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   663
	self windowGroup process name:'Project: ' , newName.
57
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   664
    ].
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   665
    box showAtPointer
278
9d33deca396c better message (nationalized)
Claus Gittinger <cg@exept.de>
parents: 272
diff changeset
   666
955
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   667
    "Modified: 14.2.1997 / 13:41:15 / cg"
57
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   668
!
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   669
217
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   670
saveProjectFiles
955
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   671
    "create the projects files.
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   672
     This is not yet finished."
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   673
57
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   674
    self topView withWaitCursorDo:[
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   675
	|dir|
57
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   676
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   677
	dir := myProject directory.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   678
	(self confirm:'create source files in: ' ,  dir , ' ?') ifTrue:[
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   679
	    myProject createProjectFiles.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   680
	]
57
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   681
    ].
955
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   682
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   683
    "Modified: 14.2.1997 / 13:40:40 / cg"
57
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   684
!
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   685
513
4c5b95c8c520 per project class docu added
Claus Gittinger <cg@exept.de>
parents: 468
diff changeset
   686
showClassDocumentation
4c5b95c8c520 per project class docu added
Claus Gittinger <cg@exept.de>
parents: 468
diff changeset
   687
    "open a documentViewer on the projects classes documentation only"
4c5b95c8c520 per project class docu added
Claus Gittinger <cg@exept.de>
parents: 468
diff changeset
   688
4c5b95c8c520 per project class docu added
Claus Gittinger <cg@exept.de>
parents: 468
diff changeset
   689
    self topView withWaitCursorDo:[
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   690
	|classes packageName methods methodList anyClasses anyMethods 
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   691
	 html|
513
4c5b95c8c520 per project class docu added
Claus Gittinger <cg@exept.de>
parents: 468
diff changeset
   692
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   693
	anyMethods := anyClasses := false.
513
4c5b95c8c520 per project class docu added
Claus Gittinger <cg@exept.de>
parents: 468
diff changeset
   694
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   695
	packageName := myProject packageName.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   696
	classes := myProject classes.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   697
	(classes notNil and:[classes notEmpty]) ifTrue:[
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   698
	    anyClasses := true.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   699
	].
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   700
	(anyClasses or:[anyMethods]) ifFalse:[
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   701
	    self information:(resources string:'no classes or methods in this project (yet)').
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   702
	    ^ self.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   703
	].
513
4c5b95c8c520 per project class docu added
Claus Gittinger <cg@exept.de>
parents: 468
diff changeset
   704
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   705
	methods := myProject individualMethods.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   706
	methods notEmpty ifTrue:[
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   707
	    anyMethods := true.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   708
	    "/ not yet shown ...
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   709
	].
513
4c5b95c8c520 per project class docu added
Claus Gittinger <cg@exept.de>
parents: 468
diff changeset
   710
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   711
	anyClasses ifFalse:[ ^ self].
513
4c5b95c8c520 per project class docu added
Claus Gittinger <cg@exept.de>
parents: 468
diff changeset
   712
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   713
	html := HTMLDocGenerator 
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   714
			htmlClasses:classes 
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   715
			title:'project classes' 
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   716
			backTo:#none.
513
4c5b95c8c520 per project class docu added
Claus Gittinger <cg@exept.de>
parents: 468
diff changeset
   717
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   718
	HTMLDocumentView openFullOnText:html
513
4c5b95c8c520 per project class docu added
Claus Gittinger <cg@exept.de>
parents: 468
diff changeset
   719
    ]
4c5b95c8c520 per project class docu added
Claus Gittinger <cg@exept.de>
parents: 468
diff changeset
   720
4c5b95c8c520 per project class docu added
Claus Gittinger <cg@exept.de>
parents: 468
diff changeset
   721
    "Created: 11.4.1996 / 19:29:50 / cg"
515
3f2035620126 per project class docu added
Claus Gittinger <cg@exept.de>
parents: 513
diff changeset
   722
    "Modified: 26.4.1996 / 17:48:33 / cg"
513
4c5b95c8c520 per project class docu added
Claus Gittinger <cg@exept.de>
parents: 468
diff changeset
   723
!
4c5b95c8c520 per project class docu added
Claus Gittinger <cg@exept.de>
parents: 468
diff changeset
   724
217
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   725
showProject
955
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   726
    "show all views belonging to that project and hide
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   727
     the active projects views (except for those opened before)"
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   728
217
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   729
    ActiveProjectView notNil ifTrue:[
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   730
	ActiveProjectView hideProject
57
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   731
    ].
217
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   732
    ActiveProjectView := self.
110
claus
parents: 106
diff changeset
   733
217
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   734
    myProject showViews.
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   735
    Project current:myProject.
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   736
    toggle turnOn
955
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   737
31a5221235f1 commentary;
Claus Gittinger <cg@exept.de>
parents: 904
diff changeset
   738
    "Modified: 14.2.1997 / 13:40:10 / cg"
57
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   739
! !
36e13831b62d *** empty log message ***
claus
parents: 52
diff changeset
   740
0
571fd5eee315 Initial revision
claus
parents:
diff changeset
   741
!ProjectView methodsFor:'private accessing'!
571fd5eee315 Initial revision
claus
parents:
diff changeset
   742
571fd5eee315 Initial revision
claus
parents:
diff changeset
   743
setProject:aProject
571fd5eee315 Initial revision
claus
parents:
diff changeset
   744
    |name e|
571fd5eee315 Initial revision
claus
parents:
diff changeset
   745
571fd5eee315 Initial revision
claus
parents:
diff changeset
   746
    name := aProject name.
571fd5eee315 Initial revision
claus
parents:
diff changeset
   747
    self label:name.
17
58c360f199be *** empty log message ***
claus
parents: 9
diff changeset
   748
    self iconLabel:name.
0
571fd5eee315 Initial revision
claus
parents:
diff changeset
   749
    toggle label:'Project: ' , name.
571fd5eee315 Initial revision
claus
parents:
diff changeset
   750
    toggle resize.
571fd5eee315 Initial revision
claus
parents:
diff changeset
   751
    myProject := aProject.
571fd5eee315 Initial revision
claus
parents:
diff changeset
   752
    e := (toggle width @ toggle height).
29
8a72e10043f6 *** empty log message ***
claus
parents: 17
diff changeset
   753
    drawableId isNil ifTrue:[
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   754
	self minExtent:e.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   755
	self maxExtent:e.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   756
	self open
29
8a72e10043f6 *** empty log message ***
claus
parents: 17
diff changeset
   757
    ] ifFalse:[
1348
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   758
	self unmap.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   759
	self minExtent:e.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   760
	self maxExtent:e.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   761
	self extent:e.
f958dbefe269 *** empty log message ***
Claus Gittinger <cg@exept.de>
parents: 1326
diff changeset
   762
	self remap
29
8a72e10043f6 *** empty log message ***
claus
parents: 17
diff changeset
   763
    ]
0
571fd5eee315 Initial revision
claus
parents:
diff changeset
   764
! !
217
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   765
796
b8edcbceaa18 XtHTML is no longer there ...
Claus Gittinger <cg@exept.de>
parents: 692
diff changeset
   766
!ProjectView class methodsFor:'documentation'!
217
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   767
a4b6b0d44c3b repository added
Claus Gittinger <cg@exept.de>
parents: 175
diff changeset
   768
version
2118
15936084e52b category change
Claus Gittinger <cg@exept.de>
parents: 2109
diff changeset
   769
    ^ '$Header: /cvs/stx/stx/libtool/ProjectView.st,v 1.46 1999-04-23 12:47:08 cg Exp $'
515
3f2035620126 per project class docu added
Claus Gittinger <cg@exept.de>
parents: 513
diff changeset
   770
! !