Instance Property

frontmostApplication

Returns the frontmost app, which is the app that receives key events.

Declaration

@property(readonly, strong) NSRunningApplication *frontmostApplication;

Return Value

The running app instance for the app that receives key events.

Discussion

This value is key-value observing compliant.

See Also

Requesting Information

getInfoForFile:application:type:

Retrieves information about the specified file.

URLForApplicationToOpenURL:

Returns the URL to the default app that would be used to open the given URL.

fullPathForApplication:

Returns the full path for the specified app.

isFilePackageAtPath:

Determines whether the specified path is a file package.

runningApplications

Returns an array of NSRunningApplication representing the running apps.

menuBarOwningApplication

Returns the app that owns the currently displayed menu bar.