bug-gnustep
[Top][All Lists]
Advanced

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

[bug #15348] Failure when using -[NSNib initWithNibNamed:bundle:]


From: Chris Armstrong
Subject: [bug #15348] Failure when using -[NSNib initWithNibNamed:bundle:]
Date: Mon, 2 Jan 2006 04:26:01 +0000
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8) Gecko/20051224 Debian/1.5.dfsg-3 Firefox/1.5

URL:
  <http://savannah.gnu.org/bugs/?func=detailitem&item_id=15348>

                 Summary: Failure when using -[NSNib
initWithNibNamed:bundle:]
                 Project: GNUstep
            Submitted by: carmstrong
            Submitted on: Mon 01/02/06 at 04:26
                Category: Gui/AppKit
                Severity: 3 - Normal
              Item Group: Bug
                  Status: None
                 Privacy: Public
             Assigned to: None
             Open/Closed: Open

    _______________________________________________________

Details:

I'm thinking no one's ever used this method before.

I'm running the following code:

  NSNib* myNib = [[NSNib alloc] initWithNibNamed:@"imageviewdemo"
bundle:[NSBundle mainBundle]];
  [myNib instantiateNibWithOwner:[ImageController new]
topLevelObjects:NULL];

and getting the following error message:

2006-01-02 15:19:48.418 imageviewdemo[17777] File NSData.m: 166. In
readContentsOfFile Open
/home/chris/DOCS/AppKit/imageviewdemo/imageviewdemo.debug/Resources/English.lproj/imageviewdemo.gorm/imageviewdemo)
attempt failed - No such file or directory

this is the wrong path for the "objects.gorm" file it should be getting at. A
check of the source code reveals that it builds the path name using the
"nibNamed" variable as follows:

[path to resource directory]/[nibNamed].gorm/[nibNamed]

This is incorrect, as such a file does not exist. I think we change line 181
from:

fileName = [bundlePath stringByAppendingPathComponent: nibNamed];

to

fileName = [bundlePath stringByAppendingString:@"objects.gorm"];

Or whatever this is supposed to be (I could be wrong, but this doesn't work
on my machine.







    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?func=detailitem&item_id=15348>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/





reply via email to

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