зеркало из https://github.com/mozilla/gecko-dev.git
Strip whitespace around url (bug 149082)
This commit is contained in:
Родитель
2fd744fdef
Коммит
ae2d20be15
|
@ -585,10 +585,14 @@ static NSString *SearchToolbarItemIdentifier = @"Search Toolbar Item";
|
|||
|
||||
- (IBAction)goToLocationFromToolbarURLField:(id)sender
|
||||
{
|
||||
[self loadURL:[NSURL URLWithString:[sender stringValue]]];
|
||||
// trim off any whitespace around url
|
||||
NSMutableString *theURL = [[NSMutableString alloc] initWithString:[sender stringValue]];
|
||||
CFStringTrimWhitespace((CFMutableStringRef)theURL);
|
||||
[self loadURL:[NSURL URLWithString:theURL]];
|
||||
[theURL release];
|
||||
|
||||
// Focus and activate our content area.
|
||||
[[mBrowserView getBrowserView] setActive: YES];
|
||||
// Focus and activate our content area.
|
||||
[[mBrowserView getBrowserView] setActive: YES];
|
||||
}
|
||||
|
||||
- (void)saveDocument: (NSView*)aFilterView filterList: (NSPopUpButton*)aFilterList
|
||||
|
|
|
@ -585,10 +585,14 @@ static NSString *SearchToolbarItemIdentifier = @"Search Toolbar Item";
|
|||
|
||||
- (IBAction)goToLocationFromToolbarURLField:(id)sender
|
||||
{
|
||||
[self loadURL:[NSURL URLWithString:[sender stringValue]]];
|
||||
// trim off any whitespace around url
|
||||
NSMutableString *theURL = [[NSMutableString alloc] initWithString:[sender stringValue]];
|
||||
CFStringTrimWhitespace((CFMutableStringRef)theURL);
|
||||
[self loadURL:[NSURL URLWithString:theURL]];
|
||||
[theURL release];
|
||||
|
||||
// Focus and activate our content area.
|
||||
[[mBrowserView getBrowserView] setActive: YES];
|
||||
// Focus and activate our content area.
|
||||
[[mBrowserView getBrowserView] setActive: YES];
|
||||
}
|
||||
|
||||
- (void)saveDocument: (NSView*)aFilterView filterList: (NSPopUpButton*)aFilterList
|
||||
|
|
|
@ -585,10 +585,14 @@ static NSString *SearchToolbarItemIdentifier = @"Search Toolbar Item";
|
|||
|
||||
- (IBAction)goToLocationFromToolbarURLField:(id)sender
|
||||
{
|
||||
[self loadURL:[NSURL URLWithString:[sender stringValue]]];
|
||||
// trim off any whitespace around url
|
||||
NSMutableString *theURL = [[NSMutableString alloc] initWithString:[sender stringValue]];
|
||||
CFStringTrimWhitespace((CFMutableStringRef)theURL);
|
||||
[self loadURL:[NSURL URLWithString:theURL]];
|
||||
[theURL release];
|
||||
|
||||
// Focus and activate our content area.
|
||||
[[mBrowserView getBrowserView] setActive: YES];
|
||||
// Focus and activate our content area.
|
||||
[[mBrowserView getBrowserView] setActive: YES];
|
||||
}
|
||||
|
||||
- (void)saveDocument: (NSView*)aFilterView filterList: (NSPopUpButton*)aFilterList
|
||||
|
|
|
@ -585,10 +585,14 @@ static NSString *SearchToolbarItemIdentifier = @"Search Toolbar Item";
|
|||
|
||||
- (IBAction)goToLocationFromToolbarURLField:(id)sender
|
||||
{
|
||||
[self loadURL:[NSURL URLWithString:[sender stringValue]]];
|
||||
// trim off any whitespace around url
|
||||
NSMutableString *theURL = [[NSMutableString alloc] initWithString:[sender stringValue]];
|
||||
CFStringTrimWhitespace((CFMutableStringRef)theURL);
|
||||
[self loadURL:[NSURL URLWithString:theURL]];
|
||||
[theURL release];
|
||||
|
||||
// Focus and activate our content area.
|
||||
[[mBrowserView getBrowserView] setActive: YES];
|
||||
// Focus and activate our content area.
|
||||
[[mBrowserView getBrowserView] setActive: YES];
|
||||
}
|
||||
|
||||
- (void)saveDocument: (NSView*)aFilterView filterList: (NSPopUpButton*)aFilterList
|
||||
|
|
Загрузка…
Ссылка в новой задаче