[squeak-dev] ProvideAnswerNotification and UIManager
Patrick.Rein at hpi.de
Tue Jul 10 09:28:14 UTC 2018
recently I noticed that the method BlockClosure>>valueSupplyingAnswer: (and related ones) do
not work on all method of UIManager. When I looked into the issue I noticed that the signaling of
ProvideAnswerNotification is not done in the UIManagers but in the classes implementing the
actual user interfaces for the corresponding queries (e.g. MenuMorph and PopUpMenu). This
scattered the ProvideAnswerNotification logic throughout different packages and classes and
might have lead to the oversights.
The attached changeset is a refactoring of this mechanism which moves the corresponding
logic into the UIManagers. Unfortunately, this required some code duplication but at least it is
contained with the UIManager. On the plus side the code is contained in the UIManagers and
all methods should be covered now.
As I am not very familiar with the original intend and responsibilities of the UIManagers I wanted
to ask whether anyone has any thoughts on that change.
Thanks and bests
P.S.: There are other minor changes related to the refactoring in the changeset such as extending
the BlockClosureTests to test all UIManager subclasses
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
More information about the Squeak-dev