Xavier Arias wrote:
We could also use a shorter name for cc::extension, don’t you think?
You could use namespace alias to achieve that.
namespace cc = cocos2d; will work for you.
Xavier Arias wrote:
We could also use a shorter name for cc::extension, don’t you think?
You could use namespace alias to achieve that.
namespace cc = cocos2d; will work for you.
Éloi Rivard wrote:
This is great !
I notice that there is no CCDeprecated.h in extensions. Do you think it is a good idea to keep (and deprecate) CC prefix compatibility with extensions too ?
Done in the develop branch.
James Chen wrote:
Xavier Arias wrote:
> We could also use a shorter name for cc::extension, don’t you think?
>
You could use namespace alias to achieve that.
namespace cc = cocos2d; will work for you.
Good that there’s the 2 options, but I was talking about the extension namespace there, haha.
We could call it ext or something like that.
Example:
cc::ext::ScrollView
It’s easy too, you could
namespace cocos2d {
namespace ext = extension;
}
Xavier Arias wrote:
James Chen wrote:
> Xavier Arias wrote:
> > We could also use a shorter name for cc::extension, don’t you think?
>
> You could use namespace alias to achieve that.
> namespace cc = cocos2d; will work for you.
>
Good that there’s the 2 options, but I was talking about the extension namespace there, haha.
We could call it ext or something like that.
>
Example:
cc::ext::ScrollView
My 2p: Keep the namespace the same and let people alias it to a smaller one if they want instead of forcing it and making people alias it back. Cocos2d is clearer and makes for more maintainable code.
Another reason for ‘no changing’ is: all tutorials have to be adapt too
Yep, we have done it like that ,kept the namespace ‘cocos2d’. Thanks all your advices.
Adam Legge wrote:
My 2p: Keep the namespace the same and let people alias it to a smaller one if they want instead of forcing it and making people alias it back. Cocos2d is clearer and makes for more maintainable code.
Hate to remove the CC prefix