initial checkin
authorClaus Gittinger <cg@exept.de>
Sat, 20 Aug 2011 14:28:01 +0200
changeset 340 e19af0c2226e
parent 339 98bc665876cf
child 341 2f6e029166a1
initial checkin
MCRepositoryList.st
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/MCRepositoryList.st	Sat Aug 20 14:28:01 2011 +0200
@@ -0,0 +1,89 @@
+"{ Package: 'stx:goodies/monticello' }"
+
+MCBrowserList subclass:#MCRepositoryList
+	instanceVariableNames:''
+	classVariableNames:''
+	poolDictionaries:''
+	category:'Monticello-St/X UI'
+!
+
+
+!MCRepositoryList methodsFor:'drag & drop'!
+
+dropObjects:aCollectionOfDropObjects
+    "drop manager wants to drop.
+     This is ony sent, if #canDrop: returned true.
+     Must be redefined in order for drop to work."
+
+    ^ self shouldImplement
+! !
+
+!MCRepositoryList methodsFor:'generators'!
+
+makeEntry: repository
+
+    ^MCRepositoryEntry repository: repository
+
+    "Created: / 16-09-2010 / 18:40:43 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+!
+
+makeGenerator
+
+    ^Iterator on:
+        [:whatToDo| | selection |
+        selection := self selectionHolder value.
+        selection ifNotNil:[
+        selection packages do: [:pkgentry|whatToDo value: pkgentry]]].
+
+    "Modified: / 16-09-2010 / 18:58:11 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+! !
+
+!MCRepositoryList methodsFor:'private'!
+
+browserNameList
+    "superclass Tools::BrowserList says that I am responsible to implement this method"
+
+    ^ self shouldImplement
+!
+
+makeDependent
+    "superclass Tools::BrowserList says that I am responsible to implement this method"
+
+    "^ self shouldImplement"
+
+    "Modified: / 16-09-2010 / 16:05:46 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+!
+
+makeIndependent
+    "superclass Tools::BrowserList says that I am responsible to implement this method"
+
+    "^ self shouldImplement"
+
+    "Modified: / 16-09-2010 / 16:05:51 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+!
+
+updateList
+
+    | repos list |
+    repos := self inGeneratorHolder value.
+    repos ifNil:[repos := MCRepositoryGroup default repositories].
+    list := repos collect: [:repo|self makeEntry:repo].
+    self listHolder value: list.
+    listValid := true.
+
+    "Modified: / 16-09-2010 / 18:58:47 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+! !
+
+!MCRepositoryList class methodsFor:'documentation'!
+
+version
+    ^ '$Header: /cvs/stx/stx/goodies/monticello/MCRepositoryList.st,v 1.1 2011-08-20 12:28:01 cg Exp $'
+!
+
+version_CVS
+    ^ '$Header: /cvs/stx/stx/goodies/monticello/MCRepositoryList.st,v 1.1 2011-08-20 12:28:01 cg Exp $'
+!
+
+version_SVN
+    ^ '§Id: MCRepositoryList.st 14 2010-09-17 14:16:41Z vranyj1 §'
+! !