HelloFS doses not load the file icon

29 views
Skip to first unread message

Karthick R

unread,
Apr 23, 2015, 8:06:09 AM4/23/15
to osxfus...@googlegroups.com
Hi,

I downloaded and ran the helloFS sample, it loads the supplied custom icon successfully, i just supplied my own icns file instead of "hellodoc.icns" but still the app loads the "hellodoc.icns" file but not my icns file. I am not sure what is wrong. Please help me. Below shown is the method from which the icns data is returned.

- (NSDictionary *)resourceAttributesAtPath:(NSString *)path error:(NSError **)error {

  if ([path isEqualToString:helloPath]) {

    NSString *file = [[NSBundle mainBundle] pathForResource:@"hello" ofType:@"icns"];

    return [NSDictionary dictionaryWithObject:[NSData dataWithContentsOfFile:file]

                                       forKey:kGMUserFileSystemCustomIconDataKey];

  }

  return nil;

}

Reply all
Reply to author
Forward
0 new messages