In general wanting the host application to survive an in-process plug-in crash is misguided. It can leave the application in an unstable state and cause problems at a later time which can seem unrelated to the original problem and are much harder to fix. The classic example is a corrupt heap which often manifests in a crash in the allocation or de-allocation of memory some time after the actual real problem.
Recently I heard about .NET profiling API and want to implement it. To do that, I require to build an ATL based COM project. Unfortunately I am using Visual C++ express edition which doesn't supports ATL. So I googled for a free alternative to ATL. I got COMET[^] and DispHelper[^]
Can I use these libraries to implement .NET profiling API? Thanks for your kind advice.
What do you think is the best control for getting keyboard and mouse input? I need to be able to over ride OnKeyDown, OnChar, OnMouseMove, OnLButtonDown & Up. I need to be able to control every aspect of how to respond to the input.
I have the task to wrap a list<myobject> inside a .NET wrapper, and actually after some heavy researching and editing, it seems to work, but I dont trust that I have understood all unmanaged issues correctly.
First, I found I should add an operator overload and a copy constructor to my class:
int OnlyLeafNodes(Elem *t, int currentDepth=0)
// if 'this' is null, returnif(!t)
// inc the depth because we represent another one
// ask each of the children, how deep they go, relative to meint leftDepth=OnlyLeafNodes(t->left,currentDepth)-currentDepth);
// spots 1,1 | 1,0 | 0,1if(max(leftDepth,rightDepth)==1)
cout << t->key << endl;
// and return the depth this node representsreturn currentDepth;
I haven't compiled it, sorry, but the general idea is to find all children who only descend one past the currentDepth