Where is the AMPathPopUpButton class declared?

623 views Asked by At

I stumbled upon the AMPathPopUpButton control in the Interface Builder, but every time I try to use it, the compiler notified me

Use of undeclared type 'AMPathPopUpButton'.

According to some search, it should be in the Automator framework. But after I import the framework, I still have no luck.

I suspect that this control may have been deprecated, however, it is still available in Interface Builder, and I couldn't find any information about its retirement.

Is it still usable in code? If yes, what should I import or do?

1

There are 1 answers

2
Dalmazio On

You should link against the Automator framework, and use a forward class declaration for the button type:

  1. Go to your target's Build Phases and add Automator.framework to the Link Binary with Libraries build phase.

  2. In your interface/implementation file that declares or references the AMPathPopUpButton type, use a forward class declaration instead of trying to import a header file:

    @class AMPathPopUpButton;