• 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: what happend of the .hidden file in Tiger?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: what happend of the .hidden file in Tiger?


  • Subject: Re: what happend of the .hidden file in Tiger?
  • From: James Bucanek <email@hidden>
  • Date: Fri, 26 Aug 2005 09:54:04 -0700

Giovanni Donelli wrote on Friday, August 26, 2005:

>Hi Folks,
>     I'm trying to remove the hidden files from the content of a
>directory.
>
>1st.    I'm first checking if the name start with a dot: "."
>2nd.   I'm using the launch services to determine whether the hidden
>flag is on
>
>Still few hidden files are left out from this (such as the mach
>kernel in the disk root)
>
>now... there was suppose to be a file called ".hidden" in the
>directory which would have listed other hidden files... however I
>can't find this file anywhere in Tiger
>
>Anybody any suggestions?

Stop trying to second guess the OS and just ask Launch Services if the item is hidden or not:


    LSItemInfoRecord    itemInfo;
    err = LSCopyItemInfoForRef(&itemRef,kLSRequestBasicFlagsOnly,&itemInfo);
    if ( (itemInfo.flags&kLSItemInfoIsInvisible) != 0 )
        {
        // item is invisible...

This is the exact same interface the Finder and most other system frameworks use. It applies all of the rules that OS X uses to determine if a file should normally be hidden from the user. And will continue to do so in the future, even if those rules change.

--
James Bucanek
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: what happend of the .hidden file in Tiger?
      • From: Mason Mark <email@hidden>
    • Re: what happend of the .hidden file in Tiger?
      • From: Giovanni Donelli <email@hidden>
References: 
 >what happend of the .hidden file in Tiger? (From: Giovanni Donelli <email@hidden>)

  • Prev by Date: Re: Finding transparent pixels in an image
  • Next by Date: Re: how can one programmatically check if text fits in cells and text-views?
  • Previous by thread: what happend of the .hidden file in Tiger?
  • Next by thread: Re: what happend of the .hidden file in Tiger?
  • Index(es):
    • Date
    • Thread