[Gtab-cvs] src/factory DefaultDrawerFactory.cpp,1.44,1.45 DrawerFactory.cpp,1.4,1.5
Status: Alpha
Brought to you by:
m0ta
|
From: Seavan <se...@us...> - 2006-02-28 07:15:27
|
Update of /cvsroot/gtab/src/factory In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv4121/factory Modified Files: DefaultDrawerFactory.cpp DrawerFactory.cpp Log Message: * memory leaks workaround Index: DrawerFactory.cpp =================================================================== RCS file: /cvsroot/gtab/src/factory/DrawerFactory.cpp,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** DrawerFactory.cpp 26 Feb 2006 12:13:44 -0000 1.4 --- DrawerFactory.cpp 28 Feb 2006 07:15:24 -0000 1.5 *************** *** 27,31 **** --- 27,37 ---- * @author Samvel Avanesov */ + // PCH file #include "stdafx.h" + // Memory leak detection + #ifdef _DEBUG + #define new DEBUG_NEW + #endif + // -- memory leak detection #include "DrawerFactory.h" Index: DefaultDrawerFactory.cpp =================================================================== RCS file: /cvsroot/gtab/src/factory/DefaultDrawerFactory.cpp,v retrieving revision 1.44 retrieving revision 1.45 diff -C2 -d -r1.44 -r1.45 *** DefaultDrawerFactory.cpp 27 Feb 2006 18:52:33 -0000 1.44 --- DefaultDrawerFactory.cpp 28 Feb 2006 07:15:24 -0000 1.45 *************** *** 27,31 **** --- 27,37 ---- * @author Samvel Avanesov */ + // PCH file #include "stdafx.h" + // Memory leak detection + #ifdef _DEBUG + #define new DEBUG_NEW + #endif + // -- memory leak detection #include "DefaultDrawerFactory.h" #include "../drawobjects/CursorDrawer.h" *************** *** 162,166 **** DefaultDrawerFactory* DefaultDrawerFactory::instance() { ! static DefaultDrawerFactory *factory = new DefaultDrawerFactory(); ! return factory; } --- 168,172 ---- DefaultDrawerFactory* DefaultDrawerFactory::instance() { ! static DefaultDrawerFactory factory;; ! return &factory; } |