mac docu fixes, mac launcher backport from sauer, etc
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@3372 e016b1c5-ed68-44aa-a2f7-31cac88cffde
This commit is contained in:
@@ -1,8 +1,8 @@
|
||||
#import <Cocoa/Cocoa.h>
|
||||
|
||||
#define _MAXDEFSTR 260
|
||||
#define MAXSTRLEN 260
|
||||
inline char *s_strncpy(char *d, const char *s, size_t m) { strncpy(d,s,m); d[m-1] = 0; return d; };
|
||||
inline char *s_strcat(char *d, const char *s) { size_t n = strlen(d); return s_strncpy(d+n,s,_MAXDEFSTR-n); };
|
||||
inline char *s_strcat(char *d, const char *s) { size_t n = strlen(d); return s_strncpy(d+n,s,MAXSTRLEN-n); };
|
||||
|
||||
void mac_pasteconsole(char *commandbuf)
|
||||
{
|
||||
@@ -13,4 +13,16 @@ void mac_pasteconsole(char *commandbuf)
|
||||
if (contents != nil)
|
||||
s_strcat(commandbuf, [contents lossyCString]);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
* 0x1030 = 10.3
|
||||
* 0x1040 = 10.4
|
||||
* 0x1050 = 10.5
|
||||
*/
|
||||
int mac_osversion()
|
||||
{
|
||||
SInt32 MacVersion;
|
||||
Gestalt(gestaltSystemVersion, &MacVersion);
|
||||
return MacVersion;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user