aboutsummaryrefslogtreecommitdiffstats
path: root/Frameworks/PSMTabBar
diff options
context:
space:
mode:
Diffstat (limited to 'Frameworks/PSMTabBar')
-rw-r--r--Frameworks/PSMTabBar/PSMTabDragAssistant.m1
-rw-r--r--Frameworks/PSMTabBar/Styles/PSMSequelProTabStyle.h2
-rw-r--r--Frameworks/PSMTabBar/Styles/PSMSequelProTabStyle.m14
3 files changed, 13 insertions, 4 deletions
diff --git a/Frameworks/PSMTabBar/PSMTabDragAssistant.m b/Frameworks/PSMTabBar/PSMTabDragAssistant.m
index 5d5b7fcc..21e014da 100644
--- a/Frameworks/PSMTabBar/PSMTabDragAssistant.m
+++ b/Frameworks/PSMTabBar/PSMTabDragAssistant.m
@@ -337,6 +337,7 @@ static PSMTabDragAssistant *sharedDragAssistant = nil;
if ([[[self sourceTabBar] tabView] numberOfTabViewItems] == 1 && [self sourceTabBar] == control &&
[[[self sourceTabBar] delegate] respondsToSelector:@selector(tabView:newTabBarForDraggedTabViewItem:atPoint:)]) {
[[[self sourceTabBar] window] setAlphaValue:0.0f];
+ [[[self sourceTabBar] window] setIgnoresMouseEvents:YES];
if ([_sourceTabBar tearOffStyle] == PSMTabBarTearOffAlphaWindow) {
[[_draggedView window] setAlphaValue:kPSMTabDragWindowAlpha];
diff --git a/Frameworks/PSMTabBar/Styles/PSMSequelProTabStyle.h b/Frameworks/PSMTabBar/Styles/PSMSequelProTabStyle.h
index d7ab9a56..599bc492 100644
--- a/Frameworks/PSMTabBar/Styles/PSMSequelProTabStyle.h
+++ b/Frameworks/PSMTabBar/Styles/PSMSequelProTabStyle.h
@@ -26,6 +26,8 @@
#import "PSMTabStyle.h"
@interface PSMSequelProTabStyle : NSObject <PSMTabStyle> {
+ SInt32 systemVersion;
+
NSImage *sequelProCloseButton;
NSImage *sequelProCloseButtonDown;
NSImage *sequelProCloseButtonOver;
diff --git a/Frameworks/PSMTabBar/Styles/PSMSequelProTabStyle.m b/Frameworks/PSMTabBar/Styles/PSMSequelProTabStyle.m
index ece10a76..05c4ada2 100644
--- a/Frameworks/PSMTabBar/Styles/PSMSequelProTabStyle.m
+++ b/Frameworks/PSMTabBar/Styles/PSMSequelProTabStyle.m
@@ -46,6 +46,9 @@
- (id) init
{
if ( (self = [super init]) ) {
+ systemVersion = 0;
+ Gestalt(gestaltSystemVersion, &systemVersion);
+
sequelProCloseButton = [[NSImage alloc] initByReferencingFile:[[PSMTabBarControl bundle] pathForImageResource:@"SequelProTabClose"]];
sequelProCloseButtonDown = [[NSImage alloc] initByReferencingFile:[[PSMTabBarControl bundle] pathForImageResource:@"SequelProTabClose_Pressed"]];
sequelProCloseButtonOver = [[NSImage alloc] initByReferencingFile:[[PSMTabBarControl bundle] pathForImageResource:@"SequelProTabClose_Rollover"]];
@@ -405,12 +408,15 @@
[[NSGraphicsContext currentContext] setShouldAntialias:NO];
float backgroundCalibratedWhite = 0.495f;
+ if (systemVersion >= 0x1070) backgroundCalibratedWhite = 0.55f;
+
float lineCalibratedWhite = [[NSColor darkGrayColor] whiteComponent];
float shadowAlpha = 0.4f;
// When the window is in the background, tone down the colours
if (![[tabBar window] isMainWindow] || ![NSApp isActive]) {
backgroundCalibratedWhite = 0.73f;
+ if (systemVersion >= 0x1070) backgroundCalibratedWhite = 0.79f;
lineCalibratedWhite = 0.49f;
shadowAlpha = 0.3f;
}
@@ -502,19 +508,19 @@
if ([[tabBar window] isMainWindow] && [NSApp isActive]) {
lineColor = [NSColor darkGrayColor];
if ([cell state] == NSOnState) {
- fillColor = [NSColor colorWithCalibratedWhite:0.59f alpha:1.0f];
+ fillColor = [NSColor colorWithCalibratedWhite:(systemVersion >= 0x1070)?0.63f:0.59f alpha:1.0f];
shadowColor = [NSColor colorWithCalibratedWhite:0.0f alpha:0.7f];
} else {
- fillColor = [NSColor colorWithCalibratedWhite:0.495f alpha:1.0f];
+ fillColor = [NSColor colorWithCalibratedWhite:(systemVersion >= 0x1070)?0.55f:0.495f alpha:1.0f];
shadowColor = [NSColor colorWithCalibratedWhite:0.0f alpha:1.0f];
}
} else {
lineColor = [NSColor colorWithCalibratedWhite:0.49f alpha:1.0f];
if ([cell state] == NSOnState) {
- fillColor = [NSColor colorWithCalibratedWhite:0.81f alpha:1.0f];
+ fillColor = [NSColor colorWithCalibratedWhite:(systemVersion >= 0x1070)?0.85f:0.81f alpha:1.0f];
shadowColor = [NSColor colorWithCalibratedWhite:0.0f alpha:0.4f];
} else {
- fillColor = [NSColor colorWithCalibratedWhite:0.73f alpha:1.0f];
+ fillColor = [NSColor colorWithCalibratedWhite:(systemVersion >= 0x1070)?0.79f:0.73f alpha:1.0f];
shadowColor = [NSColor colorWithCalibratedWhite:0.0f alpha:0.7f];
}
}