Decrease false positives on untitled window detection

The detection algorithm is still dumb; it now thinks a window is
untitled (i.e. good for opening new files in) when its title begins with
"[No Name] - VIM".  This means that it now rejects modified buffers
which haven't been saved to a file.
This commit is contained in:
Bjorn Winckler
2008-01-31 16:24:45 +01:00
parent f2740bd858
commit 3b98d9f0dc
+1 -1
View File
@@ -967,7 +967,7 @@ typedef struct
// TODO: This is a moronic test...should query the Vim process if there
// are any open buffers or something like that instead.
NSString *title = [[[vc windowController] window] title];
if ([title hasPrefix:@"[No Name]"]) {
if ([title hasPrefix:@"[No Name] - VIM"]) {
//NSLog(@"found untitled window");
return vc;
}