• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: adding multiple assets (resources) to a project
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: adding multiple assets (resources) to a project


  • Subject: Re: adding multiple assets (resources) to a project
  • From: Jens Alfke <email@hidden>
  • Date: Thu, 26 Jun 2008 10:58:42 -0700


On 26 Jun '08, at 10:47 AM, email@hidden wrote:

This option works better because it retains the folder structure, but
any time I add new files, I have to delete the top assets folder and add
everything again because the new files are not added automatically to the
“copy bundle resources” build stage.

Um, that shouldn't be so. I've done this in several projects and it has no trouble with newly-added files. If you close and re-open the group in the Xcode tree does the new file show up?


 Another problem I have with this approach is that nsbundle doesn't
 find the files, I have to append the asset path to the path of
 mainbundle to get the correct path.

NSBundle doesn't search the whole directory tree when you ask for a resource; that would be too slow. So yes, you do need to specify the relative path. That's what the -pathForResource:ofType:inDirectory: method is for.


—Jens _______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: adding multiple assets (resources) to a project
      • From: lajos kamocsay <email@hidden>
References: 
 >adding multiple assets (resources) to a project (From: email@hidden)

  • Prev by Date: Re: struct align
  • Next by Date: .jpg to .icns?
  • Previous by thread: adding multiple assets (resources) to a project
  • Next by thread: Re: adding multiple assets (resources) to a project
  • Index(es):
    • Date
    • Thread