Search found 6681 matches

by Auria
Thu Mar 08, 2007 8:53 pm
Forum: C++ Development
Topic: objects that can cause memory leaks
Replies: 16
Views: 2151

It ponits to the constructor of HUD. Do you delete all HUD instances? Really, you should check you delete everything that has a new.
by Auria
Thu Mar 08, 2007 8:51 pm
Forum: C++ Development
Topic: [resolved]problem to center wxStaticBox
Replies: 3
Views: 497

Hi, i see you create sizers:

wxBoxSizer* sizerCodeSujet = new wxBoxSizer(wxHORIZONTAL);

but never apply them to the window:

SetSizer(sizerCodeSujet);
SetAutoLayout(true);
(etc...)

without this, sizers will probbaly not work
by Auria
Wed Mar 07, 2007 6:44 pm
Forum: C++ Development
Topic: objects that can cause memory leaks
Replies: 16
Views: 2151

Every 'new' needs a delete... (not necessarly in your code though - you need to get info about the libs you are using to know who should delete what -for instance, in wxWidgets, parent windows automatically delte their children ) with a quick look, i saw this: HUD_Element * hud_element = new HUD_Ele...
by Auria
Tue Mar 06, 2007 11:55 pm
Forum: C++ Development
Topic: objects that can cause memory leaks
Replies: 16
Views: 2151

rather do this

Code: Select all

Gui *gui;
osg::ref_ptr<osg::Group> sceneRoot;
/*`Main program' equivalent, creating windows and returning main app frame */
bool wxOsgApp::OnInit()
{


gui = new Gui();
} 
by Auria
Tue Mar 06, 2007 11:48 pm
Forum: C++ Development
Topic: Window beside the main frame
Replies: 1
Views: 209

You create the frame on the stack, hence it is deleted the second the method is done. You need to use 'new'.
by Auria
Tue Mar 06, 2007 1:38 am
Forum: wxCode
Topic: wxScript and Tcl
Replies: 6
Views: 1686

I really need to know that I can embed an interpreter before I continue develop. Tcl is the interpreter of choice in applications I use in my business so I would prefer to use Tcl but would consider Python. You could try a 3rd party library like C++/Tcl http://cpptcl.sourceforge.net/ jb_coder gave ...
by Auria
Tue Mar 06, 2007 12:54 am
Forum: C++ Development
Topic: new operator on non wxStructures structures [SOLVED]
Replies: 7
Views: 886

Just being curious: Also note, that pRands[j] never should be 0, because then you got an invalid division. 0/255 != 0? I know that 255/0 results in an exception or at least a runtime error but didn't know that 0/anything also is undefined. Is that actually true? This si not true, 0/anything = 0
by Auria
Sat Mar 03, 2007 9:13 pm
Forum: C++ Development
Topic: help with array of pointers to objects!!
Replies: 2
Views: 409

GCC 4 has no problem with that: #include <iostream> class MyType { public: int c,d; MyType(int a, int b) { c=a; d=b; } }; int main(int argc, char* argv[]) { MyType* someArray[10]; int x = 0; while (x < 10) { someArray[x] = new MyType(1,2); x++; } x = 0; while (x < 10) { std::cout << someArray[x]->c ...
by Auria
Sat Mar 03, 2007 2:57 pm
Forum: Platform Related Issues
Topic: why MacOSX Gauge height not changing?
Replies: 6
Views: 1254

Don't bother with that, actually making wider would probably make it look weird to mac users ;)
by Auria
Sat Mar 03, 2007 2:18 am
Forum: Platform Related Issues
Topic: why MacOSX Gauge height not changing?
Replies: 6
Views: 1254

Just seen the screenshots...

Well this is the standard dimensions for progress bars on OS X. I have never seen any bigger ones
by Auria
Fri Mar 02, 2007 10:10 pm
Forum: C++ Development
Topic: problems (bug?) with moving wxStaticText and wxButton
Replies: 3
Views: 543

A lot has changed since 2.4...
change the location with SetSize()
I don't understand. SetSize() changes the size, not the location! SetPosition() will change the location.

EDIT: My mistake i didn't check enoguh. Forget about that
by Auria
Fri Mar 02, 2007 9:35 pm
Forum: Platform Related Issues
Topic: why MacOSX Gauge height not changing?
Replies: 6
Views: 1254

Can you post some code? I've never had any issue
by Auria
Fri Mar 02, 2007 2:03 am
Forum: C++ Development
Topic: Main frame collecting Dialog info?
Replies: 57
Views: 4046

Note: reload the sample, i just looked at it again and noticed an error - fixed now.
by Auria
Fri Mar 02, 2007 1:53 am
Forum: General Development
Topic: wxglcanvas texture issue
Replies: 2
Views: 490

I think this is what the class wxGLContext does - however i cannot help fruther since i never used it
by Auria
Fri Mar 02, 2007 1:38 am
Forum: C++ Development
Topic: Main frame collecting Dialog info?
Replies: 57
Views: 4046

ContactManagerFrm is a class name, you can't call methods on a class name. You will need a pointer to an ContactManagerFrm instance. Now remember that because all your errors are about that! You cannot call methods on a pointer name stored in a string. You cannot call a method an an ID. You cannot c...