@@ -259,7 +259,6 @@ static HBITMAP BitmapFromMetroBitmap( HBITMAP hBitmap, int bitmapSize, DWORD met
259
259
HGDIOBJ bmp0=SelectObject (hdc,bmp);
260
260
HGDIOBJ bmp02=SelectObject (hsrc,hBitmap);
261
261
int offset=(bitmapSize-info.bmWidth )/2 ;
262
- bool bInvert=g_bInvertMetroIcons;
263
262
if (g_bInvertMetroIcons && bGrayscale)
264
263
{
265
264
FillRect (hdc,&rc,(HBRUSH)GetStockObject (BLACK_BRUSH));
@@ -302,8 +301,7 @@ static HBITMAP BitmapFromMetroBitmap( HBITMAP hBitmap, int bitmapSize, DWORD met
302
301
303
302
static HBITMAP LoadMetroBitmap0 ( const wchar_t *path, int bitmapSize, DWORD metroColor )
304
303
{
305
- int iconSize=g_bInvertMetroIcons?bitmapSize:(bitmapSize-2 );
306
- SIZE size={-iconSize,iconSize};
304
+ SIZE size={-bitmapSize,bitmapSize};
307
305
HBITMAP hBitmap=LoadImageFile (path,&size,true ,true ,NULL );
308
306
if (hBitmap)
309
307
{
@@ -440,16 +438,8 @@ static HBITMAP LoadMetroBitmap2( const wchar_t *location, int bitmapSize, DWORD
440
438
}
441
439
if (iconSize)
442
440
{
443
- if (g_bInvertMetroIcons)
444
- {
445
- if (iconSize>bitmapSize)
446
- iconSize=bitmapSize;
447
- }
448
- else
449
- {
450
- if (iconSize>bitmapSize-2 )
451
- iconSize=bitmapSize-2 ;
452
- }
441
+ if (iconSize>bitmapSize)
442
+ iconSize=bitmapSize;
453
443
SIZE size={iconSize,iconSize};
454
444
HBITMAP hBitmap=LoadImageFile (path,&size,true ,true ,NULL );
455
445
if (hBitmap)
@@ -2322,12 +2312,6 @@ void CItemManager::LoadShellIcon( IShellItem *pItem, int refreshFlags, const Ico
2322
2312
int smallIconSize=SMALL_ICON_SIZE;
2323
2313
int largeIconSize=LARGE_ICON_SIZE;
2324
2314
int extraLargeIconSize=EXTRA_LARGE_ICON_SIZE;
2325
- if (pMetroColor)
2326
- {
2327
- smallIconSize-=2 ;
2328
- largeIconSize-=2 ;
2329
- extraLargeIconSize-=2 ;
2330
- }
2331
2315
HICON hSmallIcon=NULL , hLargeIcon=NULL , hExtraLargeIcon=NULL ;
2332
2316
if (bNotFileName)
2333
2317
{
@@ -2446,8 +2430,7 @@ void CItemManager::LoadMetroIcon( IShellItem *pItem, int &refreshFlags, const Ic
2446
2430
if (FAILED (pResManager->GetDefaultContext (IID_ResourceContext,(void **)&pResContext)))
2447
2431
return ;
2448
2432
int iconFlags=0 ;
2449
- int delta=g_bInvertMetroIcons?0 :2 ;
2450
- if ((refreshFlags&INFO_SMALL_ICON) && SetResContextTargetSize (pResContext,SMALL_ICON_SIZE-delta))
2433
+ if ((refreshFlags&INFO_SMALL_ICON) && SetResContextTargetSize (pResContext,SMALL_ICON_SIZE))
2451
2434
{
2452
2435
CComString pLocation;
2453
2436
if (SUCCEEDED (pResMap->GetFilePath (iconName,&pLocation)))
@@ -2457,7 +2440,7 @@ void CItemManager::LoadMetroIcon( IShellItem *pItem, int &refreshFlags, const Ic
2457
2440
StoreInCache (hash,L" " ,hSmallBitmap,NULL ,NULL ,INFO_SMALL_ICON,smallIcon,largeIcon,extraLargeIcon,false ,true );
2458
2441
}
2459
2442
}
2460
- if ((refreshFlags&INFO_LARGE_ICON) && SetResContextTargetSize (pResContext,LARGE_ICON_SIZE-delta ))
2443
+ if ((refreshFlags&INFO_LARGE_ICON) && SetResContextTargetSize (pResContext,LARGE_ICON_SIZE))
2461
2444
{
2462
2445
CComString pLocation;
2463
2446
if (SUCCEEDED (pResMap->GetFilePath (iconName,&pLocation)))
@@ -2467,7 +2450,7 @@ void CItemManager::LoadMetroIcon( IShellItem *pItem, int &refreshFlags, const Ic
2467
2450
StoreInCache (hash,L" " ,NULL ,hLargeBitmap,NULL ,INFO_LARGE_ICON,smallIcon,largeIcon,extraLargeIcon,false ,true );
2468
2451
}
2469
2452
}
2470
- if ((refreshFlags&INFO_EXTRA_LARGE_ICON) && SetResContextTargetSize (pResContext,EXTRA_LARGE_ICON_SIZE-delta ))
2453
+ if ((refreshFlags&INFO_EXTRA_LARGE_ICON) && SetResContextTargetSize (pResContext,EXTRA_LARGE_ICON_SIZE))
2471
2454
{
2472
2455
CComString pLocation;
2473
2456
if (SUCCEEDED (pResMap->GetFilePath (iconName,&pLocation)))
0 commit comments