2011-11-17 10:10:13 +08:00
|
|
|
#ifndef _TEXTURECACHE_TEST_H_
|
|
|
|
#define _TEXTURECACHE_TEST_H_
|
|
|
|
|
2011-11-21 12:04:21 +08:00
|
|
|
|
2011-11-17 10:10:13 +08:00
|
|
|
#include "cocos2d.h"
|
2015-04-03 14:31:03 +08:00
|
|
|
#include "../BaseTest.h"
|
2011-11-17 10:10:13 +08:00
|
|
|
|
2015-04-03 14:31:03 +08:00
|
|
|
DEFINE_TEST_SUITE(TextureCacheTests);
|
|
|
|
|
|
|
|
class TextureCacheTest : public TestCase
|
2011-11-17 10:10:13 +08:00
|
|
|
{
|
|
|
|
public:
|
2015-04-03 14:31:03 +08:00
|
|
|
CREATE_FUNC(TextureCacheTest);
|
|
|
|
|
2012-04-19 14:35:52 +08:00
|
|
|
TextureCacheTest();
|
2015-04-03 14:31:03 +08:00
|
|
|
|
2012-04-19 14:35:52 +08:00
|
|
|
void addSprite();
|
2014-01-02 17:23:00 +08:00
|
|
|
void loadingCallBack(cocos2d::Texture2D *texture);
|
2011-11-17 10:10:13 +08:00
|
|
|
|
2015-04-03 14:31:03 +08:00
|
|
|
virtual float getDuration() const override { return 3.5f; }
|
2011-11-17 10:10:13 +08:00
|
|
|
private:
|
2014-03-26 23:33:58 +08:00
|
|
|
cocos2d::Label *_labelLoading;
|
|
|
|
cocos2d::Label *_labelPercent;
|
2013-06-15 14:03:30 +08:00
|
|
|
int _numberOfSprites;
|
|
|
|
int _numberOfLoadedSprites;
|
2011-11-17 10:10:13 +08:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif // _TEXTURECACHE_TEST_H_
|