Jump to content

  • Log In with Google      Sign In   
  • Create Account

Funkymunky

Member Since 28 Jul 1999
Offline Last Active Yesterday, 10:27 PM

Posts I've Made

In Topic: Linking a static library to my static library

21 December 2014 - 02:53 PM

>Try to linking just with the .exe.

 

Right, this is the most common advice.  I was trying to avoid that; I have my 3 static libraries which in turn link to 20 individual libraries.  I don't want every application that uses my 3 static libraries to have to explicitly link to all those individual libraries.

 

And I still don't get the argument for why this i frowned upon.  If my library contains a static version of the declarations from a dynamic library, or if those declarations are in the application itself, seems to be reaching the same endpoint.  The dynamic library changes and either the application or the static library has to be updated.  But in one case I'm linking every application to 20 libraries, and in the other i'm only linking to 3 which manage those 20.


In Topic: Linking a static library to my static library

21 December 2014 - 10:45 AM

When I said "links to" I really just meant setting it as an "Additional Dependency".  I understand that it only gets linked in when it is ultimately used by the application.  I only need to do that in the Graphics library though, but I get the warnings as previously described.

 

I'm really wondering about why it's so adamantly proclaimed as "wrong" to do it this way, and also if there's a way to do it without getting the warnings.


In Topic: Direct2D kills my CriticalSection...?

12 December 2014 - 02:36 PM

It's just a std::queue, I'm trying to use the CriticalSection stuff to prevent blocking from being a problem.


In Topic: Direct2D kills my CriticalSection...?

12 December 2014 - 07:56 AM

Incidentally the class I wrote to wrap the critical section work is almost identical to the "CriticalSection" class from that link, but I like their CSLock class and will probably incorporate that as well.  (I'll try it when I get home).

 

However I doubt that this is the case.  I know I'm properly calling LeaveCriticalSection.  Again, this code worked 100% of the time until I added the 3 Direct2D calls.  I can comment them out and it works perfectly.


In Topic: Windows Dialog Background Color

08 December 2014 - 09:43 PM

I guess I don't even know what the "default" on Windows 7 looks like... I'm doing this now to get a darker gray than I'd anticipated, but at least it's doing something I'd expect:

		case WM_ERASEBKGND:
			RECT rc;
			GetClientRect(hwnd, &rc);
			FillRect((HDC)wParam, &rc, GetSysColorBrush(COLOR_BTNSHADOW));
			return TRUE;

PARTNERS