From 4597bc5c390024765aef274dc1aae5c15dfec5d8 Mon Sep 17 00:00:00 2001 From: "nick.kreeger%park.edu" Date: Tue, 6 Jun 2006 20:42:40 +0000 Subject: [PATCH] Fix bug 333623, about:blank's favicon is draggable from location bar, but not from tabs. Patch by Chris Lawson --- camino/src/browser/PageProxyIcon.mm | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/camino/src/browser/PageProxyIcon.mm b/camino/src/browser/PageProxyIcon.mm index 704417ba24d0..299ebeee64f9 100644 --- a/camino/src/browser/PageProxyIcon.mm +++ b/camino/src/browser/PageProxyIcon.mm @@ -92,12 +92,13 @@ { NSString* urlString = nil; NSString* titleString = nil; - + id parentWindowController = [[self window] windowController]; if ([parentWindowController isKindOfClass:[BrowserWindowController class]]) [[(BrowserWindowController*)parentWindowController getBrowserWrapper] getTitle:&titleString andHref:&urlString]; - if (!urlString) + // don't allow dragging of proxy icon for empty pages + if ((!urlString) || [MainController isBlankURL:urlString]) return; NSString *cleanedTitle = [titleString stringByReplacingCharactersInSet:[NSCharacterSet controlCharacterSet] withString:@" "]; @@ -106,7 +107,7 @@ [pboard declareURLPasteboardWithAdditionalTypes:[NSArray array] owner:self]; [pboard setDataForURL:urlString title:cleanedTitle]; - + [self dragImage: [MainController createImageForDragging:[self image] title:titleString] at: NSMakePoint(0,0) offset: NSMakeSize(0,0) event: event pasteboard: pboard source: self slideBack: YES];