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

wl: Remove CogWlPlatform::init_web_view() #632

Conversation

psaavedra
Copy link
Member

All the initialization done in the init_web_view() is now relocated inside of the cog_wl_view_init(). To make this possible all the code related to the "run-file-chooser" and "mouse-target-changed" signals have be moved from the cog-platform-wl to the cog-view-wl.

This change makes the Wayland platform compatible with the check implemented in the cog_platform_init_web_view(): "CogWlPlatform class defines both .get_view_type and .init_web_view the latter should be removed."

Also adds again the early return in cog_platform_init_web_view() if class defines both .get_view_type and .init_web_view.

@psaavedra psaavedra self-assigned this Oct 26, 2023
@psaavedra psaavedra force-pushed the psaavedra/fix_defines_both_get_view_type_and_init_web_view_warning branch from 91cc7d1 to 24bd92d Compare October 26, 2023 21:05
Copy link
Member

@aperezdc aperezdc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice, thanks for the fix. There's only one small nit to fix before landing.

platform/wayland/cog-view-wl.c Outdated Show resolved Hide resolved
Copy link
Member

@aperezdc aperezdc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Feel free to push the small fix and land the PR, @psaavedra 🙏🏼

All the initialization done in the init_web_view() is now relocated
inside of the cog_wl_view_init(). To make this possible all the code
related to the "run-file-chooser" and "mouse-target-changed" signals
have be moved from the cog-platform-wl to the cog-view-wl.

This change makes the Wayland platform compatible with the check
implemented in the cog_platform_init_web_view(): "CogWlPlatform class
defines both .get_view_type and .init_web_view the latter should be
removed."
... if class defines both .get_view_type and .init_web_view.

This brings again the change reverted in "wl: Remove early return on
cog_platform_init_web_view()".
@psaavedra psaavedra force-pushed the psaavedra/fix_defines_both_get_view_type_and_init_web_view_warning branch from 24bd92d to e9bbd74 Compare October 27, 2023 10:22
@psaavedra psaavedra merged commit 234b137 into master Oct 27, 2023
5 checks passed
@psaavedra psaavedra deleted the psaavedra/fix_defines_both_get_view_type_and_init_web_view_warning branch October 27, 2023 10:57
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.

2 participants