Fix 2 issues with new-line.

— Apply patch from @glazedkoala. Fix the issue where Label is reused
with new-string being smaller than previous one. With fix character is
not displaced any more.

— _width logic was broken for long time. If CCLabelBMFont is created
with some width say N, then expectation is to see new-line once string
is out-of bound.
     This effect is more visible where user is updating label
dynamically (like appending single character)
CCEffects - Refactor CCEffectRenderPass

CCEffectRenderPass was serving two purposes: 1) To pass static information to the effect renderer and 2) To receive information
from the renderer and convey it to the begin, update, and end blocks.  This dual purpose "I'm an input and an output" business was
starting to get a little hard to keep track of so I'm busting it up into two classes: CCEffectRenderPass is the static stuff that the effect
is passing to the renderer. CCEffectRenderPassInputs is the stuff that the renderer is passing to the effect's blocks.
CCEffects - Refactor effects into CCEffect and CCEffectImpl

This is something we've thought about for a while as a way to enable different
implementations as optimizations but I'm doing it now in preparation for adding
Metal support.

With this change, the functions, uniforms, varyings, and render passes all move
into CCEffectImpl subclass (or really an effect specific subclass of CCEffectImpl)
while the public initializers, convenience constructors, and properties all stay in
the CCEffect subclass.

For now, initializing an effect instance immediately creates the corresponding
effect implementation instance and the implementation does not change for the
lifetime of the effect.  This need not always be the case though and it is possible
to switch the implementation dynamically based on effect property values.

For example, the bloom effect currently has a conditional in its shader based on the
luminance threshold value. If the threshold is 0.0 or 1.0 though, we could select
a different implementation where the condition is replaced with the hardcoded
pass or fail path as an optimization.
Merge branch 'v3.3' into develop
CCEffects - Rework the distance field and lighting effects to CCEffectImpl
CCEffectsTest - Re-enable the distance field tests
CCEffects - Simplify the CCEffectImpl initialization flow

Prior to these changes, an effect subclass called one of several initializers on CCEffectImpl of the
form:

initWithArg:arg
initWithArg:arg blarg:blarg
initWithArg:arg blarg:blarg flarg:flarg

Which all chained to the designated initializer (in this example, initWithArg: blarg: flarg:). The designated
initializer then did the following:

if (!arg) [self buildArg];
if (!blarg) [selfBuildBlarg];
if (!flarg) [selfBuildFlarg];

And subclasses could opt to override these builder methods. Instead of this sub-class calling
the super-class and the super-class calling back to the sub-class arrangement, remove all but
the designated super-class initializer and require sub-classes to use it. Also remove the overridable
builder methods from the super-class so the sub-class must supply all required initializer arguments
instead of not supplying them and instead creating them in the overridden builder methods.

This makes the super-class initializer call more verbose but it makes the overall flow more
straightforward. It also addresses potential initialization order problems with overridden builder
methods being called on the sub-class before the sub-class's initializer body could execute.

There is one remaining issue with the render pass blocks capturing self before self is assigned
by the call to the super-class initializer but I will fix that next.
CCEffects - Move the uniform translation table to CCEffectRenderPass

This is so the render pass blocks get the translation table from the render pass instead of
having to capture self when they are created.
Merge pull request #1069 from NickyWeber/bugfix/package_persistency_ios

Bugfix/package persistency ios and more
CCEffects - Stop capturing self in the render pass blocks

Because the blocks are constructed prior to calling (self = [super init]) we shouldn't
capture self in them. Instead, capture the owning interface class weakly.
Merge branch 'develop' into metal/effects1-RenderPassRefactor

Conflicts:
	cocos2d/CCEffectLighting.m
Merge branch 'metal/effects1-RenderPassRefactor' into metal/effects2-EffectImpl
Merge branch 'metal/effects2-EffectImpl' into metal/effects3-InitializerCleanup

Conflicts:
	cocos2d/CCEffectLighting.m
CCEffects - Fix initialization of conditioned ivars
Fixes warning and errors in Mac target
Fixes warnings in Mac target
Updates the version number
Merge branch 'develop' into metalPrep/Step1-RenderPassRefactor
Merge branch 'metalPrep/Step1-RenderPassRefactor' into metalPrep/Step2-EffectImpl
CCEffectLighting - Build fix after latest merge from upstream

passInputs.node becomes passInputs.sprite.