forked from pharo-vcs/iceberg
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Simplify Edit project dialog: - add root directory - handle deselection (and select root)
- Loading branch information
Showing
9 changed files
with
26 additions
and
39 deletions.
There are no files selected for viewing
2 changes: 1 addition & 1 deletion
2
Iceberg-TipUI.package/IceTipDirectoryDataSource.class/instance/directory..st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
accessing | ||
directory: aDirectory | ||
|
||
rootItem := (self class rootItemFor: (self childrenToShowFrom: aDirectory)) | ||
rootItem := (self class rootItemFor: { aDirectory }) | ||
dataSource: self; | ||
yourself. | ||
self rootItem: rootItem |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
Iceberg-TipUI.package/IceTipEditProjectDialog.class/instance/newDirectoryDataSource.st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
initialization | ||
newDirectoryDataSource | ||
|
||
^ IceTipDirectoryDataSource new | ||
directory: self model fileSystem; | ||
yourself |
16 changes: 10 additions & 6 deletions
16
...-TipUI.package/IceTipEditProjectDialog.class/instance/sourceDirectorySelectionChanged..st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,18 @@ | ||
initialization | ||
sourceDirectorySelectionChanged: selectedIndexes | ||
|
||
| selectedDirectory | | ||
| selectedDirectory selection | | ||
selectedIndexes | ||
ifEmpty: [ | ||
"If the user does not select any directory, we choose the root and we use the default format" | ||
selectedDirectoryPath := RelativePath new. | ||
formatList setSelectedItem: defaultFormat ] | ||
ifNotEmpty: [ | selection | | ||
self sourceDirectoryTree widget selectRowIndex: 1. | ||
selection := self sourceDirectoryTree widget dataSource rootItem children first. | ||
selectedDirectory := self sourceDirectoryTree widget dataSource rootItem children first data. | ||
] ifNotEmpty: [ | ||
selection := self sourceDirectoryTree widget dataSource elementAt: selectedIndexes first. | ||
selectedDirectory := selection data. | ||
selectedDirectoryPath := selectedDirectory relativeTo: self model fileSystem. | ||
formatList setSelectedItem: (self guessFormatFromDirectory: selectedDirectory) ]. | ||
]. | ||
|
||
selectedDirectory := selection data. | ||
selectedDirectoryPath := selectedDirectory relativeTo: self model fileSystem. | ||
formatList setSelectedItem: (self guessFormatFromDirectory: selectedDirectory). |
3 changes: 0 additions & 3 deletions
3
Iceberg-TipUI.package/IceTipEditProjectDialog.class/instance/useSourceFolder.st
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters