Class: Sketchup::DefinitionObserver Abstract
- Inherits:
-
EntityObserver
- Object
- EntityObserver
- Sketchup::DefinitionObserver
Overview
To implement this observer, create a Ruby class of this type, override the desired methods, and add an instance of the observer to the definitions of interests.
This observer interface is implemented to react to component definition events.
Instance Method Summary # collapse
-
#onComponentInstanceAdded(definition, instance) ⇒ nil
The #onComponentInstanceAdded method is called when a new component instance is added to a model.
-
#onComponentInstanceRemoved(definition, instance) ⇒ nil
The #onComponentInstanceRemoved method is called when a component instance is removed from a model.
Methods inherited from EntityObserver
#onChangeEntity, #onEraseEntity
Instance Method Details
↑ #onComponentInstanceAdded(definition, instance) ⇒ nil
The #onComponentInstanceAdded method is called when a new component instance is added to a model.
↑ #onComponentInstanceRemoved(definition, instance) ⇒ nil
Due to the underlying way that the SketchUp Move Tool is implemented, this method is fired on a Move + Copy operation even though no ComponentInstance is apparently removed.
The #onComponentInstanceRemoved method is called when a component instance is removed from a model.