Esempio n. 1
0
File: sizer.go Progetto: nzlov/wxgo
func (s *sizer) InsertSizerWithUserData(index int, sizer Sizer, proportion int, flag int, border int, userData Object) SizerItem {
	p := s.ptr()
	if p == nil {
		return nil
	}
	var pUserData C.WxObjectPtr
	if userData != nil {
		globalObjectTable.unhold(userData)
		pUserData = userData.ptr()
	}
	if obj := bindObject(C.wxSizer_InsertSizerWithUserData(p, C.long(index), sizer.ptr(), C.int(proportion), C.int(flag), C.int(border), pUserData), false); obj != nil {
		globalObjectTable.unhold(sizer)
		return obj.(SizerItem)
	}
	return nil
}
Esempio n. 2
0
func (s *sizer) InsertSizerWithUserData(index int, sizer Sizer, proportion int, flag int, border int, userData Object) SizerItem {
	p := s.wxPtr()
	if p == nil {
		return nil
	}
	var pUserData C.WxObjectPtr
	if userData != nil {
		userData.unhold()
		pUserData = userData.wxPtr()
	}
	if obj := NewObjectFromPtr(C.wxSizer_InsertSizerWithUserData(p, C.long(index), sizer.wxPtr(), C.int(proportion), C.int(flag), C.int(border), pUserData), false); obj != nil {
		sizer.unhold()
		return obj.(SizerItem)
	}
	return nil
}