Beispiel #1
0
func NewParamSpecFromCPointer(p unsafe.Pointer) *ParamSpec {
	ret := &ParamSpec{
		NewTraitParamSpec(p),
		p,
	}
	C.g_object_ref_sink(C.gpointer(p))
	runtime.SetFinalizer(ret, func(p *ParamSpec) {
		C.g_object_unref(C.gpointer(unsafe.Pointer(p.CPointer)))
	})
	return ret
}
Beispiel #2
0
func NewObjectFromCPointer(p unsafe.Pointer) *Object {
	ret := &Object{
		NewTraitObject(p),
		p,
	}
	C.g_object_ref_sink(C.gpointer(p))
	runtime.SetFinalizer(ret, func(p *Object) {
		C.g_object_unref(C.gpointer(unsafe.Pointer(p.CPointer)))
	})
	return ret
}
Beispiel #3
0
func NewAppLaunchContextFromCPointer(p unsafe.Pointer) *AppLaunchContext {
	ret := &AppLaunchContext{
		NewTraitAppLaunchContext(p),
		p,
	}
	C.g_object_ref_sink(C.gpointer(p))
	runtime.SetFinalizer(ret, func(p *AppLaunchContext) {
		C.g_object_unref(C.gpointer(unsafe.Pointer(p.CPointer)))
	})
	return ret
}
Beispiel #4
0
func NewInitiallyUnownedFromCPointer(p unsafe.Pointer) *InitiallyUnowned {
	ret := &InitiallyUnowned{
		NewTraitInitiallyUnowned(p),
		NewTraitObject(p),
		p,
	}
	C.g_object_ref_sink(C.gpointer(p))
	runtime.SetFinalizer(ret, func(p *InitiallyUnowned) {
		C.g_object_unref(C.gpointer(unsafe.Pointer(p.CPointer)))
	})
	return ret
}
Beispiel #5
0
func NewInputStreamFromCPointer(p unsafe.Pointer) *InputStream {
	ret := &InputStream{
		NewTraitInputStream(p),
		gobject.NewTraitObject(p),
		p,
	}
	C.g_object_ref_sink(C.gpointer(p))
	runtime.SetFinalizer(ret, func(p *InputStream) {
		C.g_object_unref(C.gpointer(unsafe.Pointer(p.CPointer)))
	})
	return ret
}
Beispiel #6
0
func NewFilenameCompleterFromCPointer(p unsafe.Pointer) *FilenameCompleter {
	ret := &FilenameCompleter{
		NewTraitFilenameCompleter(p),
		gobject.NewTraitObject(p),
		p,
	}
	C.g_object_ref_sink(C.gpointer(p))
	runtime.SetFinalizer(ret, func(p *FilenameCompleter) {
		C.g_object_unref(C.gpointer(unsafe.Pointer(p.CPointer)))
	})
	return ret
}
Beispiel #7
0
func NewDesktopAppInfoFromCPointer(p unsafe.Pointer) *DesktopAppInfo {
	ret := &DesktopAppInfo{
		NewTraitDesktopAppInfo(p),
		gobject.NewTraitObject(p),
		p,
	}
	C.g_object_ref_sink(C.gpointer(p))
	runtime.SetFinalizer(ret, func(p *DesktopAppInfo) {
		C.g_object_unref(C.gpointer(unsafe.Pointer(p.CPointer)))
	})
	return ret
}
Beispiel #8
0
func NewDBusMethodInvocationFromCPointer(p unsafe.Pointer) *DBusMethodInvocation {
	ret := &DBusMethodInvocation{
		NewTraitDBusMethodInvocation(p),
		gobject.NewTraitObject(p),
		p,
	}
	C.g_object_ref_sink(C.gpointer(p))
	runtime.SetFinalizer(ret, func(p *DBusMethodInvocation) {
		C.g_object_unref(C.gpointer(unsafe.Pointer(p.CPointer)))
	})
	return ret
}
Beispiel #9
0
func NewCredentialsFromCPointer(p unsafe.Pointer) *Credentials {
	ret := &Credentials{
		NewTraitCredentials(p),
		gobject.NewTraitObject(p),
		p,
	}
	C.g_object_ref_sink(C.gpointer(p))
	runtime.SetFinalizer(ret, func(p *Credentials) {
		C.g_object_unref(C.gpointer(unsafe.Pointer(p.CPointer)))
	})
	return ret
}
Beispiel #10
0
func NewVfsFromCPointer(p unsafe.Pointer) *Vfs {
	ret := &Vfs{
		NewTraitVfs(p),
		gobject.NewTraitObject(p),
		p,
	}
	C.g_object_ref_sink(C.gpointer(p))
	runtime.SetFinalizer(ret, func(p *Vfs) {
		C.g_object_unref(C.gpointer(unsafe.Pointer(p.CPointer)))
	})
	return ret
}
Beispiel #11
0
func NewSimpleActionGroupFromCPointer(p unsafe.Pointer) *SimpleActionGroup {
	ret := &SimpleActionGroup{
		NewTraitSimpleActionGroup(p),
		gobject.NewTraitObject(p),
		p,
	}
	C.g_object_ref_sink(C.gpointer(p))
	runtime.SetFinalizer(ret, func(p *SimpleActionGroup) {
		C.g_object_unref(C.gpointer(unsafe.Pointer(p.CPointer)))
	})
	return ret
}
Beispiel #12
0
func NewPropertyActionFromCPointer(p unsafe.Pointer) *PropertyAction {
	ret := &PropertyAction{
		NewTraitPropertyAction(p),
		gobject.NewTraitObject(p),
		p,
	}
	C.g_object_ref_sink(C.gpointer(p))
	runtime.SetFinalizer(ret, func(p *PropertyAction) {
		C.g_object_unref(C.gpointer(unsafe.Pointer(p.CPointer)))
	})
	return ret
}
Beispiel #13
0
func NewNetworkServiceFromCPointer(p unsafe.Pointer) *NetworkService {
	ret := &NetworkService{
		NewTraitNetworkService(p),
		gobject.NewTraitObject(p),
		p,
	}
	C.g_object_ref_sink(C.gpointer(p))
	runtime.SetFinalizer(ret, func(p *NetworkService) {
		C.g_object_unref(C.gpointer(unsafe.Pointer(p.CPointer)))
	})
	return ret
}
Beispiel #14
0
func NewMenuModelFromCPointer(p unsafe.Pointer) *MenuModel {
	ret := &MenuModel{
		NewTraitMenuModel(p),
		gobject.NewTraitObject(p),
		p,
	}
	C.g_object_ref_sink(C.gpointer(p))
	runtime.SetFinalizer(ret, func(p *MenuModel) {
		C.g_object_unref(C.gpointer(unsafe.Pointer(p.CPointer)))
	})
	return ret
}
Beispiel #15
0
func NewTypeModuleFromCPointer(p unsafe.Pointer) *TypeModule {
	ret := &TypeModule{
		NewTraitTypeModule(p),
		NewTraitObject(p),
		p,
	}
	C.g_object_ref_sink(C.gpointer(p))
	runtime.SetFinalizer(ret, func(p *TypeModule) {
		C.g_object_unref(C.gpointer(unsafe.Pointer(p.CPointer)))
	})
	return ret
}
Beispiel #16
0
func NewUnixFDListFromCPointer(p unsafe.Pointer) *UnixFDList {
	ret := &UnixFDList{
		NewTraitUnixFDList(p),
		gobject.NewTraitObject(p),
		p,
	}
	C.g_object_ref_sink(C.gpointer(p))
	runtime.SetFinalizer(ret, func(p *UnixFDList) {
		C.g_object_unref(C.gpointer(unsafe.Pointer(p.CPointer)))
	})
	return ret
}
Beispiel #17
0
func NewCharsetConverterFromCPointer(p unsafe.Pointer) *CharsetConverter {
	ret := &CharsetConverter{
		NewTraitCharsetConverter(p),
		gobject.NewTraitObject(p),
		p,
	}
	C.g_object_ref_sink(C.gpointer(p))
	runtime.SetFinalizer(ret, func(p *CharsetConverter) {
		C.g_object_unref(C.gpointer(unsafe.Pointer(p.CPointer)))
	})
	return ret
}
Beispiel #18
0
func NewSimpleProxyResolverFromCPointer(p unsafe.Pointer) *SimpleProxyResolver {
	ret := &SimpleProxyResolver{
		NewTraitSimpleProxyResolver(p),
		gobject.NewTraitObject(p),
		p,
	}
	C.g_object_ref_sink(C.gpointer(p))
	runtime.SetFinalizer(ret, func(p *SimpleProxyResolver) {
		C.g_object_unref(C.gpointer(unsafe.Pointer(p.CPointer)))
	})
	return ret
}
Beispiel #19
0
func NewZlibDecompressorFromCPointer(p unsafe.Pointer) *ZlibDecompressor {
	ret := &ZlibDecompressor{
		NewTraitZlibDecompressor(p),
		gobject.NewTraitObject(p),
		p,
	}
	C.g_object_ref_sink(C.gpointer(p))
	runtime.SetFinalizer(ret, func(p *ZlibDecompressor) {
		C.g_object_unref(C.gpointer(unsafe.Pointer(p.CPointer)))
	})
	return ret
}
Beispiel #20
0
func NewSocketAddressEnumeratorFromCPointer(p unsafe.Pointer) *SocketAddressEnumerator {
	ret := &SocketAddressEnumerator{
		NewTraitSocketAddressEnumerator(p),
		gobject.NewTraitObject(p),
		p,
	}
	C.g_object_ref_sink(C.gpointer(p))
	runtime.SetFinalizer(ret, func(p *SocketAddressEnumerator) {
		C.g_object_unref(C.gpointer(unsafe.Pointer(p.CPointer)))
	})
	return ret
}
Beispiel #21
0
func NewAppInfoMonitorFromCPointer(p unsafe.Pointer) *AppInfoMonitor {
	ret := &AppInfoMonitor{
		NewTraitAppInfoMonitor(p),
		gobject.NewTraitObject(p),
		p,
	}
	C.g_object_ref_sink(C.gpointer(p))
	runtime.SetFinalizer(ret, func(p *AppInfoMonitor) {
		C.g_object_unref(C.gpointer(unsafe.Pointer(p.CPointer)))
	})
	return ret
}
Beispiel #22
0
func NewSocketControlMessageFromCPointer(p unsafe.Pointer) *SocketControlMessage {
	ret := &SocketControlMessage{
		NewTraitSocketControlMessage(p),
		gobject.NewTraitObject(p),
		p,
	}
	C.g_object_ref_sink(C.gpointer(p))
	runtime.SetFinalizer(ret, func(p *SocketControlMessage) {
		C.g_object_unref(C.gpointer(unsafe.Pointer(p.CPointer)))
	})
	return ret
}
Beispiel #23
0
func NewDBusServerFromCPointer(p unsafe.Pointer) *DBusServer {
	ret := &DBusServer{
		NewTraitDBusServer(p),
		gobject.NewTraitObject(p),
		p,
	}
	C.g_object_ref_sink(C.gpointer(p))
	runtime.SetFinalizer(ret, func(p *DBusServer) {
		C.g_object_unref(C.gpointer(unsafe.Pointer(p.CPointer)))
	})
	return ret
}
Beispiel #24
0
func NewSubprocessLauncherFromCPointer(p unsafe.Pointer) *SubprocessLauncher {
	ret := &SubprocessLauncher{
		NewTraitSubprocessLauncher(p),
		gobject.NewTraitObject(p),
		p,
	}
	C.g_object_ref_sink(C.gpointer(p))
	runtime.SetFinalizer(ret, func(p *SubprocessLauncher) {
		C.g_object_unref(C.gpointer(unsafe.Pointer(p.CPointer)))
	})
	return ret
}
Beispiel #25
0
func NewEmblemedIconFromCPointer(p unsafe.Pointer) *EmblemedIcon {
	ret := &EmblemedIcon{
		NewTraitEmblemedIcon(p),
		gobject.NewTraitObject(p),
		p,
	}
	C.g_object_ref_sink(C.gpointer(p))
	runtime.SetFinalizer(ret, func(p *EmblemedIcon) {
		C.g_object_unref(C.gpointer(unsafe.Pointer(p.CPointer)))
	})
	return ret
}
Beispiel #26
0
func NewTlsCertificateFromCPointer(p unsafe.Pointer) *TlsCertificate {
	ret := &TlsCertificate{
		NewTraitTlsCertificate(p),
		gobject.NewTraitObject(p),
		p,
	}
	C.g_object_ref_sink(C.gpointer(p))
	runtime.SetFinalizer(ret, func(p *TlsCertificate) {
		C.g_object_unref(C.gpointer(unsafe.Pointer(p.CPointer)))
	})
	return ret
}
Beispiel #27
0
func NewInetAddressMaskFromCPointer(p unsafe.Pointer) *InetAddressMask {
	ret := &InetAddressMask{
		NewTraitInetAddressMask(p),
		gobject.NewTraitObject(p),
		p,
	}
	C.g_object_ref_sink(C.gpointer(p))
	runtime.SetFinalizer(ret, func(p *InetAddressMask) {
		C.g_object_unref(C.gpointer(unsafe.Pointer(p.CPointer)))
	})
	return ret
}
Beispiel #28
0
func NewCancellableFromCPointer(p unsafe.Pointer) *Cancellable {
	ret := &Cancellable{
		NewTraitCancellable(p),
		gobject.NewTraitObject(p),
		p,
	}
	C.g_object_ref_sink(C.gpointer(p))
	runtime.SetFinalizer(ret, func(p *Cancellable) {
		C.g_object_unref(C.gpointer(unsafe.Pointer(p.CPointer)))
	})
	return ret
}
Beispiel #29
0
func NewApplicationCommandLineFromCPointer(p unsafe.Pointer) *ApplicationCommandLine {
	ret := &ApplicationCommandLine{
		NewTraitApplicationCommandLine(p),
		gobject.NewTraitObject(p),
		p,
	}
	C.g_object_ref_sink(C.gpointer(p))
	runtime.SetFinalizer(ret, func(p *ApplicationCommandLine) {
		C.g_object_unref(C.gpointer(unsafe.Pointer(p.CPointer)))
	})
	return ret
}
Beispiel #30
0
func NewTlsPasswordFromCPointer(p unsafe.Pointer) *TlsPassword {
	ret := &TlsPassword{
		NewTraitTlsPassword(p),
		gobject.NewTraitObject(p),
		p,
	}
	C.g_object_ref_sink(C.gpointer(p))
	runtime.SetFinalizer(ret, func(p *TlsPassword) {
		C.g_object_unref(C.gpointer(unsafe.Pointer(p.CPointer)))
	})
	return ret
}