FileApplicationNoteBook.st
branchjv
changeset 13170 c9b815af5777
parent 12517 3a904476a8d2
parent 12830 7c993d3f4519
child 13180 64a4186ddfce
equal deleted inserted replaced
12819:0ce340e972c4 13170:c9b815af5777
   122 "
   122 "
   123     [Author:]
   123     [Author:]
   124         Christian Penk
   124         Christian Penk
   125 "
   125 "
   126 ! !
   126 ! !
   127 
       
   128 
   127 
   129 !FileApplicationNoteBook class methodsFor:'application list'!
   128 !FileApplicationNoteBook class methodsFor:'application list'!
   130 
   129 
   131 applicationList
   130 applicationList
   132     " returns a list of all applications to start by the NoteBookApplication with 
   131     " returns a list of all applications to start by the NoteBookApplication with 
   176 typeFor:aApplicationListItem
   175 typeFor:aApplicationListItem
   177 
   176 
   178     ^ aApplicationListItem at:2
   177     ^ aApplicationListItem at:2
   179 ! !
   178 ! !
   180 
   179 
   181 
       
   182 !FileApplicationNoteBook class methodsFor:'classAccess'!
   180 !FileApplicationNoteBook class methodsFor:'classAccess'!
   183 
   181 
   184 textEditorClass
   182 textEditorClass
   185 
   183 
   186     ^ TextEditor
   184     ^ TextEditor
   187 ! !
   185 ! !
   188 
   186 
   189 
       
   190 !FileApplicationNoteBook class methodsFor:'defaults'!
   187 !FileApplicationNoteBook class methodsFor:'defaults'!
   191 
   188 
   192 openAnotherApplicationOnSameItem
   189 openAnotherApplicationOnSameItem
   193 
   190 
   194     ^ false
   191     ^ false
   195 ! !
   192 ! !
   196 
       
   197 
   193 
   198 !FileApplicationNoteBook class methodsFor:'interface specs'!
   194 !FileApplicationNoteBook class methodsFor:'interface specs'!
   199 
   195 
   200 windowSpec
   196 windowSpec
   201     "This resource specification was automatically generated
   197     "This resource specification was automatically generated
   239            )
   235            )
   240          
   236          
   241         )
   237         )
   242       )
   238       )
   243 ! !
   239 ! !
   244 
       
   245 
   240 
   246 !FileApplicationNoteBook class methodsFor:'menu specs'!
   241 !FileApplicationNoteBook class methodsFor:'menu specs'!
   247 
   242 
   248 tabMenu
   243 tabMenu
   249     "This resource specification was automatically generated
   244     "This resource specification was automatically generated
   309       )
   304       )
   310 
   305 
   311     "Modified: / 27-03-2007 / 11:13:52 / cg"
   306     "Modified: / 27-03-2007 / 11:13:52 / cg"
   312 ! !
   307 ! !
   313 
   308 
   314 
       
   315 !FileApplicationNoteBook methodsFor:'accessing'!
   309 !FileApplicationNoteBook methodsFor:'accessing'!
   316 
   310 
   317 listOfApplications
   311 listOfApplications
   318     "return the value of the instance variable 'listOfApplications' (automatically generated)"
   312     "return the value of the instance variable 'listOfApplications' (automatically generated)"
   319 
   313 
   333 
   327 
   334 selectionHistoryList:aCol
   328 selectionHistoryList:aCol
   335 
   329 
   336     selectionHistoryList := aCol 
   330     selectionHistoryList := aCol 
   337 ! !
   331 ! !
   338 
       
   339 
   332 
   340 !FileApplicationNoteBook methodsFor:'accessing-applications'!
   333 !FileApplicationNoteBook methodsFor:'accessing-applications'!
   341 
   334 
   342 getAllApplicationsByClass:aClass andType:aType
   335 getAllApplicationsByClass:aClass andType:aType
   343     ^ self listOfApplications 
   336     ^ self listOfApplications 
   375             and:[ (appl isKindOf:(anApplication class)) 
   368             and:[ (appl isKindOf:(anApplication class)) 
   376             and:[ (appl item = (anApplication item)) 
   369             and:[ (appl item = (anApplication item)) 
   377             and:[ (appl type == anApplication type) ]]])
   370             and:[ (appl type == anApplication type) ]]])
   378         ].
   371         ].
   379 ! !
   372 ! !
   380 
       
   381 
   373 
   382 !FileApplicationNoteBook methodsFor:'actions-app-common'!
   374 !FileApplicationNoteBook methodsFor:'actions-app-common'!
   383 
   375 
   384 changeItem:anItem for:anAppl
   376 changeItem:anItem for:anAppl
   385     | applIndex string isDirectory |
   377     | applIndex string isDirectory |
   722                 "/ if item already changed select the application
   714                 "/ if item already changed select the application
   723                 selAppl := sameAppls detect:[:appl | (appl item = anItem) ] ifNone:[nil].
   715                 selAppl := sameAppls detect:[:appl | (appl item = anItem) ] ifNone:[nil].
   724             ].
   716             ].
   725         ] ifFalse:[
   717         ] ifFalse:[
   726             "/ keep in same application change the first application of the same class and type - if item not changed otherwise open new
   718             "/ keep in same application change the first application of the same class and type - if item not changed otherwise open new
   727             sameAppls := sameAppls select:[:appl | appl isModified not ].
   719             sameAppls := sameAppls reject:[:appl | appl isModified ].
   728         ].
   720         ].
   729     ].
   721     ].
   730     sameAppls size ~~ 0 ifTrue:[
   722     sameAppls size ~~ 0 ifTrue:[
   731         " take first all applications which have nil items 
   723         " take first all applications which have nil items 
   732           second the selected 
   724           second the selected 
   751     ^ selAppl.
   743     ^ selAppl.
   752 
   744 
   753     "Modified (format): / 29-11-2011 / 19:07:57 / cg"
   745     "Modified (format): / 29-11-2011 / 19:07:57 / cg"
   754 ! !
   746 ! !
   755 
   747 
   756 
       
   757 !FileApplicationNoteBook methodsFor:'actions-app-spec'!
   748 !FileApplicationNoteBook methodsFor:'actions-app-spec'!
   758 
   749 
   759 addTerminalIn:aDirectory
   750 addTerminalIn:aDirectory
   760     |item|
   751     |item|
   761 
   752 
   890             withType:#file 
   881             withType:#file 
   891             checkExisting:true 
   882             checkExisting:true 
   892             preSetItem:[:aTextEditor | aTextEditor presentation:#hexDump].
   883             preSetItem:[:aTextEditor | aTextEditor presentation:#hexDump].
   893 ! !
   884 ! !
   894 
   885 
   895 
       
   896 !FileApplicationNoteBook methodsFor:'applicationlist access'!
   886 !FileApplicationNoteBook methodsFor:'applicationlist access'!
   897 
   887 
   898 applicationList
   888 applicationList
   899     ^ self class applicationList
   889     ^ self class applicationList
   900 ! !
   890 ! !
   901 
       
   902 
   891 
   903 !FileApplicationNoteBook methodsFor:'aspects'!
   892 !FileApplicationNoteBook methodsFor:'aspects'!
   904 
   893 
   905 canvasHolder
   894 canvasHolder
   906 
   895 
  1022 
  1011 
  1023 tabList:aValue
  1012 tabList:aValue
  1024 
  1013 
  1025     tabList := aValue.
  1014     tabList := aValue.
  1026 ! !
  1015 ! !
  1027 
       
  1028 
  1016 
  1029 !FileApplicationNoteBook methodsFor:'change & update'!
  1017 !FileApplicationNoteBook methodsFor:'change & update'!
  1030 
  1018 
  1031 canvasChanged
  1019 canvasChanged
  1032     "invoked when the contentsView has been changed"
  1020     "invoked when the contentsView has been changed"
  1111         self closeDirectoryDescription.
  1099         self closeDirectoryDescription.
  1112     ].
  1100     ].
  1113     ^ self.
  1101     ^ self.
  1114 ! !
  1102 ! !
  1115 
  1103 
  1116 
       
  1117 !FileApplicationNoteBook methodsFor:'menu & actions'!
  1104 !FileApplicationNoteBook methodsFor:'menu & actions'!
  1118 
  1105 
  1119 destroyTabAt:idx
  1106 destroyTabAt:idx
  1120     |app|
  1107     |app|
  1121 
  1108 
  1134     menu findGuiResourcesIn:self.
  1121     menu findGuiResourcesIn:self.
  1135     ^ menu
  1122     ^ menu
  1136 
  1123 
  1137     "Modified: / 27-03-2007 / 10:57:25 / cg"
  1124     "Modified: / 27-03-2007 / 10:57:25 / cg"
  1138 ! !
  1125 ! !
  1139 
       
  1140 
  1126 
  1141 !FileApplicationNoteBook methodsFor:'queries'!
  1127 !FileApplicationNoteBook methodsFor:'queries'!
  1142 
  1128 
  1143 getSameFilesModifiedFor:aAppl
  1129 getSameFilesModifiedFor:aAppl
  1144 
  1130 
  1153             ]
  1139             ]
  1154         ]
  1140         ]
  1155     ].
  1141     ].
  1156     ^ colOfChanged
  1142     ^ colOfChanged
  1157 ! !
  1143 ! !
  1158 
       
  1159 
  1144 
  1160 !FileApplicationNoteBook methodsFor:'selection'!
  1145 !FileApplicationNoteBook methodsFor:'selection'!
  1161 
  1146 
  1162 currentTabMenusApplication
  1147 currentTabMenusApplication
  1163     "only valid within menu processing"
  1148     "only valid within menu processing"
  1192     canvas := self canvasHolder value.
  1177     canvas := self canvasHolder value.
  1193     canvas isNil ifTrue:[ ^ nil].
  1178     canvas isNil ifTrue:[ ^ nil].
  1194     ^ canvas application.
  1179     ^ canvas application.
  1195 ! !
  1180 ! !
  1196 
  1181 
  1197 
       
  1198 !FileApplicationNoteBook methodsFor:'startup & release'!
  1182 !FileApplicationNoteBook methodsFor:'startup & release'!
  1199 
  1183 
  1200 closeRequest
  1184 closeRequest
  1201     "asks for permission before closing"
  1185     "asks for permission before closing"
  1202 
  1186 
  1242         ].
  1226         ].
  1243     ].
  1227     ].
  1244     ^ true
  1228     ^ true
  1245 ! !
  1229 ! !
  1246 
  1230 
  1247 
       
  1248 !FileApplicationNoteBook::ArchiveViewApplication class methodsFor:'defaults'!
  1231 !FileApplicationNoteBook::ArchiveViewApplication class methodsFor:'defaults'!
  1249 
  1232 
  1250 tabStringFor:aApplicationType
  1233 tabStringFor:aApplicationType
  1251     "the formatString shown in a tab (language translated)"
  1234     "the formatString shown in a tab (language translated)"
  1252 
  1235 
  1253     ^ 'Archive %1'
  1236     ^ 'Archive %1'
  1254 
  1237 
  1255     "Modified: / 01-03-2007 / 21:43:13 / cg"
  1238     "Modified: / 01-03-2007 / 21:43:13 / cg"
  1256 ! !
  1239 ! !
  1257 
       
  1258 
  1240 
  1259 !FileApplicationNoteBook::ArchiveViewApplication class methodsFor:'help specs'!
  1241 !FileApplicationNoteBook::ArchiveViewApplication class methodsFor:'help specs'!
  1260 
  1242 
  1261 flyByHelpSpec
  1243 flyByHelpSpec
  1262     "This resource specification was automatically generated
  1244     "This resource specification was automatically generated
  1315 #stopButton
  1297 #stopButton
  1316 'Stop'
  1298 'Stop'
  1317 
  1299 
  1318 )
  1300 )
  1319 ! !
  1301 ! !
  1320 
       
  1321 
  1302 
  1322 !FileApplicationNoteBook::ArchiveViewApplication class methodsFor:'image specs'!
  1303 !FileApplicationNoteBook::ArchiveViewApplication class methodsFor:'image specs'!
  1323 
  1304 
  1324 extract28x28Icon
  1305 extract28x28Icon
  1325     "This resource specification was automatically generated
  1306     "This resource specification was automatically generated
  1397 @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
  1378 @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
  1398 @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
  1379 @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
  1399 @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
  1380 @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
  1400 @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@a') ; colorMapFromArray:#[0 0 0 8 4 8 105 133 190 121 133 157 129 129 129 194 194 194 255 0 0]; mask:((Depth1Image new) width: 28; height: 22; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@LC@@@A!! @@@L0@@@A8@@@@L@@@@G @@@CL@@@A!! @@@0L@@@@@@@BY=5LAIUUT S5UU8D!!UUPAFU\#@@@@@@@LR9@@D)J @A:R(@@P$*@@CIN @@@@@@@@@a') ; yourself); yourself]
  1381 @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@a') ; colorMapFromArray:#[0 0 0 8 4 8 105 133 190 121 133 157 129 129 129 194 194 194 255 0 0]; mask:((Depth1Image new) width: 28; height: 22; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@LC@@@A!! @@@L0@@@A8@@@@L@@@@G @@@CL@@@A!! @@@0L@@@@@@@BY=5LAIUUT S5UU8D!!UUPAFU\#@@@@@@@LR9@@D)J @A:R(@@P$*@@CIN @@@@@@@@@a') ; yourself); yourself]
  1401 ! !
  1382 ! !
  1402 
       
  1403 
  1383 
  1404 !FileApplicationNoteBook::ArchiveViewApplication class methodsFor:'interface specs'!
  1384 !FileApplicationNoteBook::ArchiveViewApplication class methodsFor:'interface specs'!
  1405 
  1385 
  1406 windowSpec
  1386 windowSpec
  1407     "This resource specification was automatically generated
  1387     "This resource specification was automatically generated
  1496          
  1476          
  1497         )
  1477         )
  1498       )
  1478       )
  1499 ! !
  1479 ! !
  1500 
  1480 
  1501 
       
  1502 !FileApplicationNoteBook::ArchiveViewApplication class methodsFor:'menu specs'!
  1481 !FileApplicationNoteBook::ArchiveViewApplication class methodsFor:'menu specs'!
  1503 
  1482 
  1504 fileListMenu
  1483 fileListMenu
  1505     "This resource specification was automatically generated
  1484     "This resource specification was automatically generated
  1506      by the MenuEditor of ST/X."
  1485      by the MenuEditor of ST/X."
  1634       )
  1613       )
  1635 
  1614 
  1636     "Modified: / 12-01-2012 / 00:34:06 / cg"
  1615     "Modified: / 12-01-2012 / 00:34:06 / cg"
  1637 ! !
  1616 ! !
  1638 
  1617 
  1639 
       
  1640 !FileApplicationNoteBook::ArchiveViewApplication class methodsFor:'queries'!
  1618 !FileApplicationNoteBook::ArchiveViewApplication class methodsFor:'queries'!
  1641 
  1619 
  1642 canOpenItem:anItem
  1620 canOpenItem:anItem
  1643     |suffix mimeType|
  1621     |suffix mimeType|
  1644 
  1622 
  1664 
  1642 
  1665 wantNewApplicationAnyway
  1643 wantNewApplicationAnyway
  1666 
  1644 
  1667     ^ false
  1645     ^ false
  1668 ! !
  1646 ! !
  1669 
       
  1670 
  1647 
  1671 !FileApplicationNoteBook::ArchiveViewApplication class methodsFor:'tableColumns specs'!
  1648 !FileApplicationNoteBook::ArchiveViewApplication class methodsFor:'tableColumns specs'!
  1672 
  1649 
  1673 tableColumns
  1650 tableColumns
  1674     "This resource specification was automatically generated
  1651     "This resource specification was automatically generated
  1827        )
  1804        )
  1828       )
  1805       )
  1829     
  1806     
  1830 ! !
  1807 ! !
  1831 
  1808 
  1832 
       
  1833 !FileApplicationNoteBook::ArchiveViewApplication methodsFor:'accessing'!
  1809 !FileApplicationNoteBook::ArchiveViewApplication methodsFor:'accessing'!
  1834 
  1810 
  1835 archiver
  1811 archiver
  1836     "return the value of the instance variable 'archiver' (automatically generated)"
  1812     "return the value of the instance variable 'archiver' (automatically generated)"
  1837 
  1813 
  1894         temporaryDirectory makeDirectory.
  1870         temporaryDirectory makeDirectory.
  1895     ].
  1871     ].
  1896     ^ temporaryDirectory
  1872     ^ temporaryDirectory
  1897 ! !
  1873 ! !
  1898 
  1874 
  1899 
       
  1900 !FileApplicationNoteBook::ArchiveViewApplication methodsFor:'actions'!
  1875 !FileApplicationNoteBook::ArchiveViewApplication methodsFor:'actions'!
  1901 
  1876 
  1902 changeItem:anItem 
  1877 changeItem:anItem 
  1903     self item:anItem.
  1878     self item:anItem.
  1904     self clearFileList.
  1879     self clearFileList.
  2005     master notNil ifTrue:[
  1980     master notNil ifTrue:[
  2006         master openApplByFileItem:item.
  1981         master openApplByFileItem:item.
  2007     ].
  1982     ].
  2008 ! !
  1983 ! !
  2009 
  1984 
  2010 
       
  2011 !FileApplicationNoteBook::ArchiveViewApplication methodsFor:'aspects'!
  1985 !FileApplicationNoteBook::ArchiveViewApplication methodsFor:'aspects'!
  2012 
  1986 
  2013 archiveFileList
  1987 archiveFileList
  2014 
  1988 
  2015     archiveFileList isNil ifTrue:[
  1989     archiveFileList isNil ifTrue:[
  2083         viewErrorList onChangeSend:#viewErrorListChanged to:self.
  2057         viewErrorList onChangeSend:#viewErrorListChanged to:self.
  2084     ].
  2058     ].
  2085     ^ viewErrorList
  2059     ^ viewErrorList
  2086 ! !
  2060 ! !
  2087 
  2061 
  2088 
       
  2089 !FileApplicationNoteBook::ArchiveViewApplication methodsFor:'change & update'!
  2062 !FileApplicationNoteBook::ArchiveViewApplication methodsFor:'change & update'!
  2090 
  2063 
  2091 update:something with:aParameter from:changedObject
  2064 update:something with:aParameter from:changedObject
  2092     changedObject == self archiveFileList ifTrue:[
  2065     changedObject == self archiveFileList ifTrue:[
  2093         self hasListEntriesHolder value:(changedObject notEmpty).
  2066         self hasListEntriesHolder value:(changedObject notEmpty).
  2102 
  2075 
  2103     viewListValue := self viewErrorList value.
  2076     viewListValue := self viewErrorList value.
  2104     self enableRemoveErrorOutput value:viewListValue.
  2077     self enableRemoveErrorOutput value:viewListValue.
  2105     self errorListVisibilityHolder value:viewListValue.
  2078     self errorListVisibilityHolder value:viewListValue.
  2106 ! !
  2079 ! !
  2107 
       
  2108 
  2080 
  2109 !FileApplicationNoteBook::ArchiveViewApplication methodsFor:'command execution'!
  2081 !FileApplicationNoteBook::ArchiveViewApplication methodsFor:'command execution'!
  2110 
  2082 
  2111 getErrorBlock
  2083 getErrorBlock
  2112 
  2084 
  2221             ]
  2193             ]
  2222         ]
  2194         ]
  2223     ].
  2195     ].
  2224 ! !
  2196 ! !
  2225 
  2197 
  2226 
       
  2227 !FileApplicationNoteBook::ArchiveViewApplication methodsFor:'command helper'!
  2198 !FileApplicationNoteBook::ArchiveViewApplication methodsFor:'command helper'!
  2228 
  2199 
  2229 selectDirectoryDialog
  2200 selectDirectoryDialog
  2230 
  2201 
  2231     | dir directory haveDirectory|
  2202     | dir directory haveDirectory|
  2284         ].
  2255         ].
  2285     ].
  2256     ].
  2286     ^ dir
  2257     ^ dir
  2287 ! !
  2258 ! !
  2288 
  2259 
  2289 
       
  2290 !FileApplicationNoteBook::ArchiveViewApplication methodsFor:'commands add'!
  2260 !FileApplicationNoteBook::ArchiveViewApplication methodsFor:'commands add'!
  2291 
  2261 
  2292 addFilesToArchive:colOfFiles 
  2262 addFilesToArchive:colOfFiles 
  2293     self archiver 
  2263     self archiver 
  2294         outStream:nil
  2264         outStream:nil
  2310         self listFiles:colOfFiles
  2280         self listFiles:colOfFiles
  2311     ].
  2281     ].
  2312     ^ true
  2282     ^ true
  2313 ! !
  2283 ! !
  2314 
  2284 
  2315 
       
  2316 !FileApplicationNoteBook::ArchiveViewApplication methodsFor:'commands extract'!
  2285 !FileApplicationNoteBook::ArchiveViewApplication methodsFor:'commands extract'!
  2317 
  2286 
  2318 extractAll
  2287 extractAll
  2319 
  2288 
  2320     self extractSelectedFilesTo:nil withSelection:#all
  2289     self extractSelectedFilesTo:nil withSelection:#all
  2346     selectOrAll == #selection ifTrue:[
  2315     selectOrAll == #selection ifTrue:[
  2347         self extractSelectionTo:dir askForExtractOptions:askForExtractOptionsBoolean
  2316         self extractSelectionTo:dir askForExtractOptions:askForExtractOptionsBoolean
  2348     ].
  2317     ].
  2349 "/    self updateFileBrowserIfPresentWith:dir.
  2318 "/    self updateFileBrowserIfPresentWith:dir.
  2350 ! !
  2319 ! !
  2351 
       
  2352 
  2320 
  2353 !FileApplicationNoteBook::ArchiveViewApplication methodsFor:'commands extract private'!
  2321 !FileApplicationNoteBook::ArchiveViewApplication methodsFor:'commands extract private'!
  2354 
  2322 
  2355 extractAllTo:aDirectory 
  2323 extractAllTo:aDirectory 
  2356 
  2324 
  2431     ^ true.
  2399     ^ true.
  2432 
  2400 
  2433     "Modified (format): / 29-11-2011 / 18:58:01 / cg"
  2401     "Modified (format): / 29-11-2011 / 18:58:01 / cg"
  2434 ! !
  2402 ! !
  2435 
  2403 
  2436 
       
  2437 !FileApplicationNoteBook::ArchiveViewApplication methodsFor:'commands list'!
  2404 !FileApplicationNoteBook::ArchiveViewApplication methodsFor:'commands list'!
  2438 
  2405 
  2439 listAllFiles
  2406 listAllFiles
  2440     self archiveFileList value removeAll.
  2407     self archiveFileList value removeAll.
  2441     self listFiles:nil
  2408     self listFiles:nil
  2455         self 
  2422         self 
  2456             makeProcessFor:[self archiver listFiles:aColOfFilesOrNil]
  2423             makeProcessFor:[self archiver listFiles:aColOfFilesOrNil]
  2457             with:'List files'
  2424             with:'List files'
  2458     ]
  2425     ]
  2459 ! !
  2426 ! !
  2460 
       
  2461 
  2427 
  2462 !FileApplicationNoteBook::ArchiveViewApplication methodsFor:'commands remove'!
  2428 !FileApplicationNoteBook::ArchiveViewApplication methodsFor:'commands remove'!
  2463 
  2429 
  2464 removeFilesFromArchive
  2430 removeFilesFromArchive
  2465     |sel realSel list firtsPre stringCol stringRealSel|
  2431     |sel realSel list firtsPre stringCol stringRealSel|
  2486         makeProcessFor:[ self archiver removeFilesFromArchive:stringCol ]
  2452         makeProcessFor:[ self archiver removeFilesFromArchive:stringCol ]
  2487         with:'Remove files'.
  2453         with:'Remove files'.
  2488     self archiveFileList value removeAllFoundIn:realSel
  2454     self archiveFileList value removeAllFoundIn:realSel
  2489 ! !
  2455 ! !
  2490 
  2456 
  2491 
       
  2492 !FileApplicationNoteBook::ArchiveViewApplication methodsFor:'drag & drop'!
  2457 !FileApplicationNoteBook::ArchiveViewApplication methodsFor:'drag & drop'!
  2493 
  2458 
  2494 canDrop:aContext
  2459 canDrop:aContext
  2495 
  2460 
  2496     ^ inDropMode
  2461     ^ inDropMode
  2565     |sel|
  2530     |sel|
  2566 
  2531 
  2567     sel := self selectionHolder value.
  2532     sel := self selectionHolder value.
  2568     ^ sel collect:[:el| DropObject newFileInArchive:(el fileName asFilename) ].
  2533     ^ sel collect:[:el| DropObject newFileInArchive:(el fileName asFilename) ].
  2569 ! !
  2534 ! !
  2570 
       
  2571 
  2535 
  2572 !FileApplicationNoteBook::ArchiveViewApplication methodsFor:'event handling'!
  2536 !FileApplicationNoteBook::ArchiveViewApplication methodsFor:'event handling'!
  2573 
  2537 
  2574 processEvent:anEvent 
  2538 processEvent:anEvent 
  2575     "filter keyboard events.
  2539     "filter keyboard events.
  2590             ]
  2554             ]
  2591         ]
  2555         ]
  2592     ].
  2556     ].
  2593     ^ false
  2557     ^ false
  2594 ! !
  2558 ! !
  2595 
       
  2596 
  2559 
  2597 !FileApplicationNoteBook::ArchiveViewApplication methodsFor:'initialization & release'!
  2560 !FileApplicationNoteBook::ArchiveViewApplication methodsFor:'initialization & release'!
  2598 
  2561 
  2599 postBuildFileTable:aWidget
  2562 postBuildFileTable:aWidget
  2600 
  2563 
  2638 release
  2601 release
  2639     self archiver release.
  2602     self archiver release.
  2640     ^ super release.
  2603     ^ super release.
  2641 ! !
  2604 ! !
  2642 
  2605 
  2643 
       
  2644 !FileApplicationNoteBook::ArchiveViewApplication methodsFor:'queries'!
  2606 !FileApplicationNoteBook::ArchiveViewApplication methodsFor:'queries'!
  2645 
  2607 
  2646 canDelete
  2608 canDelete
  2647 
  2609 
  2648     ^ (self hasOneSelectionInList and:[archiver class canRemoveFiles])
  2610     ^ (self hasOneSelectionInList and:[archiver class canRemoveFiles])
  2685             ]
  2647             ]
  2686         ].
  2648         ].
  2687     ].
  2649     ].
  2688     ^ newSel.
  2650     ^ newSel.
  2689 ! !
  2651 ! !
  2690 
       
  2691 
  2652 
  2692 !FileApplicationNoteBook::ArchiveViewApplication methodsFor:'sorting'!
  2653 !FileApplicationNoteBook::ArchiveViewApplication methodsFor:'sorting'!
  2693 
  2654 
  2694 generateSortBlock:instanceName
  2655 generateSortBlock:instanceName
  2695 
  2656 
  2748     sortCol addAll:fileList.
  2709     sortCol addAll:fileList.
  2749     fileList removeAll.
  2710     fileList removeAll.
  2750     fileList addAll:sortCol.
  2711     fileList addAll:sortCol.
  2751 ! !
  2712 ! !
  2752 
  2713 
  2753 
       
  2754 !FileApplicationNoteBook::ArchiveViewApplication::ArchivItem methodsFor:'accessing'!
  2714 !FileApplicationNoteBook::ArchiveViewApplication::ArchivItem methodsFor:'accessing'!
  2755 
  2715 
  2756 compressSize
  2716 compressSize
  2757     "return the value of the instance variable 'compressSize' (automatically generated)"
  2717     "return the value of the instance variable 'compressSize' (automatically generated)"
  2758 
  2718 
  3001 
  2961 
  3002 yearString:yearString
  2962 yearString:yearString
  3003     self year:(Integer readFrom:yearString)
  2963     self year:(Integer readFrom:yearString)
  3004 ! !
  2964 ! !
  3005 
  2965 
  3006 
       
  3007 !FileApplicationNoteBook::ArchiveViewApplication::ArchivItem methodsFor:'printing'!
  2966 !FileApplicationNoteBook::ArchiveViewApplication::ArchivItem methodsFor:'printing'!
  3008 
  2967 
  3009 printOn:aStream
  2968 printOn:aStream
  3010     aStream nextPutAll:self fileName asString
  2969     aStream nextPutAll:self fileName asString
  3011 ! !
  2970 ! !
  3012 
  2971 
  3013 
       
  3014 !FileApplicationNoteBook::ArchiveViewApplication::ArchivItem methodsFor:'queries'!
  2972 !FileApplicationNoteBook::ArchiveViewApplication::ArchivItem methodsFor:'queries'!
  3015 
  2973 
  3016 hasDirectoryPart
  2974 hasDirectoryPart
  3017 
  2975 
  3018     ^ self fileName asFilename components size ~= 1
  2976     ^ self fileName asFilename components size ~= 1
  3019 ! !
  2977 ! !
  3020 
       
  3021 
  2978 
  3022 !FileApplicationNoteBook::CommandResult class methodsFor:'defaults'!
  2979 !FileApplicationNoteBook::CommandResult class methodsFor:'defaults'!
  3023 
  2980 
  3024 tabStringFor:aApplicationType
  2981 tabStringFor:aApplicationType
  3025     "the formatString shown in a tab (language translated)"
  2982     "the formatString shown in a tab (language translated)"
  3031 
  2988 
  3032 wantNewApplicationAnyway
  2989 wantNewApplicationAnyway
  3033 
  2990 
  3034     ^ false
  2991     ^ false
  3035 ! !
  2992 ! !
  3036 
       
  3037 
  2993 
  3038 !FileApplicationNoteBook::CommandResult class methodsFor:'interface specs'!
  2994 !FileApplicationNoteBook::CommandResult class methodsFor:'interface specs'!
  3039 
  2995 
  3040 windowSpec
  2996 windowSpec
  3041     "This resource specification was automatically generated
  2997     "This resource specification was automatically generated
  3094          
  3050          
  3095         )
  3051         )
  3096       )
  3052       )
  3097 ! !
  3053 ! !
  3098 
  3054 
  3099 
       
  3100 !FileApplicationNoteBook::CommandResult class methodsFor:'menu specs'!
  3055 !FileApplicationNoteBook::CommandResult class methodsFor:'menu specs'!
  3101 
  3056 
  3102 menu
  3057 menu
  3103     "This resource specification was automatically generated
  3058     "This resource specification was automatically generated
  3104      by the MenuEditor of ST/X."
  3059      by the MenuEditor of ST/X."
  3142       )
  3097       )
  3143 
  3098 
  3144     "Modified: / 12-01-2012 / 00:33:56 / cg"
  3099     "Modified: / 12-01-2012 / 00:33:56 / cg"
  3145 ! !
  3100 ! !
  3146 
  3101 
  3147 
       
  3148 !FileApplicationNoteBook::CommandResult methodsFor:'accessing'!
  3102 !FileApplicationNoteBook::CommandResult methodsFor:'accessing'!
  3149 
  3103 
  3150 resultStream
  3104 resultStream
  3151     "return the value of the instance variable 'resultStream' (automatically generated)"
  3105     "return the value of the instance variable 'resultStream' (automatically generated)"
  3152 
  3106 
  3156 resultStream:something
  3110 resultStream:something
  3157     "set the value of the instance variable 'resultStream' (automatically generated)"
  3111     "set the value of the instance variable 'resultStream' (automatically generated)"
  3158 
  3112 
  3159     resultStream := something.
  3113     resultStream := something.
  3160 ! !
  3114 ! !
  3161 
       
  3162 
  3115 
  3163 !FileApplicationNoteBook::CommandResult methodsFor:'actions'!
  3116 !FileApplicationNoteBook::CommandResult methodsFor:'actions'!
  3164 
  3117 
  3165 changeTabTo:aString 
  3118 changeTabTo:aString 
  3166 
  3119 
  3181         self notify:('kill ', myProcess name).
  3134         self notify:('kill ', myProcess name).
  3182         myProcess terminate.    
  3135         myProcess terminate.    
  3183     ].
  3136     ].
  3184 ! !
  3137 ! !
  3185 
  3138 
  3186 
       
  3187 !FileApplicationNoteBook::CommandResult methodsFor:'aspects'!
  3139 !FileApplicationNoteBook::CommandResult methodsFor:'aspects'!
  3188 
  3140 
  3189 enableStopButton
  3141 enableStopButton
  3190 
  3142 
  3191     enableStopButton isNil ifTrue:[
  3143     enableStopButton isNil ifTrue:[
  3201         process := ValueHolder new.
  3153         process := ValueHolder new.
  3202         process addDependent:self.
  3154         process addDependent:self.
  3203     ].
  3155     ].
  3204     ^ process
  3156     ^ process
  3205 ! !
  3157 ! !
  3206 
       
  3207 
  3158 
  3208 !FileApplicationNoteBook::CommandResult methodsFor:'change & update'!
  3159 !FileApplicationNoteBook::CommandResult methodsFor:'change & update'!
  3209 
  3160 
  3210 update:something with:aParameter from:changedObject
  3161 update:something with:aParameter from:changedObject
  3211     changedObject == self process ifTrue:[
  3162     changedObject == self process ifTrue:[
  3212         self enableStopButton value:changedObject value notNil.
  3163         self enableStopButton value:changedObject value notNil.
  3213         ^ self
  3164         ^ self
  3214     ].
  3165     ].
  3215     super update:something with:aParameter from:changedObject
  3166     super update:something with:aParameter from:changedObject
  3216 ! !
  3167 ! !
  3217 
       
  3218 
  3168 
  3219 !FileApplicationNoteBook::CommandResult methodsFor:'initialization & release'!
  3169 !FileApplicationNoteBook::CommandResult methodsFor:'initialization & release'!
  3220 
  3170 
  3221 postBuildTextCollector:aBuilder
  3171 postBuildTextCollector:aBuilder
  3222 
  3172 
  3241 
  3191 
  3242     self doStopProcess.
  3192     self doStopProcess.
  3243     ^ super release
  3193     ^ super release
  3244 ! !
  3194 ! !
  3245 
  3195 
  3246 
       
  3247 !FileApplicationNoteBook::CommandResult methodsFor:'printing'!
  3196 !FileApplicationNoteBook::CommandResult methodsFor:'printing'!
  3248 
  3197 
  3249 printOn:aStream
  3198 printOn:aStream
  3250     aStream nextPutAll:'CommandResult Application'.
  3199     aStream nextPutAll:'CommandResult Application'.
  3251 ! !
  3200 ! !
  3252 
  3201 
  3253 
       
  3254 !FileApplicationNoteBook::DigitalNotepadFileViewApplication class methodsFor:'defaults'!
  3202 !FileApplicationNoteBook::DigitalNotepadFileViewApplication class methodsFor:'defaults'!
  3255 
  3203 
  3256 tabStringFor:anApplicationType
  3204 tabStringFor:anApplicationType
  3257     "the formatString shown in a tab (language translated)"
  3205     "the formatString shown in a tab (language translated)"
  3258 
  3206 
  3259     ^ 'Note in %1'
  3207     ^ 'Note in %1'
  3260 
  3208 
  3261     "Modified: / 01-03-2007 / 21:43:23 / cg"
  3209     "Modified: / 01-03-2007 / 21:43:23 / cg"
  3262 ! !
  3210 ! !
  3263 
       
  3264 
  3211 
  3265 !FileApplicationNoteBook::DigitalNotepadFileViewApplication class methodsFor:'documentation'!
  3212 !FileApplicationNoteBook::DigitalNotepadFileViewApplication class methodsFor:'documentation'!
  3266 
  3213 
  3267 documentation
  3214 documentation
  3268 "
  3215 "
  3269     a previewer-plugin for digital-notepad recordings as
  3216     a previewer-plugin for digital-notepad recordings as
  3270     provided by the waltop (tevion) MD85276 digital ink notepad.
  3217     provided by the waltop (tevion) MD85276 digital ink notepad.
  3271 "
  3218 "
  3272 ! !
  3219 ! !
  3273 
  3220 
  3274 
       
  3275 !FileApplicationNoteBook::DigitalNotepadFileViewApplication class methodsFor:'help specs'!
  3221 !FileApplicationNoteBook::DigitalNotepadFileViewApplication class methodsFor:'help specs'!
  3276 
  3222 
  3277 flyByHelpSpec
  3223 flyByHelpSpec
  3278     "This resource specification was automatically generated
  3224     "This resource specification was automatically generated
  3279      by the UIHelpTool of ST/X."
  3225      by the UIHelpTool of ST/X."
  3292 #'fitImageSize'
  3238 #'fitImageSize'
  3293 'Shrink to Fit View'
  3239 'Shrink to Fit View'
  3294 
  3240 
  3295 )
  3241 )
  3296 ! !
  3242 ! !
  3297 
       
  3298 
  3243 
  3299 !FileApplicationNoteBook::DigitalNotepadFileViewApplication class methodsFor:'interface specs'!
  3244 !FileApplicationNoteBook::DigitalNotepadFileViewApplication class methodsFor:'interface specs'!
  3300 
  3245 
  3301 windowSpec
  3246 windowSpec
  3302     "This resource specification was automatically generated
  3247     "This resource specification was automatically generated
  3349            )
  3294            )
  3350          
  3295          
  3351         )
  3296         )
  3352       )
  3297       )
  3353 ! !
  3298 ! !
  3354 
       
  3355 
  3299 
  3356 !FileApplicationNoteBook::DigitalNotepadFileViewApplication class methodsFor:'menu specs'!
  3300 !FileApplicationNoteBook::DigitalNotepadFileViewApplication class methodsFor:'menu specs'!
  3357 
  3301 
  3358 menu
  3302 menu
  3359     "This resource specification was automatically generated
  3303     "This resource specification was automatically generated
  3409         nil
  3353         nil
  3410         nil
  3354         nil
  3411       )
  3355       )
  3412 ! !
  3356 ! !
  3413 
  3357 
  3414 
       
  3415 !FileApplicationNoteBook::DigitalNotepadFileViewApplication class methodsFor:'queries'!
  3358 !FileApplicationNoteBook::DigitalNotepadFileViewApplication class methodsFor:'queries'!
  3416 
  3359 
  3417 canOpenItem:anItem
  3360 canOpenItem:anItem
  3418     ^ anItem mimeType = 'application/x-waltop-digital-notepad'
  3361     ^ anItem mimeType = 'application/x-waltop-digital-notepad'
  3419 !
  3362 !
  3420 
  3363 
  3421 wantNewApplicationAnyway
  3364 wantNewApplicationAnyway
  3422 
  3365 
  3423     ^ false
  3366     ^ false
  3424 ! !
  3367 ! !
  3425 
       
  3426 
  3368 
  3427 !FileApplicationNoteBook::DigitalNotepadFileViewApplication methodsFor:'accessing'!
  3369 !FileApplicationNoteBook::DigitalNotepadFileViewApplication methodsFor:'accessing'!
  3428 
  3370 
  3429 imageView
  3371 imageView
  3430     ^ imageView
  3372     ^ imageView
  3451 "/                with:image depth.
  3393 "/                with:image depth.
  3452 "/    ].
  3394 "/    ].
  3453 "/    self notify:msg.
  3395 "/    self notify:msg.
  3454 ! !
  3396 ! !
  3455 
  3397 
  3456 
       
  3457 !FileApplicationNoteBook::DigitalNotepadFileViewApplication methodsFor:'actions'!
  3398 !FileApplicationNoteBook::DigitalNotepadFileViewApplication methodsFor:'actions'!
  3458 
  3399 
  3459 changeItem:anItem
  3400 changeItem:anItem
  3460 
  3401 
  3461     self item:anItem.
  3402     self item:anItem.
  3465 
  3406 
  3466 setupImageView
  3407 setupImageView
  3467     imageView readFile:self fileName
  3408     imageView readFile:self fileName
  3468 ! !
  3409 ! !
  3469 
  3410 
  3470 
       
  3471 !FileApplicationNoteBook::DigitalNotepadFileViewApplication methodsFor:'aspects'!
  3411 !FileApplicationNoteBook::DigitalNotepadFileViewApplication methodsFor:'aspects'!
  3472 
  3412 
  3473 fitSize
  3413 fitSize
  3474     "return/create the 'fitSize' value holder (automatically generated)"
  3414     "return/create the 'fitSize' value holder (automatically generated)"
  3475 
  3415 
  3477         fitSize := ValueHolder new.
  3417         fitSize := ValueHolder new.
  3478         fitSize addDependent:self.
  3418         fitSize addDependent:self.
  3479     ].
  3419     ].
  3480     ^ fitSize
  3420     ^ fitSize
  3481 ! !
  3421 ! !
  3482 
       
  3483 
  3422 
  3484 !FileApplicationNoteBook::DigitalNotepadFileViewApplication methodsFor:'change & update'!
  3423 !FileApplicationNoteBook::DigitalNotepadFileViewApplication methodsFor:'change & update'!
  3485 
  3424 
  3486 update:something with:aParameter from:changedObject
  3425 update:something with:aParameter from:changedObject
  3487     changedObject == self fitSize ifTrue:[
  3426     changedObject == self fitSize ifTrue:[
  3492         ].
  3431         ].
  3493         ^ self
  3432         ^ self
  3494     ].
  3433     ].
  3495     super update:something with:aParameter from:changedObject
  3434     super update:something with:aParameter from:changedObject
  3496 ! !
  3435 ! !
  3497 
       
  3498 
  3436 
  3499 !FileApplicationNoteBook::DigitalNotepadFileViewApplication methodsFor:'initialization & release'!
  3437 !FileApplicationNoteBook::DigitalNotepadFileViewApplication methodsFor:'initialization & release'!
  3500 
  3438 
  3501 postBuildImageView:aWidget
  3439 postBuildImageView:aWidget
  3502 
  3440 
  3526     ].
  3464     ].
  3527     self setupImageView.
  3465     self setupImageView.
  3528     super postOpenWith:aBuilder
  3466     super postOpenWith:aBuilder
  3529 ! !
  3467 ! !
  3530 
  3468 
  3531 
       
  3532 !FileApplicationNoteBook::HtmlViewApplication class methodsFor:'defaults'!
  3469 !FileApplicationNoteBook::HtmlViewApplication class methodsFor:'defaults'!
  3533 
  3470 
  3534 tabStringFor:aApplicationType
  3471 tabStringFor:aApplicationType
  3535     "the formatString shown in a tab (language translated)"
  3472     "the formatString shown in a tab (language translated)"
  3536 
  3473 
  3537     ^ 'HTML View for %1'
  3474     ^ 'HTML View for %1'
  3538 
  3475 
  3539     "Modified: / 01-03-2007 / 21:43:18 / cg"
  3476     "Modified: / 01-03-2007 / 21:43:18 / cg"
  3540 ! !
  3477 ! !
  3541 
       
  3542 
  3478 
  3543 !FileApplicationNoteBook::HtmlViewApplication class methodsFor:'help specs'!
  3479 !FileApplicationNoteBook::HtmlViewApplication class methodsFor:'help specs'!
  3544 
  3480 
  3545 helpSpec
  3481 helpSpec
  3546     "This resource specification was automatically generated
  3482     "This resource specification was automatically generated
  3560 #'Edit Source'
  3496 #'Edit Source'
  3561 ''
  3497 ''
  3562 
  3498 
  3563 )
  3499 )
  3564 ! !
  3500 ! !
  3565 
       
  3566 
  3501 
  3567 !FileApplicationNoteBook::HtmlViewApplication class methodsFor:'interface specs'!
  3502 !FileApplicationNoteBook::HtmlViewApplication class methodsFor:'interface specs'!
  3568 
  3503 
  3569 windowSpec
  3504 windowSpec
  3570 
  3505 
  3702         )
  3637         )
  3703       )
  3638       )
  3704 
  3639 
  3705     "Modified: / 11-08-2011 / 00:34:35 / Jan Vrany <jan.vrany@fit.cvut.cz>"
  3640     "Modified: / 11-08-2011 / 00:34:35 / Jan Vrany <jan.vrany@fit.cvut.cz>"
  3706 ! !
  3641 ! !
  3707 
       
  3708 
  3642 
  3709 !FileApplicationNoteBook::HtmlViewApplication class methodsFor:'menu specs'!
  3643 !FileApplicationNoteBook::HtmlViewApplication class methodsFor:'menu specs'!
  3710 
  3644 
  3711 menu
  3645 menu
  3712     "This resource specification was automatically generated
  3646     "This resource specification was automatically generated
  3807         nil
  3741         nil
  3808         nil
  3742         nil
  3809       )
  3743       )
  3810 ! !
  3744 ! !
  3811 
  3745 
  3812 
       
  3813 !FileApplicationNoteBook::HtmlViewApplication class methodsFor:'queries'!
  3746 !FileApplicationNoteBook::HtmlViewApplication class methodsFor:'queries'!
  3814 
  3747 
  3815 canOpenItem:anItem
  3748 canOpenItem:anItem
  3816 
  3749 
  3817     ^ (anItem hasMimeType and:[anItem mimeType isHtml])
  3750     ^ (anItem hasMimeType and:[anItem mimeType isHtml])
  3819 
  3752 
  3820 wantNewApplicationAnyway
  3753 wantNewApplicationAnyway
  3821 
  3754 
  3822     ^ false
  3755     ^ false
  3823 ! !
  3756 ! !
  3824 
       
  3825 
  3757 
  3826 !FileApplicationNoteBook::HtmlViewApplication methodsFor:'accessing'!
  3758 !FileApplicationNoteBook::HtmlViewApplication methodsFor:'accessing'!
  3827 
  3759 
  3828 htmlView
  3760 htmlView
  3829     "return the value of the instance variable 'imageView' (automatically generated)"
  3761     "return the value of the instance variable 'imageView' (automatically generated)"
  3845     retVal := super item:anItem.
  3777     retVal := super item:anItem.
  3846     self setupHtmlView.
  3778     self setupHtmlView.
  3847     ^ retVal
  3779     ^ retVal
  3848 ! !
  3780 ! !
  3849 
  3781 
  3850 
       
  3851 !FileApplicationNoteBook::HtmlViewApplication methodsFor:'accessing - subapps'!
  3782 !FileApplicationNoteBook::HtmlViewApplication methodsFor:'accessing - subapps'!
  3852 
  3783 
  3853 webBrowserPage
  3784 webBrowserPage
  3854 
  3785 
  3855     webBrowserPage isNil ifTrue:[
  3786     webBrowserPage isNil ifTrue:[
  3858     ].
  3789     ].
  3859     ^webBrowserPage
  3790     ^webBrowserPage
  3860 
  3791 
  3861     "Created: / 11-08-2011 / 00:32:37 / Jan Vrany <jan.vrany@fit.cvut.cz>"
  3792     "Created: / 11-08-2011 / 00:32:37 / Jan Vrany <jan.vrany@fit.cvut.cz>"
  3862 ! !
  3793 ! !
  3863 
       
  3864 
  3794 
  3865 !FileApplicationNoteBook::HtmlViewApplication methodsFor:'actions'!
  3795 !FileApplicationNoteBook::HtmlViewApplication methodsFor:'actions'!
  3866 
  3796 
  3867 doEdit
  3797 doEdit
  3868     self masterApplication 
  3798     self masterApplication 
  3914     ^ html
  3844     ^ html
  3915 
  3845 
  3916     "Modified: / 17-02-2011 / 14:01:35 / cg"
  3846     "Modified: / 17-02-2011 / 14:01:35 / cg"
  3917 ! !
  3847 ! !
  3918 
  3848 
  3919 
       
  3920 !FileApplicationNoteBook::HtmlViewApplication methodsFor:'aspects'!
  3849 !FileApplicationNoteBook::HtmlViewApplication methodsFor:'aspects'!
  3921 
  3850 
  3922 labelHolder
  3851 labelHolder
  3923 
  3852 
  3924     labelHolder isNil ifTrue:[
  3853     labelHolder isNil ifTrue:[
  3925         labelHolder := '' asValue.
  3854         labelHolder := '' asValue.
  3926     ].
  3855     ].
  3927     ^ labelHolder.
  3856     ^ labelHolder.
  3928 ! !
  3857 ! !
  3929 
       
  3930 
  3858 
  3931 !FileApplicationNoteBook::HtmlViewApplication methodsFor:'initialization & release'!
  3859 !FileApplicationNoteBook::HtmlViewApplication methodsFor:'initialization & release'!
  3932 
  3860 
  3933 postBuildHtmlView:aWidget
  3861 postBuildHtmlView:aWidget
  3934 
  3862 
  3963     super postOpenWith:aBuilder
  3891     super postOpenWith:aBuilder
  3964 
  3892 
  3965     "Modified: / 17-02-2011 / 13:27:12 / cg"
  3893     "Modified: / 17-02-2011 / 13:27:12 / cg"
  3966 ! !
  3894 ! !
  3967 
  3895 
  3968 
       
  3969 !FileApplicationNoteBook::ImageViewApplication class methodsFor:'defaults'!
  3896 !FileApplicationNoteBook::ImageViewApplication class methodsFor:'defaults'!
  3970 
  3897 
  3971 tabStringFor:aApplicationType
  3898 tabStringFor:aApplicationType
  3972     "the formatString shown in a tab (language translated)"
  3899     "the formatString shown in a tab (language translated)"
  3973 
  3900 
  3974     ^ 'Image in %1'
  3901     ^ 'Image in %1'
  3975 
  3902 
  3976     "Modified: / 01-03-2007 / 21:43:23 / cg"
  3903     "Modified: / 01-03-2007 / 21:43:23 / cg"
  3977 ! !
  3904 ! !
  3978 
       
  3979 
  3905 
  3980 !FileApplicationNoteBook::ImageViewApplication class methodsFor:'documentation'!
  3906 !FileApplicationNoteBook::ImageViewApplication class methodsFor:'documentation'!
  3981 
  3907 
  3982 documentation
  3908 documentation
  3983 "
  3909 "
  3984     a previewer-plugin for bitmap images (jpg, xpm, tiff, gif, etc.)
  3910     a previewer-plugin for bitmap images (jpg, xpm, tiff, gif, etc.)
  3985     Offers edit and adjust-size button functions.
  3911     Offers edit and adjust-size button functions.
  3986 "
  3912 "
  3987 ! !
  3913 ! !
  3988 
  3914 
  3989 
       
  3990 !FileApplicationNoteBook::ImageViewApplication class methodsFor:'help specs'!
  3915 !FileApplicationNoteBook::ImageViewApplication class methodsFor:'help specs'!
  3991 
  3916 
  3992 flyByHelpSpec
  3917 flyByHelpSpec
  3993     "This resource specification was automatically generated
  3918     "This resource specification was automatically generated
  3994      by the UIHelpTool of ST/X."
  3919      by the UIHelpTool of ST/X."
  4007 #'fitImageSize'
  3932 #'fitImageSize'
  4008 'Shrink Image to Fit View'
  3933 'Shrink Image to Fit View'
  4009 
  3934 
  4010 )
  3935 )
  4011 ! !
  3936 ! !
  4012 
       
  4013 
  3937 
  4014 !FileApplicationNoteBook::ImageViewApplication class methodsFor:'image specs'!
  3938 !FileApplicationNoteBook::ImageViewApplication class methodsFor:'image specs'!
  4015 
  3939 
  4016 fitSize20x20Icon
  3940 fitSize20x20Icon
  4017     "This resource specification was automatically generated
  3941     "This resource specification was automatically generated
  4039 @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
  3963 @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
  4040 @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
  3964 @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
  4041 @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
  3965 @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
  4042 @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@a') ; yourself); yourself]
  3966 @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@a') ; yourself); yourself]
  4043 ! !
  3967 ! !
  4044 
       
  4045 
  3968 
  4046 !FileApplicationNoteBook::ImageViewApplication class methodsFor:'interface specs'!
  3969 !FileApplicationNoteBook::ImageViewApplication class methodsFor:'interface specs'!
  4047 
  3970 
  4048 windowSpec
  3971 windowSpec
  4049     "This resource specification was automatically generated
  3972     "This resource specification was automatically generated
  4096            )
  4019            )
  4097          
  4020          
  4098         )
  4021         )
  4099       )
  4022       )
  4100 ! !
  4023 ! !
  4101 
       
  4102 
  4024 
  4103 !FileApplicationNoteBook::ImageViewApplication class methodsFor:'menu specs'!
  4025 !FileApplicationNoteBook::ImageViewApplication class methodsFor:'menu specs'!
  4104 
  4026 
  4105 menu
  4027 menu
  4106     "This resource specification was automatically generated
  4028     "This resource specification was automatically generated
  4156         nil
  4078         nil
  4157         nil
  4079         nil
  4158       )
  4080       )
  4159 ! !
  4081 ! !
  4160 
  4082 
  4161 
       
  4162 !FileApplicationNoteBook::ImageViewApplication class methodsFor:'queries'!
  4083 !FileApplicationNoteBook::ImageViewApplication class methodsFor:'queries'!
  4163 
  4084 
  4164 canOpenItem:anItem
  4085 canOpenItem:anItem
  4165 
  4086 
  4166     ^ (anItem hasMimeType and:[anItem mimeType isImage])
  4087     ^ (anItem hasMimeType and:[anItem mimeType isImage])
  4168 
  4089 
  4169 wantNewApplicationAnyway
  4090 wantNewApplicationAnyway
  4170 
  4091 
  4171     ^ false
  4092     ^ false
  4172 ! !
  4093 ! !
  4173 
       
  4174 
  4094 
  4175 !FileApplicationNoteBook::ImageViewApplication methodsFor:'accessing'!
  4095 !FileApplicationNoteBook::ImageViewApplication methodsFor:'accessing'!
  4176 
  4096 
  4177 image:something
  4097 image:something
  4178     image := something.
  4098     image := something.
  4203                 with:image height
  4123                 with:image height
  4204                 with:image depth.
  4124                 with:image depth.
  4205     ].
  4125     ].
  4206     self notify:msg.
  4126     self notify:msg.
  4207 ! !
  4127 ! !
  4208 
       
  4209 
  4128 
  4210 !FileApplicationNoteBook::ImageViewApplication methodsFor:'actions'!
  4129 !FileApplicationNoteBook::ImageViewApplication methodsFor:'actions'!
  4211 
  4130 
  4212 changeItem:anItem
  4131 changeItem:anItem
  4213 
  4132 
  4260     ] fork.
  4179     ] fork.
  4261 
  4180 
  4262     "Modified: / 25-07-2006 / 09:09:33 / cg"
  4181     "Modified: / 25-07-2006 / 09:09:33 / cg"
  4263 ! !
  4182 ! !
  4264 
  4183 
  4265 
       
  4266 !FileApplicationNoteBook::ImageViewApplication methodsFor:'aspects'!
  4184 !FileApplicationNoteBook::ImageViewApplication methodsFor:'aspects'!
  4267 
  4185 
  4268 fitSize
  4186 fitSize
  4269     "return/create the 'fitSize' value holder (automatically generated)"
  4187     "return/create the 'fitSize' value holder (automatically generated)"
  4270 
  4188 
  4272         fitSize := ValueHolder new.
  4190         fitSize := ValueHolder new.
  4273         fitSize addDependent:self.
  4191         fitSize addDependent:self.
  4274     ].
  4192     ].
  4275     ^ fitSize
  4193     ^ fitSize
  4276 ! !
  4194 ! !
  4277 
       
  4278 
  4195 
  4279 !FileApplicationNoteBook::ImageViewApplication methodsFor:'change & update'!
  4196 !FileApplicationNoteBook::ImageViewApplication methodsFor:'change & update'!
  4280 
  4197 
  4281 update:something with:aParameter from:changedObject
  4198 update:something with:aParameter from:changedObject
  4282     changedObject == self fitSize ifTrue:[
  4199     changedObject == self fitSize ifTrue:[
  4287         ].
  4204         ].
  4288         ^ self
  4205         ^ self
  4289     ].
  4206     ].
  4290     super update:something with:aParameter from:changedObject
  4207     super update:something with:aParameter from:changedObject
  4291 ! !
  4208 ! !
  4292 
       
  4293 
  4209 
  4294 !FileApplicationNoteBook::ImageViewApplication methodsFor:'initialization & release'!
  4210 !FileApplicationNoteBook::ImageViewApplication methodsFor:'initialization & release'!
  4295 
  4211 
  4296 postBuildImageView:aWidget
  4212 postBuildImageView:aWidget
  4297 
  4213 
  4322     ].
  4238     ].
  4323     self setupImageView.
  4239     self setupImageView.
  4324     super postOpenWith:aBuilder
  4240     super postOpenWith:aBuilder
  4325 ! !
  4241 ! !
  4326 
  4242 
  4327 
       
  4328 !FileApplicationNoteBook::Terminal class methodsFor:'defaults'!
  4243 !FileApplicationNoteBook::Terminal class methodsFor:'defaults'!
  4329 
  4244 
  4330 defaultLineLimit
  4245 defaultLineLimit
  4331     "the number of buffered lines"
  4246     "the number of buffered lines"
  4332 
  4247 
  4344 
  4259 
  4345     ^ 'Terminal'
  4260     ^ 'Terminal'
  4346 
  4261 
  4347     "Modified: / 01-03-2007 / 21:43:38 / cg"
  4262     "Modified: / 01-03-2007 / 21:43:38 / cg"
  4348 ! !
  4263 ! !
  4349 
       
  4350 
  4264 
  4351 !FileApplicationNoteBook::Terminal class methodsFor:'help specs'!
  4265 !FileApplicationNoteBook::Terminal class methodsFor:'help specs'!
  4352 
  4266 
  4353 helpSpec
  4267 helpSpec
  4354     "This resource specification was automatically generated
  4268     "This resource specification was automatically generated
  4368 #closeTabButton
  4282 #closeTabButton
  4369 ''
  4283 ''
  4370 
  4284 
  4371 )
  4285 )
  4372 ! !
  4286 ! !
  4373 
       
  4374 
  4287 
  4375 !FileApplicationNoteBook::Terminal class methodsFor:'interface specs'!
  4288 !FileApplicationNoteBook::Terminal class methodsFor:'interface specs'!
  4376 
  4289 
  4377 windowSpec
  4290 windowSpec
  4378     "This resource specification was automatically generated
  4291     "This resource specification was automatically generated
  4425          
  4338          
  4426         )
  4339         )
  4427       )
  4340       )
  4428 ! !
  4341 ! !
  4429 
  4342 
  4430 
       
  4431 !FileApplicationNoteBook::Terminal class methodsFor:'menu specs'!
  4343 !FileApplicationNoteBook::Terminal class methodsFor:'menu specs'!
  4432 
  4344 
  4433 menu
  4345 menu
  4434     "This resource specification was automatically generated
  4346     "This resource specification was automatically generated
  4435      by the MenuEditor of ST/X."
  4347      by the MenuEditor of ST/X."
  4471         nil
  4383         nil
  4472         nil
  4384         nil
  4473       )
  4385       )
  4474 ! !
  4386 ! !
  4475 
  4387 
  4476 
       
  4477 !FileApplicationNoteBook::Terminal methodsFor:'accessing'!
  4388 !FileApplicationNoteBook::Terminal methodsFor:'accessing'!
  4478 
  4389 
  4479 terminalView
  4390 terminalView
  4480 
  4391 
  4481     terminalView isNil ifTrue:[
  4392     terminalView isNil ifTrue:[
  4494     ^ terminalView.
  4405     ^ terminalView.
  4495 
  4406 
  4496     "Modified: / 05-04-2012 / 15:58:04 / Jan Vrany <jan.vrany@fit.cvut.cz>"
  4407     "Modified: / 05-04-2012 / 15:58:04 / Jan Vrany <jan.vrany@fit.cvut.cz>"
  4497 ! !
  4408 ! !
  4498 
  4409 
  4499 
       
  4500 !FileApplicationNoteBook::Terminal methodsFor:'actions'!
  4410 !FileApplicationNoteBook::Terminal methodsFor:'actions'!
  4501 
  4411 
  4502 saveAs
  4412 saveAs
  4503 
  4413 
  4504     self terminalView save.
  4414     self terminalView save.
  4505 ! !
  4415 ! !
  4506 
       
  4507 
  4416 
  4508 !FileApplicationNoteBook::Terminal methodsFor:'initialization & release'!
  4417 !FileApplicationNoteBook::Terminal methodsFor:'initialization & release'!
  4509 
  4418 
  4510 shellFinished
  4419 shellFinished
  4511     | master text string|
  4420     | master text string|
  4529     vt100 := self terminalView.
  4438     vt100 := self terminalView.
  4530     vt100 shellTerminateAction:[ self shellFinished ].
  4439     vt100 shellTerminateAction:[ self shellFinished ].
  4531     vt100 startShellIn:(self fileName).
  4440     vt100 startShellIn:(self fileName).
  4532 ! !
  4441 ! !
  4533 
  4442 
  4534 
       
  4535 !FileApplicationNoteBook::Terminal methodsFor:'printing'!
  4443 !FileApplicationNoteBook::Terminal methodsFor:'printing'!
  4536 
  4444 
  4537 printOn:aStream
  4445 printOn:aStream
  4538     aStream nextPutAll:'Terminal on:'.
  4446     aStream nextPutAll:'Terminal on:'.
  4539     self fileName baseName printOn:aStream.
  4447     self fileName baseName printOn:aStream.
  4540 ! !
  4448 ! !
  4541 
  4449 
  4542 
       
  4543 !FileApplicationNoteBook::Terminal methodsFor:'queries'!
  4450 !FileApplicationNoteBook::Terminal methodsFor:'queries'!
  4544 
  4451 
  4545 getTabValueString
  4452 getTabValueString
  4546     "the item shown in a tab (not language translated)"
  4453     "the item shown in a tab (not language translated)"
  4547 
  4454 
  4548     ^ nil
  4455     ^ nil
  4549 
  4456 
  4550     "Created: / 01-03-2007 / 21:39:56 / cg"
  4457     "Created: / 01-03-2007 / 21:39:56 / cg"
  4551 ! !
  4458 ! !
  4552 
       
  4553 
  4459 
  4554 !FileApplicationNoteBook::Terminal methodsFor:'startup & release'!
  4460 !FileApplicationNoteBook::Terminal methodsFor:'startup & release'!
  4555 
  4461 
  4556 postOpenWith:aBuilder
  4462 postOpenWith:aBuilder
  4557     "only invoked if the application not started from a master"
  4463     "only invoked if the application not started from a master"
  4562     ].
  4468     ].
  4563     self startShell.
  4469     self startShell.
  4564     super postOpenWith:aBuilder.
  4470     super postOpenWith:aBuilder.
  4565 ! !
  4471 ! !
  4566 
  4472 
  4567 
       
  4568 !FileApplicationNoteBook::TextEditor class methodsFor:'defaults'!
  4473 !FileApplicationNoteBook::TextEditor class methodsFor:'defaults'!
  4569 
  4474 
  4570 checkModifiedDelayTime
  4475 checkModifiedDelayTime
  4571     ^ 30    "seconds"
  4476     ^ 30    "seconds"
  4572 !
  4477 !
  4590 
  4495 
  4591 wantNewApplicationAnyway
  4496 wantNewApplicationAnyway
  4592 
  4497 
  4593     ^ false
  4498     ^ false
  4594 ! !
  4499 ! !
  4595 
       
  4596 
  4500 
  4597 !FileApplicationNoteBook::TextEditor class methodsFor:'documentation'!
  4501 !FileApplicationNoteBook::TextEditor class methodsFor:'documentation'!
  4598 
  4502 
  4599 documentation
  4503 documentation
  4600 "
  4504 "
  4601     a previewer-plugin for plain text
  4505     a previewer-plugin for plain text
  4602     Offers edit, hex-display and diff functions.
  4506     Offers edit, hex-display and diff functions.
  4603 "
  4507 "
  4604 ! !
  4508 ! !
  4605 
  4509 
  4606 
       
  4607 !FileApplicationNoteBook::TextEditor class methodsFor:'help specs'!
  4510 !FileApplicationNoteBook::TextEditor class methodsFor:'help specs'!
  4608 
  4511 
  4609 helpSpec
  4512 helpSpec
  4610     "This resource specification was automatically generated
  4513     "This resource specification was automatically generated
  4611      by the UIHelpTool of ST/X."
  4514      by the UIHelpTool of ST/X."
  4624 #closeTabButton
  4527 #closeTabButton
  4625 ''
  4528 ''
  4626 
  4529 
  4627 )
  4530 )
  4628 ! !
  4531 ! !
  4629 
       
  4630 
  4532 
  4631 !FileApplicationNoteBook::TextEditor class methodsFor:'interface specs'!
  4533 !FileApplicationNoteBook::TextEditor class methodsFor:'interface specs'!
  4632 
  4534 
  4633 windowSpec
  4535 windowSpec
  4634     "This resource specification was automatically generated
  4536     "This resource specification was automatically generated
  4756            )
  4658            )
  4757          
  4659          
  4758         )
  4660         )
  4759       )
  4661       )
  4760 ! !
  4662 ! !
  4761 
       
  4762 
  4663 
  4763 !FileApplicationNoteBook::TextEditor class methodsFor:'menu specs'!
  4664 !FileApplicationNoteBook::TextEditor class methodsFor:'menu specs'!
  4764 
  4665 
  4765 menu
  4666 menu
  4766     "This resource specification was automatically generated
  4667     "This resource specification was automatically generated
  4877         nil
  4778         nil
  4878         nil
  4779         nil
  4879       )
  4780       )
  4880 ! !
  4781 ! !
  4881 
  4782 
  4882 
       
  4883 !FileApplicationNoteBook::TextEditor methodsFor:'accessing'!
  4783 !FileApplicationNoteBook::TextEditor methodsFor:'accessing'!
  4884 
  4784 
  4885 fileEncoding
  4785 fileEncoding
  4886     ^ self fileEncodingHolder value
  4786     ^ self fileEncodingHolder value
  4887 !
  4787 !
  4944 type:aType
  4844 type:aType
  4945 
  4845 
  4946     super type:aType.
  4846     super type:aType.
  4947     self changeInformation.
  4847     self changeInformation.
  4948 ! !
  4848 ! !
  4949 
       
  4950 
  4849 
  4951 !FileApplicationNoteBook::TextEditor methodsFor:'actions'!
  4850 !FileApplicationNoteBook::TextEditor methodsFor:'actions'!
  4952 
  4851 
  4953 accept
  4852 accept
  4954     self saveWithAskForFilename:false.
  4853     self saveWithAskForFilename:false.
  5566                 editView validateFontEncodingFor:fileEncoding ask:false.
  5465                 editView validateFontEncodingFor:fileEncoding ask:false.
  5567             ].
  5466             ].
  5568     ].
  5467     ].
  5569 ! !
  5468 ! !
  5570 
  5469 
  5571 
       
  5572 !FileApplicationNoteBook::TextEditor methodsFor:'aspects'!
  5470 !FileApplicationNoteBook::TextEditor methodsFor:'aspects'!
  5573 
  5471 
  5574 cursorColLabelHolder
  5472 cursorColLabelHolder
  5575     ^ BlockValue 
  5473     ^ BlockValue 
  5576         with:[:v | v printString]
  5474         with:[:v | v printString]
  5705         viewModifiedChannel := false asValue.
  5603         viewModifiedChannel := false asValue.
  5706         viewModifiedChannel addDependent:self.
  5604         viewModifiedChannel addDependent:self.
  5707     ].
  5605     ].
  5708     ^ viewModifiedChannel.
  5606     ^ viewModifiedChannel.
  5709 ! !
  5607 ! !
  5710 
       
  5711 
  5608 
  5712 !FileApplicationNoteBook::TextEditor methodsFor:'aspects-visibility'!
  5609 !FileApplicationNoteBook::TextEditor methodsFor:'aspects-visibility'!
  5713 
  5610 
  5714 closeButtonShown
  5611 closeButtonShown
  5715     ^ false.
  5612     ^ false.
  5750     ^ tagsBrowserVisibleHolder
  5647     ^ tagsBrowserVisibleHolder
  5751 
  5648 
  5752     "Created: / 23-06-2011 / 09:19:18 / cg"
  5649     "Created: / 23-06-2011 / 09:19:18 / cg"
  5753     "Modified: / 06-10-2011 / 12:46:41 / cg"
  5650     "Modified: / 06-10-2011 / 12:46:41 / cg"
  5754 ! !
  5651 ! !
  5755 
       
  5756 
  5652 
  5757 !FileApplicationNoteBook::TextEditor methodsFor:'change & update'!
  5653 !FileApplicationNoteBook::TextEditor methodsFor:'change & update'!
  5758 
  5654 
  5759 changeTextColorForChanged
  5655 changeTextColorForChanged
  5760     |text prevCursorBehavior|
  5656     |text prevCursorBehavior|
  5927     ]
  5823     ]
  5928 
  5824 
  5929     "Created: / 23-06-2011 / 16:32:44 / cg"
  5825     "Created: / 23-06-2011 / 16:32:44 / cg"
  5930 ! !
  5826 ! !
  5931 
  5827 
  5932 
       
  5933 !FileApplicationNoteBook::TextEditor methodsFor:'initialization'!
  5828 !FileApplicationNoteBook::TextEditor methodsFor:'initialization'!
  5934 
  5829 
  5935 initialize
  5830 initialize
  5936     super initialize.
  5831     super initialize.
  5937     semaChangeItem := Semaphore forMutualExclusion.
  5832     semaChangeItem := Semaphore forMutualExclusion.
  5938 ! !
  5833 ! !
  5939 
       
  5940 
  5834 
  5941 !FileApplicationNoteBook::TextEditor methodsFor:'printing'!
  5835 !FileApplicationNoteBook::TextEditor methodsFor:'printing'!
  5942 
  5836 
  5943 printOn:aStream
  5837 printOn:aStream
  5944     |fn|
  5838     |fn|
  5946     aStream nextPutAll:'TextEditor for:'.
  5840     aStream nextPutAll:'TextEditor for:'.
  5947     (fn := self fileName) notNil ifTrue:[
  5841     (fn := self fileName) notNil ifTrue:[
  5948         fn baseName printOn:aStream.
  5842         fn baseName printOn:aStream.
  5949     ]
  5843     ]
  5950 ! !
  5844 ! !
  5951 
       
  5952 
  5845 
  5953 !FileApplicationNoteBook::TextEditor methodsFor:'private-process'!
  5846 !FileApplicationNoteBook::TextEditor methodsFor:'private-process'!
  5954 
  5847 
  5955 checkItemForChanges
  5848 checkItemForChanges
  5956     |exists fileModificationTime message|
  5849     |exists fileModificationTime message|
  6004             ].
  5897             ].
  6005     ].
  5898     ].
  6006     Processor addTimedBlock:checkModifiedBlock afterSeconds:(self class checkModifiedDelayTime).
  5899     Processor addTimedBlock:checkModifiedBlock afterSeconds:(self class checkModifiedDelayTime).
  6007 ! !
  5900 ! !
  6008 
  5901 
  6009 
       
  6010 !FileApplicationNoteBook::TextEditor methodsFor:'queries'!
  5902 !FileApplicationNoteBook::TextEditor methodsFor:'queries'!
  6011 
  5903 
  6012 additionalInfo
  5904 additionalInfo
  6013     ^ '[',editView numberOfLines printString , ' lines]'.
  5905     ^ '[',editView numberOfLines printString , ' lines]'.
  6014 
  5906 
  6027 
  5919 
  6028 isTextEditor
  5920 isTextEditor
  6029 
  5921 
  6030     ^ true
  5922     ^ true
  6031 ! !
  5923 ! !
  6032 
       
  6033 
  5924 
  6034 !FileApplicationNoteBook::TextEditor methodsFor:'startup & release'!
  5925 !FileApplicationNoteBook::TextEditor methodsFor:'startup & release'!
  6035 
  5926 
  6036 closeRequest
  5927 closeRequest
  6037     "asks for permission before closing"
  5928     "asks for permission before closing"
  6150     ]
  6041     ]
  6151 
  6042 
  6152     "Modified: / 10-04-2007 / 15:24:22 / cg"
  6043     "Modified: / 10-04-2007 / 15:24:22 / cg"
  6153 ! !
  6044 ! !
  6154 
  6045 
  6155 
       
  6156 !FileApplicationNoteBook::XMLViewApplication class methodsFor:'defaults'!
  6046 !FileApplicationNoteBook::XMLViewApplication class methodsFor:'defaults'!
  6157 
  6047 
  6158 tabStringFor:aApplicationType
  6048 tabStringFor:aApplicationType
  6159     "the formatString shown in a tab (language translated)"
  6049     "the formatString shown in a tab (language translated)"
  6160 
  6050 
  6161     ^ 'XML View for %1'
  6051     ^ 'XML View for %1'
  6162 
  6052 
  6163     "Modified: / 17-02-2011 / 13:28:22 / cg"
  6053     "Modified: / 17-02-2011 / 13:28:22 / cg"
  6164 ! !
  6054 ! !
  6165 
       
  6166 
  6055 
  6167 !FileApplicationNoteBook::XMLViewApplication class methodsFor:'help specs'!
  6056 !FileApplicationNoteBook::XMLViewApplication class methodsFor:'help specs'!
  6168 
  6057 
  6169 helpSpec
  6058 helpSpec
  6170     "This resource specification was automatically generated
  6059     "This resource specification was automatically generated
  6184 
  6073 
  6185 )
  6074 )
  6186 
  6075 
  6187     "Modified: / 17-02-2011 / 13:28:28 / cg"
  6076     "Modified: / 17-02-2011 / 13:28:28 / cg"
  6188 ! !
  6077 ! !
  6189 
       
  6190 
  6078 
  6191 !FileApplicationNoteBook::XMLViewApplication class methodsFor:'interface specs'!
  6079 !FileApplicationNoteBook::XMLViewApplication class methodsFor:'interface specs'!
  6192 
  6080 
  6193 windowSpec
  6081 windowSpec
  6194     "This resource specification was automatically generated
  6082     "This resource specification was automatically generated
  6242          
  6130          
  6243         )
  6131         )
  6244       )
  6132       )
  6245 ! !
  6133 ! !
  6246 
  6134 
  6247 
       
  6248 !FileApplicationNoteBook::XMLViewApplication class methodsFor:'menu specs'!
  6135 !FileApplicationNoteBook::XMLViewApplication class methodsFor:'menu specs'!
  6249 
  6136 
  6250 menu
  6137 menu
  6251     "This resource specification was automatically generated
  6138     "This resource specification was automatically generated
  6252      by the MenuEditor of ST/X."
  6139      by the MenuEditor of ST/X."
  6291       )
  6178       )
  6292 
  6179 
  6293     "Modified: / 17-02-2011 / 17:30:26 / cg"
  6180     "Modified: / 17-02-2011 / 17:30:26 / cg"
  6294 ! !
  6181 ! !
  6295 
  6182 
  6296 
       
  6297 !FileApplicationNoteBook::XMLViewApplication class methodsFor:'queries'!
  6183 !FileApplicationNoteBook::XMLViewApplication class methodsFor:'queries'!
  6298 
  6184 
  6299 canOpenItem:anItem
  6185 canOpenItem:anItem
  6300     (Smalltalk at:#'XML::XMLInspector') isNil ifTrue:[^ false].
  6186     (Smalltalk at:#'XML::XMLInspector') isNil ifTrue:[^ false].
  6301 
  6187 
  6306 
  6192 
  6307 wantNewApplicationAnyway
  6193 wantNewApplicationAnyway
  6308 
  6194 
  6309     ^ false
  6195     ^ false
  6310 ! !
  6196 ! !
  6311 
       
  6312 
  6197 
  6313 !FileApplicationNoteBook::XMLViewApplication methodsFor:'accessing'!
  6198 !FileApplicationNoteBook::XMLViewApplication methodsFor:'accessing'!
  6314 
  6199 
  6315 item:anItem 
  6200 item:anItem 
  6316     |retVal|
  6201     |retVal|
  6352 
  6237 
  6353     "Created: / 17-02-2011 / 13:39:07 / cg"
  6238     "Created: / 17-02-2011 / 13:39:07 / cg"
  6354     "Modified: / 17-02-2011 / 17:39:15 / cg"
  6239     "Modified: / 17-02-2011 / 17:39:15 / cg"
  6355 ! !
  6240 ! !
  6356 
  6241 
  6357 
       
  6358 !FileApplicationNoteBook::XMLViewApplication methodsFor:'actions'!
  6242 !FileApplicationNoteBook::XMLViewApplication methodsFor:'actions'!
  6359 
  6243 
  6360 reload
  6244 reload
  6361     self updateXMLTree.
  6245     self updateXMLTree.
  6362 
  6246 
  6363     "Created: / 17-02-2011 / 17:46:36 / cg"
  6247     "Created: / 17-02-2011 / 17:46:36 / cg"
  6364 ! !
  6248 ! !
  6365 
  6249 
  6366 
       
  6367 !FileApplicationNoteBook::XMLViewApplication methodsFor:'aspects'!
  6250 !FileApplicationNoteBook::XMLViewApplication methodsFor:'aspects'!
  6368 
  6251 
  6369 labelHolder
  6252 labelHolder
  6370 
  6253 
  6371     labelHolder isNil ifTrue:[
  6254     labelHolder isNil ifTrue:[
  6372         labelHolder := '' asValue.
  6255         labelHolder := '' asValue.
  6373     ].
  6256     ].
  6374     ^ labelHolder.
  6257     ^ labelHolder.
  6375 ! !
  6258 ! !
  6376 
       
  6377 
  6259 
  6378 !FileApplicationNoteBook::XMLViewApplication methodsFor:'initialization & release'!
  6260 !FileApplicationNoteBook::XMLViewApplication methodsFor:'initialization & release'!
  6379 
  6261 
  6380 postBuildXMLCanvas:aWidget
  6262 postBuildXMLCanvas:aWidget
  6381     xmlTreeApp := aWidget client.
  6263     xmlTreeApp := aWidget client.
  6382     item notNil ifTrue:[self updateXMLTree].
  6264     item notNil ifTrue:[self updateXMLTree].
  6383 
  6265 
  6384     "Modified: / 17-02-2011 / 13:39:18 / cg"
  6266     "Modified: / 17-02-2011 / 13:39:18 / cg"
  6385 ! !
  6267 ! !
  6386 
       
  6387 
  6268 
  6388 !FileApplicationNoteBook::XViewApplication class methodsFor:'defaults'!
  6269 !FileApplicationNoteBook::XViewApplication class methodsFor:'defaults'!
  6389 
  6270 
  6390 maxNumberOfVNCRestarts
  6271 maxNumberOfVNCRestarts
  6391 
  6272 
  6419 
  6300 
  6420 wantNewApplicationAnyway
  6301 wantNewApplicationAnyway
  6421 
  6302 
  6422     ^ true
  6303     ^ true
  6423 ! !
  6304 ! !
  6424 
       
  6425 
  6305 
  6426 !FileApplicationNoteBook::XViewApplication class methodsFor:'interface specs'!
  6306 !FileApplicationNoteBook::XViewApplication class methodsFor:'interface specs'!
  6427 
  6307 
  6428 windowSpec
  6308 windowSpec
  6429     "This resource specification was automatically generated
  6309     "This resource specification was automatically generated
  6477          
  6357          
  6478         )
  6358         )
  6479       )
  6359       )
  6480 ! !
  6360 ! !
  6481 
  6361 
  6482 
       
  6483 !FileApplicationNoteBook::XViewApplication class methodsFor:'menu specs'!
  6362 !FileApplicationNoteBook::XViewApplication class methodsFor:'menu specs'!
  6484 
  6363 
  6485 menu
  6364 menu
  6486     "This resource specification was automatically generated
  6365     "This resource specification was automatically generated
  6487      by the MenuEditor of ST/X."
  6366      by the MenuEditor of ST/X."
  6513         nil
  6392         nil
  6514         nil
  6393         nil
  6515       )
  6394       )
  6516 ! !
  6395 ! !
  6517 
  6396 
  6518 
       
  6519 !FileApplicationNoteBook::XViewApplication class methodsFor:'queries'!
  6397 !FileApplicationNoteBook::XViewApplication class methodsFor:'queries'!
  6520 
  6398 
  6521 canOpenItem:anItem
  6399 canOpenItem:anItem
  6522     | keySym|
  6400     | keySym|
  6523     
  6401     
  6536         ^ false.
  6414         ^ false.
  6537     ].
  6415     ].
  6538     ^ true
  6416     ^ true
  6539 ! !
  6417 ! !
  6540 
  6418 
  6541 
       
  6542 !FileApplicationNoteBook::XViewApplication methodsFor:'accessing'!
  6419 !FileApplicationNoteBook::XViewApplication methodsFor:'accessing'!
  6543 
  6420 
  6544 xView
  6421 xView
  6545     "return the value of the instance variable 'imageView' (automatically generated)"
  6422     "return the value of the instance variable 'imageView' (automatically generated)"
  6546 
  6423 
  6550 xView:something
  6427 xView:something
  6551     "set the value of the instance variable 'imageView' (automatically generated)"
  6428     "set the value of the instance variable 'imageView' (automatically generated)"
  6552 
  6429 
  6553     xView := something.
  6430     xView := something.
  6554 ! !
  6431 ! !
  6555 
       
  6556 
  6432 
  6557 !FileApplicationNoteBook::XViewApplication methodsFor:'actions'!
  6433 !FileApplicationNoteBook::XViewApplication methodsFor:'actions'!
  6558 
  6434 
  6559 changeInformation 
  6435 changeInformation 
  6560 
  6436 
  6589         yExt := self xView height asString.
  6465         yExt := self xView height asString.
  6590     ].
  6466     ].
  6591     ext := xExt, 'x', yExt.    
  6467     ext := xExt, 'x', yExt.    
  6592     self startViewer.
  6468     self startViewer.
  6593 ! !
  6469 ! !
  6594 
       
  6595 
  6470 
  6596 !FileApplicationNoteBook::XViewApplication methodsFor:'actions VNC'!
  6471 !FileApplicationNoteBook::XViewApplication methodsFor:'actions VNC'!
  6597 
  6472 
  6598 setupView
  6473 setupView
  6599     |  renderer view|
  6474     |  renderer view|
  6759         Delay waitForSeconds:0.5.
  6634         Delay waitForSeconds:0.5.
  6760     ].
  6635     ].
  6761     ^ true
  6636     ^ true
  6762 ! !
  6637 ! !
  6763 
  6638 
  6764 
       
  6765 !FileApplicationNoteBook::XViewApplication methodsFor:'actions viewer'!
  6639 !FileApplicationNoteBook::XViewApplication methodsFor:'actions viewer'!
  6766 
  6640 
  6767 startViewer
  6641 startViewer
  6768     |cmd keySym applItem |
  6642     |cmd keySym applItem |
  6769 
  6643 
  6837 "/    Transcript showCR:'viewer has terminated'.
  6711 "/    Transcript showCR:'viewer has terminated'.
  6838 "/    'viewer has terminated' errorPrintCR.
  6712 "/    'viewer has terminated' errorPrintCR.
  6839     "/ Dialog information:'viewer has terminated'.
  6713     "/ Dialog information:'viewer has terminated'.
  6840 ! !
  6714 ! !
  6841 
  6715 
  6842 
       
  6843 !FileApplicationNoteBook::XViewApplication methodsFor:'initialization & release'!
  6716 !FileApplicationNoteBook::XViewApplication methodsFor:'initialization & release'!
  6844 
  6717 
  6845 postBuildXView:aWidget
  6718 postBuildXView:aWidget
  6846 
  6719 
  6847     self xView:aWidget scrolledView.
  6720     self xView:aWidget scrolledView.
  6880     self stopViewer.
  6753     self stopViewer.
  6881     self stopVNCServer.
  6754     self stopVNCServer.
  6882     ^ super release
  6755     ^ super release
  6883 ! !
  6756 ! !
  6884 
  6757 
  6885 
       
  6886 !FileApplicationNoteBook class methodsFor:'documentation'!
  6758 !FileApplicationNoteBook class methodsFor:'documentation'!
  6887 
  6759 
  6888 version
  6760 version
  6889     ^ '$Header: /cvs/stx/stx/libtool/FileApplicationNoteBook.st,v 1.276 2013-03-19 13:53:54 cg Exp $'
  6761     ^ '$Header: /cvs/stx/stx/libtool/FileApplicationNoteBook.st,v 1.277 2013-06-04 10:46:46 cg Exp $'
  6890 !
  6762 !
  6891 
  6763 
  6892 version_CVS
  6764 version_CVS
  6893     ^ '$Header: /cvs/stx/stx/libtool/FileApplicationNoteBook.st,v 1.276 2013-03-19 13:53:54 cg Exp $'
  6765     ^ '$Header: /cvs/stx/stx/libtool/FileApplicationNoteBook.st,v 1.277 2013-06-04 10:46:46 cg Exp $'
  6894 !
  6766 !
  6895 
  6767 
  6896 version_HG
  6768 version_HG
  6897 
  6769 
  6898     ^ '$Changeset: <not expanded> $'
  6770     ^ '$Changeset: <not expanded> $'