#UI_ENHANCEMENT by cg
authorClaus Gittinger <cg@exept.de>
Wed, 22 Mar 2017 21:48:15 +0100
changeset 17479 a1e713bd1b44
parent 17478 f02e9da087b3
child 17480 d11cc4c467c5
#UI_ENHANCEMENT by cg class: FileDialogWithPreview class changed: #windowSpec
FileDialogWithPreview.st
--- a/FileDialogWithPreview.st	Sun Mar 19 01:16:57 2017 +0100
+++ b/FileDialogWithPreview.st	Wed Mar 22 21:48:15 2017 +0100
@@ -11,6 +11,8 @@
 "
 "{ Package: 'stx:libtool' }"
 
+"{ NameSpace: Smalltalk }"
+
 FileDialog subclass:#FileDialogWithPreview
 	instanceVariableNames:'imagePreview'
 	classVariableNames:''
@@ -58,226 +60,226 @@
     <resource: #canvas>
 
     ^ 
-     #(FullSpec
-        name: windowSpec
-        window: 
-       (WindowSpec
-          label: 'FileDialog'
-          name: 'FileDialog'
-          min: (Point 10 10)
-          bounds: (Rectangle 0 0 407 607)
-          menu: mainMenu
-          performer: treeBrowser
-        )
-        component: 
-       (SpecCollection
-          collection: (
-           (VariableVerticalPanelSpec
-              name: 'FilePanel'
-              layout: (LayoutFrame 0 0.0 0 0.0 0 1.0 -30 1.0)
-              showHandle: true
-              handlePosition: center
-              component: 
-             (SpecCollection
-                collection: (
-                 (ViewSpec
-                    name: 'FilePart'
-                    component: 
-                   (SpecCollection
-                      collection: (
-                       (MenuPanelSpec
-                          name: 'ToolBar1'
-                          layout: (LayoutFrame 0 0.0 0 0.0 0 1.0 40 0)
-                          tabable: true
-                          menu: toolBarMenu
-                          textDefault: true
-                        )
-                       (VariableHorizontalPanelSpec
-                          name: 'DeviceAndFilterPanel'
-                          layout: (LayoutFrame 0 0 40 0 0 1 70 0)
-                          level: 1
-                          showHandle: true
-                          component: 
-                         (SpecCollection
-                            collection: (
-                             (ViewSpec
-                                name: 'Box1'
-                                component: 
-                               (SpecCollection
-                                  collection: (
-                                   (ComboListSpec
-                                      name: 'ComboList1'
-                                      layout: (LayoutFrame 1 0 1 0.0 -1 1 -1 1)
-                                      visibilityChannel: driveSelectorVisible
-                                      model: selectedDeviceDrive
-                                      comboList: listOfDeviceDrives
-                                      useIndex: false
-                                      hidePullDownMenuButton: false
-                                    )
+    #(FullSpec
+       name: windowSpec
+       window: 
+      (WindowSpec
+         label: 'FileDialog'
+         name: 'FileDialog'
+         min: (Point 10 10)
+         bounds: (Rectangle 0 0 407 607)
+         menu: mainMenu
+         performer: treeBrowser
+       )
+       component: 
+      (SpecCollection
+         collection: (
+          (VariableVerticalPanelSpec
+             name: 'FilePanel'
+             layout: (LayoutFrame 0 0.0 0 0.0 0 1.0 -30 1.0)
+             showHandle: true
+             handlePosition: center
+             component: 
+            (SpecCollection
+               collection: (
+                (ViewSpec
+                   name: 'FilePart'
+                   component: 
+                  (SpecCollection
+                     collection: (
+                      (MenuPanelSpec
+                         name: 'ToolBar1'
+                         layout: (LayoutFrame 0 0.0 0 0.0 0 1.0 40 0)
+                         tabable: true
+                         menu: toolBarMenu
+                         textDefault: true
+                       )
+                      (VariableHorizontalPanelSpec
+                         name: 'DeviceAndFilterPanel'
+                         layout: (LayoutFrame 0 0 40 0 0 1 70 0)
+                         level: 1
+                         showHandle: true
+                         component: 
+                        (SpecCollection
+                           collection: (
+                            (ViewSpec
+                               name: 'Box1'
+                               component: 
+                              (SpecCollection
+                                 collection: (
+                                  (ComboListSpec
+                                     name: 'ComboList1'
+                                     layout: (LayoutFrame 1 0 1 0.0 -1 1 -1 1)
+                                     visibilityChannel: driveSelectorVisible
+                                     model: selectedDeviceDrive
+                                     comboList: listOfDeviceDrives
+                                     useIndex: false
+                                     hidePullDownMenuButton: false
                                    )
-                                 
-                                )
-                              )
-                             (ViewSpec
-                                name: 'Box2'
-                                component: 
-                               (SpecCollection
-                                  collection: (
-                                   (LabelSpec
-                                      label: 'Filter:'
-                                      name: 'FilterLabel'
-                                      layout: (LayoutFrame 1 0 2 0 59 0 -2 1)
-                                      translateLabel: true
-                                      adjust: right
-                                    )
-                                   (InputFieldSpec
-                                      name: 'FilterEntryField'
-                                      layout: (LayoutFrame 60 0 -27 1 -2 1 -2 1)
-                                      model: filterHolder
-                                      immediateAccept: true
-                                      acceptOnReturn: true
-                                      acceptOnTab: true
-                                      acceptOnLostFocus: true
-                                      acceptOnPointerLeave: false
-                                      postBuildCallback: postBuildFilterField:
-                                    )
+                                  )
+                                
+                               )
+                             )
+                            (ViewSpec
+                               name: 'Box2'
+                               component: 
+                              (SpecCollection
+                                 collection: (
+                                  (LabelSpec
+                                     label: 'Filter:'
+                                     name: 'FilterLabel'
+                                     layout: (LayoutFrame 1 0 2 0 59 0 -2 1)
+                                     translateLabel: true
+                                     adjust: right
                                    )
-                                 
-                                )
-                              )
+                                  (InputFieldSpec
+                                     name: 'FilterEntryField'
+                                     layout: (LayoutFrame 60 0 -27 1 -2 1 -2 1)
+                                     model: filterHolder
+                                     immediateAccept: true
+                                     acceptOnReturn: true
+                                     acceptOnTab: true
+                                     acceptOnLostFocus: true
+                                     acceptOnPointerLeave: false
+                                     postBuildCallback: postBuildFilterField:
+                                   )
+                                  )
+                                
+                               )
                              )
-                           
-                          )
-                          handles: (Any 0.2972972972973 1.0)
-                        )
-                       (SubCanvasSpec
-                          name: 'DirectoryTreeBrowser'
-                          layout: (LayoutFrame 0 0.0 70 0 0 1.0 -30 1)
-                          tabable: true
-                          hasHorizontalScrollBar: false
-                          hasVerticalScrollBar: false
-                          majorKey: DirectoryTreeBrowser
-                          subAspectHolders: 
-                         (Array
-                            
-                           (SubChannelInfoSpec
-                              subAspect: filterModel
-                              aspect: filterHolder
-                            ) 
-                           (SubChannelInfoSpec
-                              subAspect: rootHolder
-                              aspect: rootDirectoryHolder
                             )
-                            
-                           (SubChannelInfoSpec
-                              subAspect: showHiddenFiles
-                              aspect: showHiddenFiles
-                            )
-                          )
-                          createNewApplication: true
-                          createNewBuilder: true
-                          postBuildCallback: postBuildTreeBrowser:
-                        )
-                       (LabelSpec
-                          label: 'Filename:'
-                          name: 'FilenameLabel'
-                          layout: (LayoutFrame 3 0 -25 1 90 0 -1 1)
-                          translateLabel: true
-                          labelChannel: filenameLabelHolder
-                          adjust: left
-                        )
-                       (FilenameInputFieldSpec
-                          name: 'FilenameEntryField'
-                          layout: (LayoutFrame 90 0 -25 1 -4 1 -1 1)
-                          tabable: true
-                          model: filenameHolder
-                          immediateAccept: false
-                          acceptOnPointerLeave: false
-                          hasKeyboardFocusInitially: true
-                          postBuildCallback: postBuildFileNameField:
-                        )
+                          
+                         )
+                         handles: (Any 0.29999999999999999 1.0)
                        )
-                     
-                    )
-                  )
-                 (ViewSpec
-                    name: 'PreviewBox'
-                    visibilityChannel: previewVisibleHolder
-                    component: 
-                   (SpecCollection
-                      collection: (
-                       (ArbitraryComponentSpec
-                          name: 'ArbitraryComponent1'
-                          layout: (LayoutFrame 0 0 0 0 0 1 0 1)
-                          visibilityChannel: imageViewVisible
-                          hasHorizontalScrollBar: true
-                          hasVerticalScrollBar: true
-                          miniScrollerHorizontal: true
-                          miniScrollerVertical: true
-                          hasBorder: false
-                          component: ImageView
-                          postBuildCallback: postBuildImageView:
-                        )
+                      (SubCanvasSpec
+                         name: 'DirectoryTreeBrowser'
+                         layout: (LayoutFrame 0 0.0 70 0 0 1.0 -30 1)
+                         tabable: true
+                         hasHorizontalScrollBar: false
+                         hasVerticalScrollBar: false
+                         majorKey: DirectoryTreeBrowser
+                         subAspectHolders: 
+                        (Array
+                           
+                          (SubChannelInfoSpec
+                             subAspect: filterModel
+                             aspect: filterHolder
+                           ) 
+                          (SubChannelInfoSpec
+                             subAspect: rootHolder
+                             aspect: rootDirectoryHolder
+                           )
+                           
+                          (SubChannelInfoSpec
+                             subAspect: showHiddenFiles
+                             aspect: showHiddenFiles
+                           )
+                         )
+                         createNewApplication: true
+                         createNewBuilder: true
+                         postBuildCallback: postBuildTreeBrowser:
                        )
-                     
-                    )
-                  )
+                      (LabelSpec
+                         label: 'Filename:'
+                         name: 'FilenameLabel'
+                         layout: (LayoutFrame 3 0 -25 1 120 0 -1 1)
+                         translateLabel: true
+                         labelChannel: filenameLabelHolder
+                         adjust: left
+                       )
+                      (FilenameInputFieldSpec
+                         name: 'FilenameEntryField'
+                         layout: (LayoutFrame 120 0 -25 1 -4 1 -1 1)
+                         tabable: true
+                         model: filenameHolder
+                         immediateAccept: false
+                         acceptOnPointerLeave: false
+                         hasKeyboardFocusInitially: true
+                         postBuildCallback: postBuildFileNameField:
+                       )
+                      )
+                    
+                   )
                  )
-               
-              )
-              handles: (Any 0.750433275563258 1.0)
-              postBuildCallback: postBuildVerticalPanelView:
-            )
-           (HorizontalPanelViewSpec
-              name: 'ButtonPanel'
-              layout: (LayoutFrame 0 0.0 -30 1 0 1 0 1)
-              visibilityChannel: buttonPanelVisibleHolder
-              horizontalLayout: fitSpace
-              verticalLayout: center
-              horizontalSpace: 3
-              verticalSpace: 3
-              reverseOrderIfOKAtLeft: true
-              component: 
-             (SpecCollection
-                collection: (
-                 (ActionButtonSpec
-                    label: 'Cancel'
-                    name: 'cancelButton'
-                    translateLabel: true
-                    labelChannel: cancelLabelHolder
-                    tabable: true
-                    model: doCancel
-                    extent: (Point 131 25)
-                  )
-                 (ActionButtonSpec
-                    label: 'Append'
-                    name: 'appendButton'
-                    visibilityChannel: appendButtonVisibleHolder
-                    translateLabel: true
-                    labelChannel: appendLabelHolder
-                    tabable: true
-                    model: appendPressed
-                    extent: (Point 132 25)
-                  )
-                 (ActionButtonSpec
-                    label: 'OK'
-                    name: 'okButton'
-                    translateLabel: true
-                    labelChannel: okLabelHolder
-                    tabable: true
-                    model: okPressed
-                    isDefault: true
-                    extent: (Point 132 25)
-                  )
+                (ViewSpec
+                   name: 'PreviewBox'
+                   visibilityChannel: previewVisibleHolder
+                   component: 
+                  (SpecCollection
+                     collection: (
+                      (ArbitraryComponentSpec
+                         name: 'ArbitraryComponent1'
+                         layout: (LayoutFrame 0 0 0 0 0 1 0 1)
+                         visibilityChannel: imageViewVisible
+                         hasHorizontalScrollBar: true
+                         hasVerticalScrollBar: true
+                         miniScrollerHorizontal: true
+                         miniScrollerVertical: true
+                         hasBorder: false
+                         component: ImageView
+                         postBuildCallback: postBuildImageView:
+                       )
+                      )
+                    
+                   )
                  )
-               
-              )
-              keepSpaceForOSXResizeHandleH: true
-            )
+                )
+              
+             )
+             handles: (Any 0.75 1.0)
+             postBuildCallback: postBuildVerticalPanelView:
            )
-         
-        )
-      )
+          (HorizontalPanelViewSpec
+             name: 'ButtonPanel'
+             layout: (LayoutFrame 0 0.0 -30 1 -16 1 0 1)
+             visibilityChannel: buttonPanelVisibleHolder
+             horizontalLayout: fitSpace
+             verticalLayout: center
+             horizontalSpace: 3
+             verticalSpace: 3
+             reverseOrderIfOKAtLeft: true
+             component: 
+            (SpecCollection
+               collection: (
+                (ActionButtonSpec
+                   label: 'Cancel'
+                   name: 'cancelButton'
+                   translateLabel: true
+                   labelChannel: cancelLabelHolder
+                   tabable: true
+                   model: doCancel
+                   extent: (Point 125 25)
+                 )
+                (ActionButtonSpec
+                   label: 'Append'
+                   name: 'appendButton'
+                   visibilityChannel: appendButtonVisibleHolder
+                   translateLabel: true
+                   labelChannel: appendLabelHolder
+                   tabable: true
+                   model: appendPressed
+                   extent: (Point 125 25)
+                 )
+                (ActionButtonSpec
+                   label: 'OK'
+                   name: 'okButton'
+                   translateLabel: true
+                   labelChannel: okLabelHolder
+                   tabable: true
+                   model: okPressed
+                   isDefault: true
+                   extent: (Point 125 25)
+                 )
+                )
+              
+             )
+             keepSpaceForOSXResizeHandleH: true
+           )
+          )
+        
+       )
+     )
 ! !
 
 !FileDialogWithPreview class methodsFor:'plugIn spec'!
@@ -330,10 +332,10 @@
 !FileDialogWithPreview class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libtool/FileDialogWithPreview.st,v 1.6 2013-12-07 10:46:29 cg Exp $'
+    ^ '$Header$'
 !
 
 version_CVS
-    ^ '$Header: /cvs/stx/stx/libtool/FileDialogWithPreview.st,v 1.6 2013-12-07 10:46:29 cg Exp $'
+    ^ '$Header$'
 ! !