Beispiel #1
0
func (w *Window) Create(width, height int, title string) error {
	w.width = width
	w.height = height
	w.title = title

	return af_call(C.af_create_window(&w.window, C.int(w.width), C.int(w.height), C.CString(w.title)))
}
Beispiel #2
0
func (w *Window) Create(width, height int, title string) error {
	w.width = width
	w.height = height
	w.title = title

	aferr := C.af_create_window(&w.window, C.int(w.width), C.int(w.height), C.CString(w.title))

	if aferr != 0 {
		return ErrCreateWindow
	}

	return nil
}