From e6d86d7aae06a5b1d1ff9775f8a0248495f1808c Mon Sep 17 00:00:00 2001 From: Offray Luna Date: Sat, 16 Sep 2017 17:10:46 +0000 Subject: [PATCH] GrafoscopioReplace Interface updated. --- .../Grafoscopio/GrafoscopioReplace.class.st | 56 +++++++++++++++++-- 1 file changed, 50 insertions(+), 6 deletions(-) diff --git a/repository/Grafoscopio/GrafoscopioReplace.class.st b/repository/Grafoscopio/GrafoscopioReplace.class.st index 39b7dbe..bbb287e 100644 --- a/repository/Grafoscopio/GrafoscopioReplace.class.st +++ b/repository/Grafoscopio/GrafoscopioReplace.class.st @@ -16,23 +16,67 @@ Class { { #category : #specs } GrafoscopioReplace class >> defaultSpec [ - - SpecColumnLayout composed - add: #find; add: #replace; "add: #ok; add: #cancel;" + ^ SpecLayout composed + newColumn: [ :column | + column + add: #find; + add: #replace; + newRow: [ :row | row add: #ok; add: #cancel ] height: self toolbarHeight ]; yourself ] +{ #category : #accessing } +GrafoscopioReplace >> cancel [ + ^ cancel +] + +{ #category : #accessing } +GrafoscopioReplace >> cancel: anObject [ + cancel := anObject +] + +{ #category : #accessing } +GrafoscopioReplace >> find [ + ^ find +] + +{ #category : #accessing } +GrafoscopioReplace >> find: anObject [ + find := anObject +] + { #category : #initialization } GrafoscopioReplace >> initializeWidgets [ find := self newText. replace := self newText. ok := self newButton - label: 'OK'. + label: 'OK'; + action: [ Transcript show: self find getText ]. cancel := self newButton label: 'Cancel'. self focusOrder add: find; - add: replace"; + add: replace; add: ok; - add: cancel". + add: cancel. +] + +{ #category : #accessing } +GrafoscopioReplace >> ok [ + ^ ok +] + +{ #category : #accessing } +GrafoscopioReplace >> ok: anObject [ + ok := anObject +] + +{ #category : #accessing } +GrafoscopioReplace >> replace [ + ^ replace +] + +{ #category : #accessing } +GrafoscopioReplace >> replace: anObject [ + replace := anObject ]