Constification patch by hendu

git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@4470 dfc29bdd-3216-0410-991c-e03cc46cb475
master
hybrid 2013-03-07 10:16:05 +00:00
parent da59ee303c
commit fce326fdd0
5 changed files with 1048 additions and 1047 deletions

View File

@ -80,7 +80,7 @@ namespace quake3
typedef core::array< video::ITexture* > tTexArray;
// string helper.. TODO: move to generic files
inline s16 isEqual ( const core::stringc &string, u32 &pos, const c8 *list[], u16 listSize )
inline s16 isEqual ( const core::stringc &string, u32 &pos, const c8 * const list[], u16 listSize )
{
const char * in = string.c_str () + pos;
@ -772,7 +772,7 @@ namespace quake3
io::IFileSystem *fileSystem,
video::IVideoDriver* driver)
{
static const char* extension[] =
static const char * const extension[] =
{
".jpg",
".jpeg",

File diff suppressed because it is too large Load Diff

View File

@ -48,9 +48,9 @@ namespace irr
namespace gui
{
const wchar_t* IRR_XML_FORMAT_GUI_ENV = L"irr_gui";
const wchar_t* IRR_XML_FORMAT_GUI_ELEMENT = L"element";
const wchar_t* IRR_XML_FORMAT_GUI_ELEMENT_ATTR_TYPE = L"type";
const wchar_t IRR_XML_FORMAT_GUI_ENV[] = L"irr_gui";
const wchar_t IRR_XML_FORMAT_GUI_ELEMENT[] = L"element";
const wchar_t IRR_XML_FORMAT_GUI_ELEMENT_ATTR_TYPE[] = L"type";
const io::path CGUIEnvironment::DefaultFontName = "#DefaultFont";
@ -168,7 +168,8 @@ CGUIEnvironment::~CGUIEnvironment()
void CGUIEnvironment::loadBuiltInFont()
{
io::IReadFile* file = io::createMemoryReadFile(BuiltInFontData, BuiltInFontDataSize, DefaultFontName, false);
io::IReadFile* file = io::createMemoryReadFile((void *) BuiltInFontData,
BuiltInFontDataSize, DefaultFontName, false);
CGUIFont* font = new CGUIFont(this, DefaultFontName );
if (!font->load(file))

View File

@ -68,7 +68,7 @@ namespace
namespace irr
{
const char* wmDeleteWindow = "WM_DELETE_WINDOW";
const char wmDeleteWindow[] = "WM_DELETE_WINDOW";
//! constructor
CIrrDeviceLinux::CIrrDeviceLinux(const SIrrlichtCreationParameters& param)

View File

@ -1102,7 +1102,7 @@ void CQuake3ShaderSceneNode::animate( u32 stage,core::matrix4 &texture )
const SVariable &v = group->Variable[g];
// get the modifier
static const c8 * modifierList[] =
static const c8 * const modifierList[] =
{
"tcmod","deformvertexes","rgbgen","tcgen","map","alphagen"
};
@ -1124,7 +1124,7 @@ void CQuake3ShaderSceneNode::animate( u32 stage,core::matrix4 &texture )
}
// get the modifier function
static const c8 * funclist[] =
static const c8 * const funclist[] =
{
"scroll","scale","rotate","stretch","turb",
"wave","identity","vertex",
@ -1133,7 +1133,7 @@ void CQuake3ShaderSceneNode::animate( u32 stage,core::matrix4 &texture )
"exactvertex","const","lightingspecular","move","normal",
"identitylighting"
};
static const c8 * groupToken[] = { "(", ")" };
static const c8 * const groupToken[] = { "(", ")" };
pos = 0;
function.masterfunc1 = (eQ3ModifierFunction) isEqual( v.content, pos, funclist, 22 );