added mail events before/after send
added test
doc fix
Using constants instead of literals in Behavior
Removed redundant code in detachBehaviors()

After ensureBehaviors() call $this->_behaviors is an array already.
And since detachBehavior() unsets elements in $this->_behaviors, $this->_behaviors turns out to be an empty array after all iterations.
added default mail config to application.
Fixes #1701.
Merge pull request #1703 from crtlib/patch-2

Removed redundant code in detachBehaviors()
reverted $isValid for events.
end of line fix
Fixed build break.
line fix
Merge pull request #1683 from Ragazzo/mail_event

Mail events before/after
Fixes #1704: Incorrect regexp is used in `Inflector::camelize()`
Merge pull request #1700 from crtlib/patch-1

Using constants instead of literals in Behavior docs
removed duplicated test config.
Small fixes for the sake of consistency
code style fixes
changed default value of Component::_events
Merge pull request #1708 from crtlib/patch-2

Small fixes for the sake of consistency