DXGL r313 - Code Review

Jump to navigation Jump to search
Repository:DXGL
Revision:r312‎ | r313 | r314 >
Date:20:59, 13 January 2013
Author:admin
Status:new
Tags:
Comment:
Revert R301 in dxglcfg.cpp
Modified paths:
  • /dxglcfg/dxglcfg.cpp (modified) (history)

Diff [purge]

Index: dxglcfg/dxglcfg.cpp
@@ -1,5 +1,5 @@
22 // DXGL
3 -// Copyright (C) 2011-2013 William Feely
 3+// Copyright (C) 2011-2012 William Feely
44
55 // This library is free software; you can redistribute it and/or
66 // modify it under the terms of the GNU Lesser General Public
@@ -705,7 +705,7 @@
706706 case IDC_APPS:
707707 OldTextColor = GetTextColor(drawitem->hDC);
708708 OldBackColor = GetBkColor(drawitem->hDC);
709 - if((drawitem->itemAction & ODA_SELECT) && (drawitem->itemState & ODS_SELECTED) &&
 709+ if((drawitem->itemAction | ODA_SELECT) && (drawitem->itemState & ODS_SELECTED) &&
710710 !(drawitem->itemState & ODS_COMBOBOXEDIT))
711711 {
712712 SetTextColor(drawitem->hDC,GetSysColor(COLOR_HIGHLIGHTTEXT));
@@ -1042,7 +1042,7 @@
10431043 if(!apps[current_app].icon_shared) DeleteObject(apps[current_app].icon);
10441044 if(apps[current_app].name) delete apps[current_app].name;
10451045 if(apps[current_app].regkey) delete apps[current_app].regkey;
1046 - for(i = current_app; i < appcount; i++)
 1046+ for(int i = current_app; i < appcount; i++)
10471047 {
10481048 apps[i] = apps[i+1];
10491049 }
@@ -1073,12 +1073,10 @@
10741074 icc.dwSize = sizeof(icc);
10751075 icc.dwICC = ICC_WIN95_CLASSES;
10761076 HMODULE comctl32 = LoadLibrary(_T("comctl32.dll"));
1077 - BOOL (WINAPI *iccex)(LPINITCOMMONCONTROLSEX lpInitCtrls) = NULL;
1078 - if(comctl32) iccex =(BOOL (WINAPI *)(LPINITCOMMONCONTROLSEX))
1079 - GetProcAddress(comctl32,"InitCommonControlsEx");
 1077+ BOOL (WINAPI *iccex)(LPINITCOMMONCONTROLSEX lpInitCtrls) =
 1078+ (BOOL (WINAPI *)(LPINITCOMMONCONTROLSEX))GetProcAddress(comctl32,"InitCommonControlsEx");
10801079 if(iccex) iccex(&icc);
10811080 else InitCommonControls();
1082 - if(comctl32) FreeLibrary(comctl32);
10831081 hinstance = hInstance;
10841082 GetModuleFileName(NULL,hlppath,MAX_PATH);
10851083 GetDirFromPath(hlppath);