The plan is to work through the objects, register them, add the files that are required (working through compile and link errors) and then test.
Having registered the bitmap GUID and worked through the comparatively few errors and additional files required, and a crash in the Color Palette class bitmaps read and write. Publishing yielded a blank (missing) image. This is because the file format, under some circumstances" contains a reference to the image as a hard path. The fall-back behavior at publish time for a missing image is to just omit it.
Having a hard path to an image presents some problems for testing. the work around is to have a mechanism that will change the path in a file after the file has been been read. I did this by having a simple class that has a list of files with full paths and will match a file against the list based on the file name - so
/users/scratch/nonsense.jpgwill match against
C:\Documents and Settings\All Users\Sample Pictures\nonsense.jpg"This kind of matching is easily done with Core Foundation's CFURL. CFURLCopyLastPathComponent will get the last path component of a path i.e. nonsense.jpg and URLs can be constructed form POSIX, HFS and Windows paths.
Having added the code - it is clear there are some problems with the publishing. See below:
No comments:
Post a Comment