Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

glib.Take to return nil and gtk.marshal* to allow nil #712

Merged
merged 1 commit into from
Jan 14, 2021

Conversation

diamondburned
Copy link
Contributor

This pull request changes all of Gtk's marshal functions to allow taking a nil *glib.Object. glib.Take will return nil if it is given a nil pointer. The motivation of this change was that certain callbacks might have nil parameters.

This pull request also runs goimports on the whole repository.

hfmrow added a commit to hfmrow/gotk3 that referenced this pull request Jan 7, 2021
…ings

##### Add (Get/Set) methods to GdkRGBA & GdkVisual & GdkDisplayManager bindings

Altered files: 'gdk.go' & 'gdk.go.h'

**NOTICE**:

- GdkDisplayManager (full) *wrapper was made to fit @diamondburned modifications*: `gtk.marshal*` *to allow nil gotk3#712*
- gdk_display_manager_get()
- gdk_display_manager_get_default_display()
- gdk_display_manager_set_default_display()
- gdk_display_manager_list_displays()
- gdk_display_manager_open_display()

- GdkVisualType
- gdk_visual_get_blue_pixel_details()
- gdk_visual_get_depth()
- gdk_visual_get_green_pixel_details()
- gdk_visual_get_red_pixel_details()
- gdk_visual_get_visual_type()
- gdk_visual_get_screen()

###### The following methods (Get/Set) are made for more convenient use of the GdkRGBA object

- GetRed()
- SetRed()
- GetGreen()
- SetGreen()
- GetBlue()
- SetBlue()
- GetAlpha()
- SetAlpha()
hfmrow added a commit to hfmrow/gotk3 that referenced this pull request Jan 7, 2021
…ings

##### Add (Get/Set) methods to GdkRGBA & GdkVisual & GdkDisplayManager bindings

Altered files: 'gdk.go' & 'gdk.go.h'

** NOTICE**: *wrapper was made to fit @diamondburned modifications*: `gtk.marshal*` *to allow nil gotk3#712*

- GdkDisplayManager (full)
- gdk_display_manager_get()
- gdk_display_manager_get_default_display()
- gdk_display_manager_set_default_display()
- gdk_display_manager_list_displays()
- gdk_display_manager_open_display()

- GdkVisualType
- gdk_visual_get_blue_pixel_details()
- gdk_visual_get_depth()
- gdk_visual_get_green_pixel_details()
- gdk_visual_get_red_pixel_details()
- gdk_visual_get_visual_type()
- gdk_visual_get_screen()

###### The following methods (Get/Set) are made for more convenient use of the GdkRGBA object

- GetRed()
- SetRed()
- GetGreen()
- SetGreen()
- GetBlue()
- SetBlue()
- GetAlpha()
- SetAlpha()
@andre-hub andre-hub merged commit 90315ed into gotk3:master Jan 14, 2021
@andre-hub andre-hub added this to the V0.6.0 milestone Jan 14, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants