Refactor OvaleData module.

- Move the spellbook/talent/glyph-handling to a new module OvaleSpellBook.

- Move methods closer to the place where they are mostly used:
  - :GetTickLength() moved to OvaleAura.
  - :GetDuration() moved to OvaleState, with simplifications.

- Simplify OvaleData into a module without dependencies that can be used
  as a global data store for other modules where needed.

git-svn-id: svn+ssh://svn.curseforge.net/wow/ovale/mainline/trunk@1034 d5049fe3-3747-40f7-a4b5-f36d6801af5f
Refactor power code into a new module OvalePower.

- Split out power code from OvalePaperDoll and OvaleData into a separate
  module OvalePower.

- Enhance power code to track the maximum power of all power types.

- Add conditions Max<Power>() that return the maximum power of that power
  type, e.g., MaxRage, MaxEnergy, MaxChi, etc.  This closes ticket 291.

git-svn-id: svn+ssh://svn.curseforge.net/wow/ovale/mainline/trunk@1035 d5049fe3-3747-40f7-a4b5-f36d6801af5f
Fix ticket 296 - Ovale double deducting for energy cost

Only apply the power cost of the spell if the spellcast hasn't already
finished.  A spellcast that has finished in-game has already had the power
adjusted, which would be picked up when :Reset() is called to reset the
frame state.

Also, make this more readable by splitting out code from :ApplySpell()
method to update the power state into a new method :ApplySpellCost().

git-svn-id: svn+ssh://svn.curseforge.net/wow/ovale/mainline/trunk@1036 d5049fe3-3747-40f7-a4b5-f36d6801af5f
Fix ticket 287 - IsFriend() doesn't work correctly

Fix copy and paste error that was causing the IsFriend() condition to
incorrectly return whether the target was flagged for PvP.

Analysis and fix by @Xeltor.

git-svn-id: svn+ssh://svn.curseforge.net/wow/ovale/mainline/trunk@1037 d5049fe3-3747-40f7-a4b5-f36d6801af5f
Fix ticket 246 - Option to disable in pet battles

Instead of an option, always hide Ovale when the Pet Battle UI is active.
This should match player expectations.

git-svn-id: svn+ssh://svn.curseforge.net/wow/ovale/mainline/trunk@1038 d5049fe3-3747-40f7-a4b5-f36d6801af5f