Changed: Memory leaks detection

--HG--
branch : develop
This commit is contained in:
kervala 2016-12-04 15:14:10 +01:00
parent 71c963af36
commit b7e3e4b4f0
122 changed files with 493 additions and 11 deletions

View file

@ -36,6 +36,9 @@
using namespace std; using namespace std;
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif

View file

@ -61,6 +61,9 @@ void (*nglGetProcAddress(const char *procName))()
} }
#endif // NL_OS_WINDOWS #endif // NL_OS_WINDOWS
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
// *************************************************************************** // ***************************************************************************
// The exported function names // The exported function names

View file

@ -33,6 +33,10 @@
using namespace std; using namespace std;
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NL3D { namespace NL3D {
#ifdef NL_STATIC #ifdef NL_STATIC

View file

@ -19,6 +19,10 @@
#include "driver_opengl.h" #include "driver_opengl.h"
#include "nel/3d/light.h" #include "nel/3d/light.h"
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NL3D { namespace NL3D {
#ifdef NL_STATIC #ifdef NL_STATIC

View file

@ -21,6 +21,10 @@
#include "nel/3d/texture_bump.h" #include "nel/3d/texture_bump.h"
#include "nel/3d/material.h" #include "nel/3d/material.h"
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NL3D { namespace NL3D {
#ifdef NL_STATIC #ifdef NL_STATIC

View file

@ -17,6 +17,10 @@
#include "stdopengl.h" #include "stdopengl.h"
#include "driver_opengl.h" #include "driver_opengl.h"
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NL3D { namespace NL3D {
#ifdef NL_STATIC #ifdef NL_STATIC

View file

@ -38,6 +38,10 @@
using namespace std; using namespace std;
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NL3D namespace NL3D
{ {

View file

@ -22,6 +22,10 @@
// define it For Debug purpose only. Normal use is to hide this line // define it For Debug purpose only. Normal use is to hide this line
//#define NL3D_GLSTATE_DISABLE_CACHE //#define NL3D_GLSTATE_DISABLE_CACHE
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NL3D { namespace NL3D {
#ifdef NL_STATIC #ifdef NL_STATIC

View file

@ -28,6 +28,9 @@
using namespace NLMISC; using namespace NLMISC;
using namespace std; using namespace std;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
//#define NEL_DUMP_UPLOAD_TIME //#define NEL_DUMP_UPLOAD_TIME

View file

@ -21,6 +21,10 @@
using namespace std; using namespace std;
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NL3D { namespace NL3D {
#ifdef NL_STATIC #ifdef NL_STATIC

View file

@ -26,6 +26,9 @@
using namespace std; using namespace std;
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif

View file

@ -24,6 +24,10 @@
using namespace std; using namespace std;
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NL3D { namespace NL3D {
#ifdef NL_STATIC #ifdef NL_STATIC

View file

@ -28,6 +28,10 @@
using namespace std; using namespace std;
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
//#define DEBUG_SETUP_EXT_VERTEX_SHADER //#define DEBUG_SETUP_EXT_VERTEX_SHADER
namespace NL3D { namespace NL3D {

View file

@ -44,6 +44,10 @@
using namespace std; using namespace std;
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NL3D { namespace NL3D {
#ifdef NL_STATIC #ifdef NL_STATIC

View file

@ -17,7 +17,12 @@
#ifndef STDOPENGL_H #ifndef STDOPENGL_H
#define STDOPENGL_H #define STDOPENGL_H
#include "nel/misc/types_nl.h" #if defined(_MSC_VER) && defined(_DEBUG)
#define _CRTDBG_MAP_ALLOC
#include <stdlib.h>
#include <crtdbg.h>
#define DEBUG_NEW new(_NORMAL_BLOCK, __FILE__, __LINE__)
#endif
#include <cstdlib> #include <cstdlib>
#include <cstdio> #include <cstdio>
@ -35,6 +40,8 @@
#include <deque> #include <deque>
#include <limits> #include <limits>
#include "nel/misc/types_nl.h"
#ifdef NL_OS_WINDOWS #ifdef NL_OS_WINDOWS
# define WIN32_LEAN_AND_MEAN # define WIN32_LEAN_AND_MEAN
# ifndef NL_COMP_MINGW # ifndef NL_COMP_MINGW

View file

@ -26,6 +26,9 @@
#include <X11/XKBlib.h> #include <X11/XKBlib.h>
#include "nel/misc/debug.h" #include "nel/misc/debug.h"
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
typedef bool (*x11Proc)(NL3D::IDriver *drv, XEvent *e); typedef bool (*x11Proc)(NL3D::IDriver *drv, XEvent *e);

View file

@ -25,6 +25,9 @@
using namespace NLMISC; using namespace NLMISC;
using namespace std; using namespace std;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NL3D namespace NL3D
{ {

View file

@ -28,6 +28,9 @@
using namespace std; using namespace std;
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NL3D namespace NL3D
{ {

View file

@ -14,7 +14,15 @@
// You should have received a copy of the GNU Affero General Public License // 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/>. // along with this program. If not, see <http://www.gnu.org/licenses/>.
#include "nel/misc/types_nl.h" #ifndef NL_STD3D_H
#define NL_STD3D_H
#if defined(_MSC_VER) && defined(_DEBUG)
#define _CRTDBG_MAP_ALLOC
#include <stdlib.h>
#include <crtdbg.h>
#define DEBUG_NEW new(_NORMAL_BLOCK, __FILE__, __LINE__)
#endif
#include <map> #include <map>
#include <set> #include <set>
@ -36,6 +44,8 @@
#include <limits> #include <limits>
#include <iterator> #include <iterator>
#include "nel/misc/types_nl.h"
#include "nel/misc/rgba.h" #include "nel/misc/rgba.h"
#include "nel/misc/debug.h" #include "nel/misc/debug.h"
@ -45,7 +55,4 @@
#include "nel/misc/matrix.h" #include "nel/misc/matrix.h"
#include "nel/misc/time_nl.h" #include "nel/misc/time_nl.h"
#include "nel/3d/debug_vb.h" #endif
#include "nel/3d/transform.h"
#include "nel/3d/quad_grid.h"

View file

@ -24,6 +24,10 @@
using namespace std; using namespace std;
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NL3D { namespace NL3D {

View file

@ -24,6 +24,9 @@
using namespace NLMISC; using namespace NLMISC;
using namespace std; using namespace std;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NL3D namespace NL3D
{ {

View file

@ -35,6 +35,9 @@
using namespace std; using namespace std;
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NL3D namespace NL3D
{ {

View file

@ -24,6 +24,10 @@
#include "nel/misc/common.h" #include "nel/misc/common.h"
#include "nel/3d/viewport.h" #include "nel/3d/viewport.h"
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NL3D namespace NL3D
{ {

View file

@ -23,6 +23,9 @@
#include "nel/3d/water_height_map.h" #include "nel/3d/water_height_map.h"
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NL3D { namespace NL3D {

View file

@ -27,6 +27,10 @@
using namespace std; using namespace std;
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {

View file

@ -27,6 +27,10 @@
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {
std::map< std::string, std::map< std::string, std::string > > CCtrlBase::AHCache; std::map< std::string, std::map< std::string, std::string > > CCtrlBase::AHCache;

View file

@ -27,6 +27,10 @@
using namespace std; using namespace std;
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace namespace
{ {
const uint KEY_REPEAT_MIN = 100; const uint KEY_REPEAT_MIN = 100;

View file

@ -26,6 +26,10 @@ using namespace std;
using namespace NLMISC; using namespace NLMISC;
using namespace NL3D; using namespace NL3D;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
NLMISC_REGISTER_OBJECT(CViewBase, CCtrlButton, std::string, "button"); NLMISC_REGISTER_OBJECT(CViewBase, CCtrlButton, std::string, "button");
namespace NLGUI namespace NLGUI

View file

@ -27,6 +27,10 @@
using namespace NLMISC; using namespace NLMISC;
using namespace std; using namespace std;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
NLMISC_REGISTER_OBJECT(CViewBase, CCtrlColPick, std::string, "colpick"); NLMISC_REGISTER_OBJECT(CViewBase, CCtrlColPick, std::string, "colpick");
namespace NLGUI namespace NLGUI

View file

@ -18,6 +18,10 @@
#include "stdpch.h" #include "stdpch.h"
#include "nel/gui/ctrl_draggable.h" #include "nel/gui/ctrl_draggable.h"
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {

View file

@ -23,6 +23,10 @@
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {

View file

@ -23,6 +23,10 @@
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {

View file

@ -28,6 +28,10 @@
using namespace NLMISC; using namespace NLMISC;
using namespace std; using namespace std;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
NLMISC_REGISTER_OBJECT(CViewBase, CCtrlScroll, std::string, "scroll"); NLMISC_REGISTER_OBJECT(CViewBase, CCtrlScroll, std::string, "scroll");
namespace NLGUI namespace NLGUI

View file

@ -18,6 +18,10 @@
#include "stdpch.h" #include "stdpch.h"
#include "nel/gui/ctrl_scroll_base.h" #include "nel/gui/ctrl_scroll_base.h"
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {

View file

@ -23,6 +23,10 @@
#include "nel/gui/ctrl_sheet_selection.h" #include "nel/gui/ctrl_sheet_selection.h"
#include "nel/gui/view_renderer.h" #include "nel/gui/view_renderer.h"
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {

View file

@ -30,6 +30,9 @@ using namespace std;
using namespace NLMISC; using namespace NLMISC;
using namespace NL3D; using namespace NL3D;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
NLMISC_REGISTER_OBJECT(CViewBase, CCtrlTextButton, std::string, "text_button"); NLMISC_REGISTER_OBJECT(CViewBase, CCtrlTextButton, std::string, "text_button");

View file

@ -23,6 +23,10 @@ using namespace std;
using namespace NLMISC; using namespace NLMISC;
using namespace NL3D; using namespace NL3D;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
NLMISC_REGISTER_OBJECT(CViewBase, CCtrlToolTip, std::string, "tooltip"); NLMISC_REGISTER_OBJECT(CViewBase, CCtrlToolTip, std::string, "tooltip");
REGISTER_UI_CLASS(CCtrlToolTip) REGISTER_UI_CLASS(CCtrlToolTip)

View file

@ -18,6 +18,10 @@
#include "stdpch.h" #include "stdpch.h"
#include "nel/gui/db_manager.h" #include "nel/gui/db_manager.h"
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {
CDBManager* CDBManager::instance = NULL; CDBManager* CDBManager::instance = NULL;

View file

@ -28,6 +28,10 @@
using namespace std; using namespace std;
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {
NLMISC_REGISTER_OBJECT(CViewBase, CDBGroupComboBox, std::string, "combo_box"); NLMISC_REGISTER_OBJECT(CViewBase, CDBGroupComboBox, std::string, "combo_box");

View file

@ -27,6 +27,10 @@ using namespace std;
using namespace NL3D; using namespace NL3D;
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {
NLMISC_REGISTER_OBJECT(CViewBase, CDBGroupSelectNumber, std::string, "select_number"); NLMISC_REGISTER_OBJECT(CViewBase, CDBGroupSelectNumber, std::string, "select_number");

View file

@ -26,6 +26,10 @@ using namespace std;
using namespace NL3D; using namespace NL3D;
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
NLMISC_REGISTER_OBJECT(CViewBase, CDBViewBar, std::string, "bar"); NLMISC_REGISTER_OBJECT(CViewBase, CDBViewBar, std::string, "bar");
namespace NLGUI namespace NLGUI

View file

@ -26,6 +26,10 @@ using namespace std;
using namespace NL3D; using namespace NL3D;
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {
NLMISC_REGISTER_OBJECT(CViewBase, CDBViewBar3, std::string, "bar3"); NLMISC_REGISTER_OBJECT(CViewBase, CDBViewBar3, std::string, "bar3");

View file

@ -24,6 +24,10 @@ using namespace std;
using namespace NL3D; using namespace NL3D;
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
NLMISC_REGISTER_OBJECT(CViewBase, CDBViewDigit, std::string, "digit"); NLMISC_REGISTER_OBJECT(CViewBase, CDBViewDigit, std::string, "digit");
namespace NLGUI namespace NLGUI

View file

@ -24,6 +24,9 @@ using namespace std;
using namespace NL3D; using namespace NL3D;
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
NLMISC_REGISTER_OBJECT(CViewBase, CDBViewNumber, std::string, "text_number"); NLMISC_REGISTER_OBJECT(CViewBase, CDBViewNumber, std::string, "text_number");

View file

@ -24,6 +24,9 @@ using namespace std;
using namespace NL3D; using namespace NL3D;
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
NLMISC_REGISTER_OBJECT(CViewBase, CDBViewQuantity, std::string, "text_quantity"); NLMISC_REGISTER_OBJECT(CViewBase, CDBViewQuantity, std::string, "text_quantity");

View file

@ -19,6 +19,10 @@
#include "nel/misc/events.h" #include "nel/misc/events.h"
#include "nel/gui/event_descriptor.h" #include "nel/gui/event_descriptor.h"
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {

View file

@ -21,6 +21,10 @@
#include "nel/gui/interface_group.h" #include "nel/gui/interface_group.h"
#include "nel/gui/widget_manager.h" #include "nel/gui/widget_manager.h"
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {
CEventListener::CEventListener() CEventListener::CEventListener()

View file

@ -39,6 +39,10 @@ using namespace std;
using namespace NL3D; using namespace NL3D;
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace namespace
{ {
const sint SIZE_W_LEFT = 16; const sint SIZE_W_LEFT = 16;

View file

@ -18,6 +18,10 @@
#include "stdpch.h" #include "stdpch.h"
#include "nel/gui/group_container_base.h" #include "nel/gui/group_container_base.h"
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {

View file

@ -33,6 +33,9 @@ using namespace std;
using namespace NLMISC; using namespace NLMISC;
using namespace NL3D; using namespace NL3D;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {

View file

@ -18,6 +18,10 @@
#include "stdpch.h" #include "stdpch.h"
#include "nel/gui/group_editbox_base.h" #include "nel/gui/group_editbox_base.h"
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {

View file

@ -20,6 +20,10 @@
#include "nel/gui/view_bitmap.h" #include "nel/gui/view_bitmap.h"
#include "nel/gui/view_text.h" #include "nel/gui/view_text.h"
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {
class EBDPrivate class EBDPrivate

View file

@ -26,6 +26,10 @@
using namespace std; using namespace std;
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {

View file

@ -24,6 +24,10 @@
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {

View file

@ -49,6 +49,9 @@
using namespace std; using namespace std;
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
// Default maximum time the request is allowed to take // Default maximum time the request is allowed to take
#define DEFAULT_RYZOM_CONNECTION_TIMEOUT (300.0) #define DEFAULT_RYZOM_CONNECTION_TIMEOUT (300.0)

View file

@ -28,6 +28,10 @@
using namespace std; using namespace std;
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {
// *************************************************************************** // ***************************************************************************

View file

@ -30,6 +30,10 @@
using namespace std; using namespace std;
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
NLMISC_REGISTER_OBJECT(CViewBase, CGroupList, std::string, "list"); NLMISC_REGISTER_OBJECT(CViewBase, CGroupList, std::string, "list");
namespace NLGUI namespace NLGUI

View file

@ -32,6 +32,9 @@
using namespace NLMISC; using namespace NLMISC;
using namespace std; using namespace std;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace namespace
{ {

View file

@ -24,6 +24,10 @@
using namespace std; using namespace std;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {

View file

@ -31,6 +31,10 @@
using namespace std; using namespace std;
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
NLMISC_REGISTER_OBJECT(CViewBase, CCtrlLink, std::string, "button_link"); NLMISC_REGISTER_OBJECT(CViewBase, CCtrlLink, std::string, "button_link");
namespace NLGUI namespace NLGUI

View file

@ -25,6 +25,10 @@
#include "nel/misc/i18n.h" #include "nel/misc/i18n.h"
#include "nel/gui/widget_manager.h" #include "nel/gui/widget_manager.h"
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
NLMISC_REGISTER_OBJECT(CViewBase, CGroupScrollText, std::string, "scroll_text"); NLMISC_REGISTER_OBJECT(CViewBase, CGroupScrollText, std::string, "scroll_text");
namespace NLGUI namespace NLGUI

View file

@ -18,6 +18,10 @@
#include "stdpch.h" #include "stdpch.h"
#include "nel/gui/group_submenu_base.h" #include "nel/gui/group_submenu_base.h"
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {

View file

@ -26,6 +26,10 @@
using namespace std; using namespace std;
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
NLMISC_REGISTER_OBJECT(CViewBase, CGroupTab, std::string, "tab"); NLMISC_REGISTER_OBJECT(CViewBase, CGroupTab, std::string, "tab");
namespace NLGUI namespace NLGUI

View file

@ -29,6 +29,10 @@
using namespace std; using namespace std;
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {

View file

@ -33,6 +33,10 @@
using namespace std; using namespace std;
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {

View file

@ -18,6 +18,9 @@
#include "stdpch.h" #include "stdpch.h"
#include "nel/gui/group_wheel.h" #include "nel/gui/group_wheel.h"
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
NLMISC_REGISTER_OBJECT(CViewBase, CInterfaceGroupWheel, std::string, "group_wheel"); NLMISC_REGISTER_OBJECT(CViewBase, CInterfaceGroupWheel, std::string, "group_wheel");

View file

@ -17,6 +17,10 @@
#include "stdpch.h" #include "stdpch.h"
#include "nel/gui/input_handler.h" #include "nel/gui/input_handler.h"
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {
CInputHandler::CInputHandler() CInputHandler::CInputHandler()

View file

@ -27,6 +27,10 @@ using namespace std;
using namespace NL3D; using namespace NL3D;
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {

View file

@ -31,6 +31,10 @@
using namespace std; using namespace std;
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {
bool CInterfaceElement::editorMode = false; bool CInterfaceElement::editorMode = false;

View file

@ -25,6 +25,10 @@
using namespace std; using namespace std;
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {

View file

@ -24,6 +24,10 @@ using NLMISC::ICDBNode;
using NLMISC::CCDBNodeBranch; using NLMISC::CCDBNodeBranch;
using NLMISC::CCDBNodeLeaf; using NLMISC::CCDBNodeLeaf;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {

View file

@ -25,6 +25,10 @@
using namespace std; using namespace std;
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {

View file

@ -18,6 +18,10 @@
#include "nel/gui/view_base.h" #include "nel/gui/view_base.h"
#include "nel/misc/factory.h" #include "nel/misc/factory.h"
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {
CViewBase* CInterfaceFactory::createClass( const std::string &name ) CViewBase* CInterfaceFactory::createClass( const std::string &name )

View file

@ -32,6 +32,10 @@
using namespace std; using namespace std;
using namespace NL3D; using namespace NL3D;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
#define IG_UNIQUE_ID(this) ((void*)&((this)->_GroupSizeRef)) // NB nico : use some pointer *inside* CInterfaceGroup as a unique id for lua registry (any field but #define IG_UNIQUE_ID(this) ((void*)&((this)->_GroupSizeRef)) // NB nico : use some pointer *inside* CInterfaceGroup as a unique id for lua registry (any field but
// the first), instead of using 'this'. 'this' is already used by // the first), instead of using 'this'. 'this' is already used by
// CLuaIHM::pushReflectableOnStack as unique id to CInterfaceElement's ref pointers // CLuaIHM::pushReflectableOnStack as unique id to CInterfaceElement's ref pointers

View file

@ -33,6 +33,10 @@
using namespace std; using namespace std;
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {

View file

@ -26,6 +26,10 @@
using namespace std; using namespace std;
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {

View file

@ -42,6 +42,11 @@
#ifdef LUA_NEVRAX_VERSION #ifdef LUA_NEVRAX_VERSION
#include "lua_ide_dll_nevrax/include/lua_ide_dll/ide_interface.h" // external debugger #include "lua_ide_dll_nevrax/include/lua_ide_dll/ide_interface.h" // external debugger
#endif #endif
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
const uint32 UI_CACHE_SERIAL_CHECK = NELID("IUG_"); const uint32 UI_CACHE_SERIAL_CHECK = NELID("IUG_");
using namespace NLMISC; using namespace NLMISC;

View file

@ -24,6 +24,10 @@
using namespace NLMISC; using namespace NLMISC;
using namespace std; using namespace std;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {
// helper to convert double <> sint64 // helper to convert double <> sint64

View file

@ -21,6 +21,10 @@
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {

View file

@ -31,6 +31,10 @@
#include "nel/gui/libwww_types.h" #include "nel/gui/libwww_types.h"
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {

View file

@ -22,6 +22,10 @@
#include "nel/gui/view_pointer.h" #include "nel/gui/view_pointer.h"
#include "nel/gui/group_editbox_decor.h" #include "nel/gui/group_editbox_decor.h"
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {
void ifexprufct_forcelink(); void ifexprufct_forcelink();

View file

@ -49,6 +49,10 @@
using namespace std; using namespace std;
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {

View file

@ -92,6 +92,10 @@ Compilation is VERY SLOW
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
// declare ostream << operator for ucstring -> registration of ucstring iin luabind will build a 'tostring' function from it // declare ostream << operator for ucstring -> registration of ucstring iin luabind will build a 'tostring' function from it
std::ostream &operator<<(std::ostream &str, const ucstring &value) std::ostream &operator<<(std::ostream &str, const ucstring &value)
{ {

View file

@ -19,6 +19,10 @@
#include "nel/gui/lua_manager.h" #include "nel/gui/lua_manager.h"
#include "nel/gui/lua_helper.h" #include "nel/gui/lua_helper.h"
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {

View file

@ -20,6 +20,10 @@
#include "nel/gui/lua_ihm.h" #include "nel/gui/lua_ihm.h"
#include "nel/gui/lua_helper.h" #include "nel/gui/lua_helper.h"
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {

View file

@ -21,6 +21,10 @@
#include "nel/gui/interface_group.h" #include "nel/gui/interface_group.h"
#include "nel/gui/interface_parser.h" #include "nel/gui/interface_parser.h"
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {
IParser::IParser() IParser::IParser()

View file

@ -22,6 +22,10 @@
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {

View file

@ -18,6 +18,10 @@
#include "stdpch.h" #include "stdpch.h"
#include "nel/gui/reflect.h" #include "nel/gui/reflect.h"
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {
// Yoyo: Act like a singleton, else registerClass may crash. // Yoyo: Act like a singleton, else registerClass may crash.

View file

@ -49,6 +49,10 @@
#include "nel/gui/group_html.h" #include "nel/gui/group_html.h"
#include "nel/gui/group_header.h" #include "nel/gui/group_header.h"
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {
void CReflectableRegister::registerClasses() void CReflectableRegister::registerClasses()

View file

@ -18,6 +18,10 @@
#include "nel/gui/root_group.h" #include "nel/gui/root_group.h"
#include <vector> #include <vector>
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {

View file

@ -17,6 +17,13 @@
#ifndef NELGUI_H #ifndef NELGUI_H
#define NELGUI_H #define NELGUI_H
#if defined(_MSC_VER) && defined(_DEBUG)
#define _CRTDBG_MAP_ALLOC
#include <stdlib.h>
#include <crtdbg.h>
#define DEBUG_NEW new(_NORMAL_BLOCK, __FILE__, __LINE__)
#endif
#include <string> #include <string>
#include <limits> #include <limits>

View file

@ -17,6 +17,10 @@
#include "stdpch.h" #include "stdpch.h"
#include "nel/gui/string_case.h" #include "nel/gui/string_case.h"
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {
inline bool isSeparator (ucchar c) inline bool isSeparator (ucchar c)

View file

@ -19,6 +19,9 @@
using namespace std; using namespace std;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {

View file

@ -20,6 +20,10 @@
#include "nel/gui/interface_group.h" #include "nel/gui/interface_group.h"
#include "nel/gui/widget_manager.h" #include "nel/gui/widget_manager.h"
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {

View file

@ -26,6 +26,9 @@ using namespace std;
using namespace NLMISC; using namespace NLMISC;
using namespace NL3D; using namespace NL3D;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
NLMISC_REGISTER_OBJECT(CViewBase, CViewBitmap, std::string, "bitmap"); NLMISC_REGISTER_OBJECT(CViewBase, CViewBitmap, std::string, "bitmap");
REGISTER_UI_CLASS(CViewBitmap) REGISTER_UI_CLASS(CViewBitmap)

View file

@ -25,6 +25,10 @@
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {

View file

@ -24,6 +24,10 @@ using namespace std;
using namespace NLMISC; using namespace NLMISC;
using namespace NL3D; using namespace NL3D;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {

View file

@ -27,6 +27,10 @@
using namespace std; using namespace std;
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
NLMISC_REGISTER_OBJECT(CViewBase, CViewPointer, std::string, "generic_pointer"); NLMISC_REGISTER_OBJECT(CViewBase, CViewPointer, std::string, "generic_pointer");
namespace NLGUI namespace NLGUI

View file

@ -18,6 +18,10 @@
#include "stdpch.h" #include "stdpch.h"
#include "nel/gui/view_pointer_base.h" #include "nel/gui/view_pointer_base.h"
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {

View file

@ -23,6 +23,10 @@
using namespace NLMISC; using namespace NLMISC;
#ifdef DEBUG_NEW
#define new DEBUG_NEW
#endif
namespace NLGUI namespace NLGUI
{ {

Some files were not shown because too many files have changed in this diff Show more