mirror of
https://github.com/gnustep/apps-projectcenter.git
synced 2025-02-20 18:32:17 +00:00
Single click always invokes the internal editor now.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/apps/projectcenter/trunk@12614 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
4ee31e2a7c
commit
6b2f8c69f7
3 changed files with 24 additions and 18 deletions
|
@ -42,6 +42,7 @@
|
|||
|
||||
- (void)setProject:(PCProject *)aProject;
|
||||
|
||||
- (PCEditor *)internalEditorForFile:(NSString *)path;
|
||||
- (PCEditor *)editorForFile:(NSString *)path;
|
||||
- (NSArray *)allEditors;
|
||||
|
||||
|
|
|
@ -79,15 +79,7 @@
|
|||
project = aProject;
|
||||
}
|
||||
|
||||
- (PCEditor *)editorForFile:(NSString *)path
|
||||
{
|
||||
NSUserDefaults *ud = [NSUserDefaults standardUserDefaults];
|
||||
|
||||
if([[ud objectForKey:ExternalEditor] isEqualToString:@"YES"])
|
||||
{
|
||||
[PCEditorController openFileInEditor:path];
|
||||
}
|
||||
else
|
||||
- (PCEditor *)internalEditorForFile:(NSString *)path
|
||||
{
|
||||
PCEditor *editor;
|
||||
|
||||
|
@ -107,6 +99,19 @@
|
|||
return editor;
|
||||
}
|
||||
}
|
||||
|
||||
- (PCEditor *)editorForFile:(NSString *)path
|
||||
{
|
||||
NSUserDefaults *ud = [NSUserDefaults standardUserDefaults];
|
||||
|
||||
if([[ud objectForKey:ExternalEditor] isEqualToString:@"YES"])
|
||||
{
|
||||
[PCEditorController openFileInEditor:path];
|
||||
}
|
||||
else
|
||||
{
|
||||
[self internalEditorForFile:path];
|
||||
}
|
||||
}
|
||||
|
||||
- (NSArray *)allEditors
|
||||
|
|
|
@ -646,7 +646,7 @@
|
|||
[fileNameField setStringValue:fileName];
|
||||
|
||||
// Show the file in the internal editor!
|
||||
e = [editorController editorForFile:p];
|
||||
e = [editorController internalEditorForFile:p];
|
||||
|
||||
if( e == nil )
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue