Great idea Miguel. I believe this will not only work just fine, but will allow models in Pharo which reference the "Sensor" (something I doubt has ever happened, or ever will) to persist and materialize properly. *Provided*, that, in Pharo:
Sensor class = InputEventSensor answers "true", which I'm assuming it does (can't launch a Pharo image at the moment to be sure). - Chris 2010/1/12 Miguel Enrique Cobá Martinez <[email protected]>: > I have a question about EventSensor. > > In Pharo doesn't exists anymore, it was replaced by InputEventSensor > that has this class comment: > > An InputEventSensor is a replacement for the old Morphic EventSensor > framework. > It updates its state when events are received so that all state based > users of Sensor (e.g., Sensor keyboard, Sensor leftShiftDown, Sensor > mouseButtons) will work exactly as before. The usage of these funtions > is discouraged. > > I am installing Magma on a Pharo core image and Magma uses EventSensor, > by adding some methods to this class. As the class doesn't exist it > shows the following message: > > This package depends on the following classes: > EventSensor > You must resolve these dependencies before you will be able to load > these definitions: > EventSensor classSide>>maMaterializeFromGraph:using: > EventSensor>>maAsStorageObject > EventSensor>>maUsesStandardStorage > > > Select Proceed to continue, or close this window to cancel the > operation. > > If before loading Magma I do > > Smalltalk at: #EventSensor put: InputEventSensor. > > Then everything works without warnings. Also the InputEventSensor > receives the methods added by Magma. > > My questions are: > > Is this valid? > Must this (the InputEventSensor in the slot of EventSensor in Smalltalk) > be part of the image or will be a regresion to the situation before the > deletion of EventSensor? > What will be the correct way to handle this, change the Pharo/PharoCore > with my hack or to ask Chris Muller, the maintainer of Magma to not use > EventSensor but InputEvenSensor in the case of Pharo/PharoCore? > > Can I be reminded of the reasons to drop EventSensor in favor of > InputEvenSensor? > > Thanks for the answers > -- > Miguel Cobá > http://miguel.leugim.com.mx > > > _______________________________________________ > Pharo-project mailing list > [email protected] > http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project _______________________________________________ Pharo-project mailing list [email protected] http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
