aboutsummaryrefslogtreecommitdiff
path: root/AppKit/GTMUILocalizerAndLayoutTweaker.m
diff options
context:
space:
mode:
authorGravatar gtm.daemon <gtm.daemon@7dc7ac4e-7543-0410-b95c-c1676fc8e2a3>2009-11-03 17:00:36 +0000
committerGravatar gtm.daemon <gtm.daemon@7dc7ac4e-7543-0410-b95c-c1676fc8e2a3>2009-11-03 17:00:36 +0000
commit31b2dc28acf86e12071dba9628856ade5b892312 (patch)
treeb4fab436cc9acb3308e4390838e4608a6fc87442 /AppKit/GTMUILocalizerAndLayoutTweaker.m
parent0a1e63215324bdc7379e49ed2c9c6dee7f43a6b0 (diff)
[Author: thomasvl]
Handle path controls in autosizing. R=stuartmorgan DELTA=4 (4 added, 0 deleted, 0 changed)
Diffstat (limited to 'AppKit/GTMUILocalizerAndLayoutTweaker.m')
-rw-r--r--AppKit/GTMUILocalizerAndLayoutTweaker.m4
1 files changed, 4 insertions, 0 deletions
diff --git a/AppKit/GTMUILocalizerAndLayoutTweaker.m b/AppKit/GTMUILocalizerAndLayoutTweaker.m
index 382871c..d48e635 100644
--- a/AppKit/GTMUILocalizerAndLayoutTweaker.m
+++ b/AppKit/GTMUILocalizerAndLayoutTweaker.m
@@ -458,6 +458,10 @@ static NSSize SizeToFit(NSView *view, NSPoint offset) {
// Don't try to sizeToFit because edit fields really don't want to be sized
// to what is in them as they are for users to enter things so honor their
// current size.
+ } else if ([view isKindOfClass:[NSPathControl class]]) {
+ // Don't try to sizeToFit because NSPathControls usually need to be able
+ // to display any path, so they shouldn't tight down to whatever they
+ // happen to be listing at the moment.
} else {
// Genericaly fire a sizeToFit if it has one.
if ([view respondsToSelector:@selector(sizeToFit)]) {