Skip to content

Commit

Permalink
Merge pull request #1639 from hernanmd/add-p13-helpers
Browse files Browse the repository at this point in the history
Add helper method to setup the filtering list header title
  • Loading branch information
jecisc authored Nov 12, 2024
2 parents 5d75805 + 74567f6 commit f3e248d
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 5 deletions.
7 changes: 7 additions & 0 deletions src/Spec2-CommonWidgets/SpFilteringListPresenter.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,13 @@ SpFilteringListPresenter >> filterText [
^ self filterInputPresenter text
]

{ #category : 'api' }
SpFilteringListPresenter >> headerTitle: aString [
"Set the receiver's header title to aString"

listPresenter headerTitle: aString
]

{ #category : 'initialization' }
SpFilteringListPresenter >> initializePresenters [

Expand Down
10 changes: 5 additions & 5 deletions src/Spec2-Examples/SpFilteringListPresenter.extension.st
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@ SpFilteringListPresenter class >> example [
<sampleInstance>
| example |
example := self new.
example items: RBBrowserEnvironment default classes asArray.
example open.
example withWindowDo: [ :window |
window title: self name asString , ' example' ].

example
items: RBBrowserEnvironment default classes asArray;
headerTitle: 'Classes';
open;
withWindowDo: [ :window | window title: self name asString , ' example' ].
^ example
]

Expand Down

0 comments on commit f3e248d

Please sign in to comment.