Commit 6de93ff844eb1e1fb599fa0c25bb217dfeca017e

Clarifying documentation of when controller/view load methods are invoked. Ensured model is instantiated before model.

Commit diff

lib/monkeybars/controller.rb

 
210210 end
211211
212212 def initialize
213 @__view = create_new_view unless self.class.view_class.nil?
214213 @__model = create_new_model unless self.class.model_class.nil?
214 @__view = create_new_view unless self.class.view_class.nil?
215215 @__transfer = {}
216216 @__nested_controllers = {}
217217 @__view_state = nil
toggle raw diff

lib/monkeybars/view.rb

 
396396 end
397397
398398 # Stub to be overriden in sub-class. This is where you put the code you would
399 # normally put in initialize, it will be called whenever a new class is instantiated
399 # normally put in initialize. Load will be called whenever a new class is instantiated
400 # which happens when the Controller's instance method is called on a non-instantiated
401 # controller. Thus this method will always be called before the Controller's
402 # load method (which is called during Controlller#open).
400403 def load; end
401404
402405 # Stub to be overriden in sub-class. This is called whenever the view is closed.
toggle raw diff