Module: IronNails::Models::Databinding
- Defined in:
- lib/ironnails/models/model_mixin.rb
Defined Under Namespace
Modules: ClassMethods
Class Method Summary collapse
-
.included(base) ⇒ Object
extend the class with the class methods defined in this module.
Instance Method Summary collapse
Class Method Details
.included(base) ⇒ Object
extend the class with the class methods defined in this module
40 41 42 43 |
# File 'lib/ironnails/models/model_mixin.rb', line 40 def self.included(base) base.send :include, System::ComponentModel::INotifyPropertyChanged unless base.ancestors.include? System::ComponentModel::INotifyPropertyChanged base.extend ClassMethods end |
Instance Method Details
#add_PropertyChanged(handler = nil) ⇒ Object
45 46 47 48 |
# File 'lib/ironnails/models/model_mixin.rb', line 45 def add_PropertyChanged(handler=nil) @__handlers__ ||= [] @__handlers__ << handler end |
#remove_PropertyChanged(handler = nil) ⇒ Object
50 51 52 53 |
# File 'lib/ironnails/models/model_mixin.rb', line 50 def remove_PropertyChanged(handler=nil) @__handlers__ ||= [] @__handlers__.delete handler end |