naev 0.12.6
glue_macos.m File Reference

Support code for macOS. More...

#include "glue_macos.h"
import <Foundation/Foundation.h>
Include dependency graph for glue_macos.m:

Go to the source code of this file.

Functions

static int macos_writeString (NSString *str, char *res, size_t n)
 Write an NSString to a C buffer.
int macos_isBundle (void)
 Determine if we're running from inside an app bundle.
int macos_resourcesPath (char *res, size_t n)
 Get the path to the bundle resources directory.
static int macos_userLibraryDir (NSString *kind, char *res, size_t n)
 Get the path to the specified user directory.
int macos_configPath (char *res, size_t n)
 Get the config directory path.
int macos_cachePath (char *res, size_t n)
 Get the cache directory path.

Detailed Description

Support code for macOS.

The functions here deal with the macOS parts that call into Objective-C land.

Definition in file glue_macos.m.

Function Documentation

◆ macos_cachePath()

int macos_cachePath ( char * res,
size_t n )

Get the cache directory path.

Definition at line 68 of file glue_macos.m.

◆ macos_configPath()

int macos_configPath ( char * res,
size_t n )

Get the config directory path.

Definition at line 60 of file glue_macos.m.

◆ macos_isBundle()

int macos_isBundle ( void )

Determine if we're running from inside an app bundle.

Definition at line 28 of file glue_macos.m.

◆ macos_resourcesPath()

int macos_resourcesPath ( char * res,
size_t n )

Get the path to the bundle resources directory.

Definition at line 37 of file glue_macos.m.

◆ macos_userLibraryDir()

int macos_userLibraryDir ( NSString * kind,
char * res,
size_t n )
static

Get the path to the specified user directory.

Definition at line 46 of file glue_macos.m.

◆ macos_writeString()

int macos_writeString ( NSString * str,
char * res,
size_t n )
static

Write an NSString to a C buffer.

Definition at line 17 of file glue_macos.m.