Changed: #825 object_viewer warnings
This commit is contained in:
parent
3bf713f884
commit
cef50abdb7
12 changed files with 21 additions and 126 deletions
|
@ -1,12 +1,5 @@
|
|||
FILE(GLOB SRC *.cpp *.h)
|
||||
|
||||
LIST(REMOVE_ITEM SRC ${CMAKE_CURRENT_SOURCE_DIR}/std_afx2.h
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/std_afx2.cpp)
|
||||
ENABLE_LANGUAGE(RC)
|
||||
|
||||
ADD_DEFINITIONS(-D_AFXDLL)
|
||||
SET(CMAKE_MFC_FLAG 2)
|
||||
|
||||
ADD_LIBRARY(object_viewer_dll SHARED ${SRC} object_viewer.rc)
|
||||
|
||||
INCLUDE_DIRECTORIES(${LIBXML2_INCLUDE_DIR})
|
||||
|
@ -22,7 +15,11 @@ NL_DEFAULT_PROPS(object_viewer_dll "NeL, Tools, 3D: Object Viewer DLL")
|
|||
NL_ADD_RUNTIME_FLAGS(object_viewer_dll)
|
||||
NL_ADD_LIB_SUFFIX(object_viewer_dll)
|
||||
|
||||
ADD_DEFINITIONS(${LIBXML2_DEFINITIONS} -DOBJECT_VIEWER_LIB_EXPORTS)
|
||||
ADD_DEFINITIONS(${LIBXML2_DEFINITIONS} ${MFC_DEFINITIONS} -DOBJECT_VIEWER_LIB_EXPORTS)
|
||||
|
||||
IF(WITH_PCH)
|
||||
ADD_NATIVE_PRECOMPILED_HEADER(object_viewer_dll ${CMAKE_CURRENT_SOURCE_DIR}/std_afx.h ${CMAKE_CURRENT_SOURCE_DIR}/std_afx.cpp)
|
||||
ENDIF(WITH_PCH)
|
||||
|
||||
INSTALL(TARGETS object_viewer_dll LIBRARY DESTINATION lib RUNTIME DESTINATION bin ARCHIVE DESTINATION lib COMPONENT tools3d)
|
||||
INSTALL(FILES object_viewer.cfg DESTINATION bin COMPONENT tools3d)
|
||||
|
|
|
@ -424,7 +424,7 @@ void CAnimationSetDlg::OnListUp()
|
|||
// Backup the string
|
||||
CString text;
|
||||
PlayList.GetText (sel, text);
|
||||
DWORD data = PlayList.GetItemData (sel);
|
||||
DWORD_PTR data = PlayList.GetItemData (sel);
|
||||
|
||||
// Remove the node
|
||||
PlayList.DeleteString (sel);
|
||||
|
@ -450,7 +450,7 @@ void CAnimationSetDlg::OnListDown()
|
|||
// Backup the string
|
||||
CString text;
|
||||
PlayList.GetText (sel, text);
|
||||
DWORD data = PlayList.GetItemData (sel);
|
||||
DWORD_PTR data = PlayList.GetItemData (sel);
|
||||
|
||||
// Remove the node
|
||||
PlayList.DeleteString (sel);
|
||||
|
|
|
@ -71,7 +71,7 @@ BOOL CBinOpDlg::OnInitDialog()
|
|||
void CBinOpDlg::OnSelchangeBinOp()
|
||||
{
|
||||
UpdateData() ;
|
||||
newOp(m_BinOp.GetItemData(m_BinOp.GetCurSel())) ;
|
||||
newOp((uint32)m_BinOp.GetItemData(m_BinOp.GetCurSel())) ;
|
||||
}
|
||||
|
||||
void CBinOpDlg::OnClose()
|
||||
|
|
|
@ -50,7 +50,7 @@ static T *DupSerializable(const T *in) throw(NLMISC::EStream)
|
|||
std::copy(ms.buffer(), ms.buffer() + ms.length(), datas.begin());
|
||||
ms.resetPtrTable();
|
||||
ms.invert();
|
||||
ms.fill(&datas[0], datas.size());
|
||||
ms.fill(&datas[0], (uint32)datas.size());
|
||||
nlassert(ms.isReading());
|
||||
T *newObj = NULL;
|
||||
TSerializePolicy::serial(newObj, ms);
|
||||
|
|
|
@ -130,9 +130,9 @@ void CEditMorphMeshDlg::OnAdd()
|
|||
std::vector<std::string> shapeNames;
|
||||
shapeNames.resize(_CM->getNumShapes() + 1);
|
||||
_CM->getShapesNames(&shapeNames[0]);
|
||||
uint index = shapeNames.size() - 1;
|
||||
uint index = (uint)shapeNames.size() - 1;
|
||||
shapeNames[index] = shapeName;
|
||||
_CM->setShapes(&shapeNames[0], shapeNames.size());
|
||||
_CM->setShapes(&shapeNames[0], (uint)shapeNames.size());
|
||||
std::vector<sint> numVerts;
|
||||
_CM->getShapeNumVerts(numVerts);
|
||||
m_MeshList.AddString(getShapeDescStr(index, numVerts[index]).c_str());
|
||||
|
@ -151,7 +151,7 @@ void CEditMorphMeshDlg::OnRemove()
|
|||
shapeNames.resize(_CM->getNumShapes());
|
||||
_CM->getShapesNames(&shapeNames[0]);
|
||||
shapeNames.erase(shapeNames.begin() + selItem);
|
||||
_CM->setShapes(&shapeNames[0], shapeNames.size());
|
||||
_CM->setShapes(&shapeNames[0], (uint)shapeNames.size());
|
||||
if (_CM->getNumShapes() == 2)
|
||||
{
|
||||
GetDlgItem(IDC_REMOVE)->EnableWindow(FALSE);
|
||||
|
@ -172,7 +172,7 @@ void CEditMorphMeshDlg::OnInsert()
|
|||
shapeNames.resize(_CM->getNumShapes());
|
||||
_CM->getShapesNames(&shapeNames[0]);
|
||||
shapeNames.insert(shapeNames.begin() + selItem, shapeName);
|
||||
_CM->setShapes(&shapeNames[0], shapeNames.size());
|
||||
_CM->setShapes(&shapeNames[0], (uint)shapeNames.size());
|
||||
GetDlgItem(IDC_REMOVE)->EnableWindow(TRUE);
|
||||
touchPSState();
|
||||
updateMeshList();
|
||||
|
@ -190,7 +190,7 @@ void CEditMorphMeshDlg::OnUp()
|
|||
shapeNames.resize(_CM->getNumShapes());
|
||||
_CM->getShapesNames(&shapeNames[0]);
|
||||
std::swap(shapeNames[selItem - 1], shapeNames[selItem]);
|
||||
_CM->setShapes(&shapeNames[0], shapeNames.size());
|
||||
_CM->setShapes(&shapeNames[0], (uint)shapeNames.size());
|
||||
GetDlgItem(IDC_REMOVE)->EnableWindow(TRUE);
|
||||
updateMeshList();
|
||||
m_MeshList.SetCurSel(selItem - 1);
|
||||
|
@ -206,7 +206,7 @@ void CEditMorphMeshDlg::OnDown()
|
|||
shapeNames.resize(_CM->getNumShapes());
|
||||
_CM->getShapesNames(&shapeNames[0]);
|
||||
std::swap(shapeNames[selItem + 1], shapeNames[selItem]);
|
||||
_CM->setShapes(&shapeNames[0], shapeNames.size());
|
||||
_CM->setShapes(&shapeNames[0], (uint)shapeNames.size());
|
||||
GetDlgItem(IDC_REMOVE)->EnableWindow(TRUE);
|
||||
updateMeshList();
|
||||
m_MeshList.SetCurSel(selItem + 1);
|
||||
|
|
|
@ -292,7 +292,7 @@ void CLocatedProperties::OnEditTriggerOnDeath()
|
|||
{
|
||||
UpdateData();
|
||||
CLBExternIDDlg dlg(_Located->getTriggerEmitterID());
|
||||
int res = dlg.DoModal();
|
||||
INT_PTR res = dlg.DoModal();
|
||||
if ( res == IDOK )
|
||||
{
|
||||
if (dlg.getNewID() != _Located->getTriggerEmitterID())
|
||||
|
|
|
@ -55,7 +55,7 @@ void CSchemeManager::serial(NLMISC::IStream &f) throw(NLMISC::EStream)
|
|||
f.serialVersion(1);
|
||||
if (!f.isReading())
|
||||
{
|
||||
sint32 size = _SchemeMap.size();
|
||||
sint32 size = (sint32)_SchemeMap.size();
|
||||
f.serial(size);
|
||||
for (TSchemeMap::iterator smIt = _SchemeMap.begin(); smIt != _SchemeMap.end(); ++smIt)
|
||||
{
|
||||
|
|
|
@ -1056,7 +1056,7 @@ void CSkeletonScaleDlg::refreshSaveButton()
|
|||
sint CSkeletonScaleDlg::getBoneForMirror(uint boneId, std::string &mirrorName)
|
||||
{
|
||||
sint side= 0;
|
||||
sint pos;
|
||||
std::string::size_type pos;
|
||||
nlassert(_SkeletonModel && boneId<_SkeletonModel->Bones.size());
|
||||
mirrorName= _SkeletonModel->Bones[boneId].getBoneName();
|
||||
|
||||
|
|
|
@ -1,18 +0,0 @@
|
|||
// NeL - MMORPG Framework <http://dev.ryzom.com/projects/nel/>
|
||||
// Copyright (C) 2010 Winch Gate Property Limited
|
||||
//
|
||||
// This program is free software: you can redistribute it and/or modify
|
||||
// it under the terms of the GNU Affero General Public License as
|
||||
// published by the Free Software Foundation, either version 3 of the
|
||||
// License, or (at your option) any later version.
|
||||
//
|
||||
// This program is distributed in the hope that it will be useful,
|
||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
// GNU Affero General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU Affero General Public License
|
||||
// along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
#include "std_afx2.h"
|
||||
|
|
@ -1,84 +0,0 @@
|
|||
// NeL - MMORPG Framework <http://dev.ryzom.com/projects/nel/>
|
||||
// Copyright (C) 2010 Winch Gate Property Limited
|
||||
//
|
||||
// This program is free software: you can redistribute it and/or modify
|
||||
// it under the terms of the GNU Affero General Public License as
|
||||
// published by the Free Software Foundation, either version 3 of the
|
||||
// License, or (at your option) any later version.
|
||||
//
|
||||
// This program is distributed in the hope that it will be useful,
|
||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
// GNU Affero General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU Affero General Public License
|
||||
// along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
|
||||
#if !defined(AFX_STDAFX2_H__9B22CB86_1929_11D5_9CD4_0050DAC3A412__INCLUDED_)
|
||||
#define AFX_STDAFX2_H__9B22CB86_1929_11D5_9CD4_0050DAC3A412__INCLUDED_
|
||||
|
||||
#if _MSC_VER > 1000
|
||||
#pragma once
|
||||
#endif // _MSC_VER > 1000
|
||||
|
||||
#define VC_EXTRALEAN // Exclude rarely-used stuff from Windows headers
|
||||
|
||||
#include <afxwin.h> // MFC core and standard components
|
||||
#include <afxext.h> // MFC extensions
|
||||
|
||||
#ifndef _AFX_NO_OLE_SUPPORT
|
||||
#include <afxole.h> // MFC OLE classes
|
||||
#include <afxodlgs.h> // MFC OLE dialog classes
|
||||
#include <afxdisp.h> // MFC Automation classes
|
||||
#endif // _AFX_NO_OLE_SUPPORT
|
||||
|
||||
|
||||
#ifndef _AFX_NO_DB_SUPPORT
|
||||
#include <afxdb.h> // MFC ODBC database classes
|
||||
#endif // _AFX_NO_DB_SUPPORT
|
||||
|
||||
#ifndef _AFX_NO_DAO_SUPPORT
|
||||
#include <afxdao.h> // MFC DAO database classes
|
||||
#endif // _AFX_NO_DAO_SUPPORT
|
||||
|
||||
#include <afxdtctl.h> // MFC support for Internet Explorer 4 Common Controls
|
||||
#ifndef _AFX_NO_AFXCMN_SUPPORT
|
||||
#include <afxcmn.h> // MFC support for Windows Common Controls
|
||||
#endif // _AFX_NO_AFXCMN_SUPPORT
|
||||
|
||||
|
||||
//#include "resource.h"
|
||||
|
||||
#include "nel/misc/common.h"
|
||||
#include "nel/misc/stream.h"
|
||||
#include "nel/misc/vector.h"
|
||||
#include "nel/misc/matrix.h"
|
||||
|
||||
#include "3d/particle_system.h"
|
||||
#include "3d/ps_located.h"
|
||||
#include "3d/ps_particle.h"
|
||||
#include "3d/ps_force.h"
|
||||
#include "3d/ps_emitter.h"
|
||||
#include "3d/ps_zone.h"
|
||||
|
||||
|
||||
#include <vector>
|
||||
#include <map>
|
||||
#include <algorithm>
|
||||
|
||||
#include "animation_dlg.h"
|
||||
#include "animation_set_dlg.h"
|
||||
#include "main_dlg.h"
|
||||
#include "object_viewer.h"
|
||||
#include "object_viewer_interface.h"
|
||||
#include "select_string.h"
|
||||
|
||||
|
||||
|
||||
|
||||
//{{AFX_INSERT_LOCATION}}
|
||||
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
|
||||
|
||||
#endif // !defined(AFX_STDAFX_H__9B22CB86_1929_11D5_9CD4_0050DAC3A412__INCLUDED_)
|
||||
|
|
@ -200,7 +200,7 @@ uint32 CWaterPoolEditor::getCurrentPoolID()
|
|||
{
|
||||
UpdateData();
|
||||
nlassert(m_PoolList.GetCurSel() != LB_ERR); // must always have something selected
|
||||
return m_PoolList.GetItemData(m_PoolList.GetCurSel());
|
||||
return (uint32)m_PoolList.GetItemData(m_PoolList.GetCurSel());
|
||||
}
|
||||
|
||||
//===================================================================
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
FILE(GLOB SRC *.cpp *.h)
|
||||
|
||||
ENABLE_LANGUAGE(RC)
|
||||
ADD_DEFINITIONS(-D_AFXDLL)
|
||||
ADD_DEFINITIONS(${MFC_DEFINITIONS})
|
||||
SET(CMAKE_MFC_FLAG 2)
|
||||
ADD_EXECUTABLE(object_viewer WIN32 ${SRC} object_viewer_exe.rc)
|
||||
|
||||
|
|
Loading…
Reference in a new issue