renamed canvas into palette
It does not do any drawing and therefore, canvas was the wrong word
(I never found it and had to use the window-fly-by-help to find it)
--- a/UIGalleryView.st Wed Jun 10 22:13:48 2009 +0200
+++ b/UIGalleryView.st Wed Jun 10 22:33:37 2009 +0200
@@ -18,7 +18,7 @@
category:'Interface-UIPainter'
!
-View subclass:#Canvas
+View subclass:#Palette
instanceVariableNames:'clientSpecHolder selection specification lastClickPoint
menuSelector uiBuilder hiddenCounter showBorders
didWarnAboutUnknownSpecs'
@@ -31,7 +31,7 @@
instanceVariableNames:''
classVariableNames:''
poolDictionaries:''
- privateIn:UIGalleryView::Canvas
+ privateIn:UIGalleryView::Palette
!
!UIGalleryView class methodsFor:'documentation'!
@@ -277,7 +277,7 @@
initialize
"setup default attributes
"
- canvas := Canvas in:self.
+ canvas := Palette in:self.
super initialize.
@@ -292,18 +292,18 @@
super release.
! !
-!UIGalleryView::Canvas class methodsFor:'documentation'!
+!UIGalleryView::Palette class methodsFor:'documentation'!
documentation
"
- I am the canvas of a gallery. Most of what I do is to allow dragging of widget out
+ I am the palette of a gallery. Most of what I do is to allow dragging of a widget out
of myself and to care for the drawing of the selection.
The arrangement into multiple pages is done by my container, which holds me
in a subcanvas.
"
! !
-!UIGalleryView::Canvas methodsFor:'accessing'!
+!UIGalleryView::Palette methodsFor:'accessing'!
builder
"get the builder used to setup a window from a specification (or nil in case
@@ -390,6 +390,7 @@
(builder := uiBuilder) isNil ifTrue:[
builder := UIBuilder new isEditing:true.
builder showDefaults:true.
+ builder application:self application. "/ for resources like images
].
specification buildViewFor:builder in:self.
@@ -407,7 +408,7 @@
].
! !
-!UIGalleryView::Canvas methodsFor:'building'!
+!UIGalleryView::Palette methodsFor:'building'!
recursiveBuildSpecFromSpecPrototype:aSpec
"build spec out of spec prototype"
@@ -446,7 +447,7 @@
^ spec
! !
-!UIGalleryView::Canvas methodsFor:'drag & drop'!
+!UIGalleryView::Palette methodsFor:'drag & drop'!
startDragFrom:evView
"start drag at lastClickPoint"
@@ -479,7 +480,7 @@
display:nil.
! !
-!UIGalleryView::Canvas methodsFor:'event handling'!
+!UIGalleryView::Palette methodsFor:'event handling'!
processEvent:anEvent
"filter keyboard events.
@@ -543,7 +544,7 @@
^ true
! !
-!UIGalleryView::Canvas methodsFor:'focus handling'!
+!UIGalleryView::Palette methodsFor:'focus handling'!
subviewsInFocusOrder
"returns none views - focus not handled within buildin canvas"
@@ -551,7 +552,7 @@
^ #()
! !
-!UIGalleryView::Canvas methodsFor:'initialization'!
+!UIGalleryView::Palette methodsFor:'initialization'!
destroy
|winGrp|
@@ -580,7 +581,7 @@
].
! !
-!UIGalleryView::Canvas methodsFor:'searching'!
+!UIGalleryView::Palette methodsFor:'searching'!
findObjectAt:aPoint
|seeIfWidgetIsHit p x y|
@@ -624,7 +625,7 @@
"Modified: / 18.5.1999 / 14:47:25 / cg"
! !
-!UIGalleryView::Canvas methodsFor:'selection'!
+!UIGalleryView::Palette methodsFor:'selection'!
handlesOf:aComponent do:aOneArgBlock
"evaluate the block on each handle; the argument to the block is a rectangle"
@@ -729,7 +730,7 @@
].
! !
-!UIGalleryView::Canvas::DropSpec class methodsFor:'instance creation'!
+!UIGalleryView::Palette::DropSpec class methodsFor:'instance creation'!
for:aWidget specification:aSpec
"create drop object for a widget derived from a specification"