blob: 887f343c189c0f6c44988fdfcfb6a58c3e4e641e (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
|
/* 28 february 2014 */
/* apparently this header is included by other headers generated by cgo, wrecking the structures below, so wheee include guards */
/* the change that introduced this was [master 9b4e30c] ("Started to build a single global delegate object; now to fix issues.") */
#ifndef __GO_UI_OBJC_DARWIN_H__
#define __GO_UI_OBJC_DARWIN_H__
/* the Objective-C runtime headers, for id */
#include <objc/message.h>
#include <objc/objc.h>
#include <objc/runtime.h>
#include <stdint.h>
/* wrapper types since the meaning of NSRect, NSSize, and NSPoint are CPU architectured-dependent; also because they're in an Objective-C-only header */
struct xrect {
intptr_t x;
intptr_t y;
intptr_t width;
intptr_t height;
};
struct xsize {
intptr_t width;
intptr_t height;
};
struct xpoint {
intptr_t x;
intptr_t y;
};
/* objc_darwin.m */
extern id toNSString(char *);
extern char *fromNSString(id);
extern void display(id);
extern struct xrect frame(id);
extern id makeScrollView(id);
extern void giveScrollViewBezelBorder(id);
extern id scrollViewContent(id);
#endif
|