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

Manage CAPS_LOCK and NUM_LOCK keys #588

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

dpino
Copy link
Member

@dpino dpino commented Jul 6, 2023

Depends on WebPlatformForEmbedded/libwpe#128.

Implement handling of CAPS_LOCK and NUM_LOCK for several layers (GTK4, Wayland, X11).

@dpino dpino marked this pull request as draft July 6, 2023 05:34
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.

There's an issue in the patch, please see the comment about mixing C and C++ code below.

static bool initialized = false;

if (!initialized) {
GUniqueOutPtr<GdkKeymapKey> keys;
Copy link
Member

Choose a reason for hiding this comment

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

This won't work on a plain C source. It looks like you were picking from C++ code from elsewhere, so this will need adapting to compile as C99.

@@ -340,6 +340,18 @@ on_scroll(GtkEventControllerScroll* controller, double dx,
return TRUE;
}

static gboolean
is_pressed_key(guint keyval)
Copy link
Member

Choose a reason for hiding this comment

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

Small nit: naming this is_key_pressed() would read more naturally.

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