1736 last fileBox directory (default: current directory) (if a nil path is given). |
1736 last fileBox directory (default: current directory) (if a nil path is given). |
1737 The box will show okText in its okButton, abortText in the abortButton. |
1737 The box will show okText in its okButton, abortText in the abortButton. |
1738 The matchPattern is set to pattern initially. |
1738 The matchPattern is set to pattern initially. |
1739 Return the string, or nil if cancel was pressed." |
1739 Return the string, or nil if cancel was pressed." |
1740 |
1740 |
|
1741 ^ self |
|
1742 requestFileName:titleString |
|
1743 default:defaultName |
|
1744 ok:okText |
|
1745 abort:abortText |
|
1746 pattern:pattern |
|
1747 fromDirectory:aDirectoryPathOrNil |
|
1748 whenBoxCreatedEvaluate:nil |
|
1749 ! |
|
1750 |
|
1751 requestFileName:titleString default:defaultName ok:okText abort:abortText pattern:pattern fromDirectory:aDirectoryPathOrNil whenBoxCreatedEvaluate:boxCreatedCallback |
|
1752 "launch a Dialog, which allows user to enter a filename. |
|
1753 The files presented initially are those in aDirectoryPathOrNil, or the |
|
1754 last fileBox directory (default: current directory) (if a nil path is given). |
|
1755 The box will show okText in its okButton, abortText in the abortButton. |
|
1756 The matchPattern is set to pattern initially. |
|
1757 Return the string, or nil if cancel was pressed." |
|
1758 |
1741 |box defaultDir defaultNm dir enteredName| |
1759 |box defaultDir defaultNm dir enteredName| |
1742 |
1760 |
1743 defaultNm := defaultName. |
1761 defaultNm := defaultName. |
1744 defaultDir := aDirectoryPathOrNil. |
1762 defaultDir := aDirectoryPathOrNil. |
1745 defaultDir isNil ifTrue:[ |
1763 defaultDir isNil ifTrue:[ |
1948 "Modified: 20.2.1997 / 18:12:28 / cg" |
1967 "Modified: 20.2.1997 / 18:12:28 / cg" |
1949 "Modified: 21.2.1997 / 14:27:27 / stefan" |
1968 "Modified: 21.2.1997 / 14:27:27 / stefan" |
1950 ! |
1969 ! |
1951 |
1970 |
1952 requestFileName:titleString default:defaultName version:versionSymbol ifFail:failBlock pattern:pattern fromDirectory:aDirectoryPath |
1971 requestFileName:titleString default:defaultName version:versionSymbol ifFail:failBlock pattern:pattern fromDirectory:aDirectoryPath |
|
1972 "launch a Dialog, which allows user to enter a filename. |
|
1973 Return the string or the value of failBlock if cancel was pressed. |
|
1974 The version argument allows validation of the files existance; |
|
1975 it may be any of: |
|
1976 #mustBeNew - fail (return empty string) if the file exists |
|
1977 #new - confirm if the file exists |
|
1978 #mustBeOld - fail if the file does not exist |
|
1979 #old - confirm if the file does not exist |
|
1980 #any (other) - no validation |
|
1981 " |
|
1982 |
|
1983 ^ self |
|
1984 requestFileName:titleString |
|
1985 default:defaultName |
|
1986 version:versionSymbol |
|
1987 ifFail:failBlock |
|
1988 pattern:pattern |
|
1989 fromDirectory:aDirectoryPath |
|
1990 whenBoxCreatedEvaluate:nil |
|
1991 ! |
|
1992 |
|
1993 requestFileName:titleString default:defaultName version:versionSymbol ifFail:failBlock pattern:pattern fromDirectory:aDirectoryPath whenBoxCreatedEvaluate:boxCreatedCallback |
1953 "launch a Dialog, which allows user to enter a filename. |
1994 "launch a Dialog, which allows user to enter a filename. |
1954 Return the string or the value of failBlock if cancel was pressed. |
1995 Return the string or the value of failBlock if cancel was pressed. |
1955 The version argument allows validation of the files existance; |
1996 The version argument allows validation of the files existance; |
1956 it may be any of: |
1997 it may be any of: |
1957 #mustBeNew - fail (return empty string) if the file exists |
1998 #mustBeNew - fail (return empty string) if the file exists |