// see http://stackoverflow.com/questions/25494914/is-there-something-like-cdn-filecancel-analogous-to-cdn-fileok-for-getting-when#comment40420049_25494914
// TODO reconcile this with users being able to enable/disable windows
structdialogDisableWindow{
HWNDhwnd;
uintmax_tn;
UT_hash_handlehh;
};
staticstructdialogDisableWindow*windows=NULL;
voiddialogHelperRegisterWindow(HWNDhwnd)
{
structdialogDisableWindow*d;
HASH_FIND_PTR(windows,&hwnd,d);
if(d!=NULL)
complain("window handle %p already register in dialogHelperRegisterWindow()",hwnd);
d=uiNew(structdialogDisableWindow);
d->hwnd=hwnd;
HASH_ADD_PTR(windows,hwnd,d);
}
voiddialogHelperUnregisterWindow(HWNDhwnd)
{
structdialogDisableWindow*d;
HASH_FIND_PTR(windows,&hwnd,d);
if(d==NULL)
complain("window handle %p not registered in dialogHelperUnregisterWindow()",hwnd);