|
13 | 13 | // #define Adium_CellPadding 2
|
14 | 14 | #define Adium_MARGIN_X 4
|
15 | 15 | #define kPSMAdiumCounterPadding 3.0
|
| 16 | +#define kPSMAdiumImageWidth 20.0 |
16 | 17 |
|
17 | 18 | @interface PSMTabBarCell(SharedPrivates)
|
18 | 19 |
|
@@ -350,8 +351,8 @@ - (NSRect)titleRectForBounds:(NSRect)theRect ofTabCell:(PSMTabBarCell *)cell {
|
350 | 351 |
|
351 | 352 | NSRect largeImageRect = [cell largeImageRectForBounds:theRect];
|
352 | 353 | if (!NSEqualRects(largeImageRect, NSZeroRect)) {
|
353 |
| - constrainedDrawingRect.origin.x += NSWidth(largeImageRect) + kPSMTabBarCellPadding; |
354 |
| - constrainedDrawingRect.size.width -= NSWidth(largeImageRect) + kPSMTabBarCellPadding; |
| 354 | + constrainedDrawingRect.origin.x += kPSMAdiumImageWidth + kPSMTabBarCellPadding; |
| 355 | + constrainedDrawingRect.size.width -= kPSMAdiumImageWidth + kPSMTabBarCellPadding; |
355 | 356 | }
|
356 | 357 |
|
357 | 358 | if (orientation == PSMTabBarHorizontalOrientation) {
|
@@ -456,8 +457,8 @@ -(NSRect)largeImageRectForBounds:(NSRect)theRect ofTabCell:(PSMTabBarCell *)cell
|
456 | 457 | constrainedDrawingRect.origin.y - ((constrainedDrawingRect.size.height - scaledImageSize.height) / 2),
|
457 | 458 | scaledImageSize.width, scaledImageSize.height);
|
458 | 459 |
|
459 |
| - if(scaledImageSize.width < kPSMTabBarIconWidth) { |
460 |
| - result.origin.x += (kPSMTabBarIconWidth - scaledImageSize.width) / 2.0; |
| 460 | + if(scaledImageSize.width < kPSMAdiumImageWidth) { |
| 461 | + result.origin.x += (kPSMTabBarCellPadding + kPSMAdiumImageWidth - scaledImageSize.width) / 2.0; |
461 | 462 | }
|
462 | 463 | if(scaledImageSize.height < constrainedDrawingRect.size.height) {
|
463 | 464 | result.origin.y += (constrainedDrawingRect.size.height - scaledImageSize.height) / 2.0;
|
|
0 commit comments