WindowSensor.st
changeset 7508 f581795812b9
parent 7468 6cc4f99397af
child 7542 9e125aa140f9
child 7664 aed121ae9902
equal deleted inserted replaced
7507:cb7c25da60d0 7508:f581795812b9
  2918      Type is the type of event, dType the corresponding device event.
  2918      Type is the type of event, dType the corresponding device event.
  2919      If the argument, aView is nil, the information is regarding any
  2919      If the argument, aView is nil, the information is regarding any
  2920      view (i.e. is there an event for any of my views);
  2920      view (i.e. is there an event for any of my views);
  2921      otherwise, the information is regarding to that specific view."
  2921      otherwise, the information is regarding to that specific view."
  2922 
  2922 
       
  2923     |device|
       
  2924 
  2923     "/ look in my queues
  2925     "/ look in my queues
  2924     (self hasEvent:type for:aView) ifTrue:[^ true].
  2926     (self hasEvent:type for:aView) ifTrue:[^ true].
  2925 
  2927 
  2926     aView notNil ifTrue:[
  2928     aView notNil ifTrue:[
  2927         "/ ask the device if it has something pending
  2929         (device := aView graphicsDevice) notNil ifTrue:[
  2928         ^ aView graphicsDevice eventPending:dType for:aView id
  2930             "/ ask the device if it has something pending
       
  2931             ^ device eventPending:dType for:aView id
       
  2932         ].
  2929     ].
  2933     ].
  2930     ^ false
  2934     ^ false
  2931 
  2935 
  2932     "Modified: / 10.6.1998 / 17:34:51 / cg"
  2936     "Modified: / 10.6.1998 / 17:34:51 / cg"
  2933 !
  2937 !