discuss-gnustep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: GWorkspace openFile & ImageViewer


From: Richard Frith-Macdonald
Subject: Re: GWorkspace openFile & ImageViewer
Date: Wed, 9 Apr 2003 17:41:58 +0100


On Wednesday, April 9, 2003, at 03:37  pm, Enrico Sersale wrote:


On Wed, 9 Apr 2003, Alexander Malmberg wrote:

Enrico Sersale wrote:
[snip]
2)Gorm
Gorm implements application:openFile: and the method is correctly called for the first file when the app is also launched and for the second one,
too. But, in this case (the second file) no window appears.

This might be due to issues with window ordering in NSWindow. I've been looking at this a bit for a while. Try commenting out the line ~1356 in
NSWindow.m? (the "if ([NSApp isActive])" in -orderFront:)

Yes, with line ~1356 commented out all the window are shown.

Well, I don't think the windows should be shown if the app is not active ... so I think this is a bug in the handling of application:openFile: by the gui (combined with focus problems in the backend making the app inactive when it should be active) ... it should make the app active before opening the file rather than assuming that the delegates :openFile: method is going to do it.

I've updated the code to do this. I've also fixed file opening in NSDocumentController based applications (so my hack to Ink.app is not needed) and made the application delete files opened with application:openTempFile: The resulting code seems to work nicely to open files when the app responsible is not active.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]