Skip to content

Commit

Permalink
Add clang format to action (#15)
Browse files Browse the repository at this point in the history
  • Loading branch information
wengxt authored May 20, 2024
1 parent 602d5d6 commit 5a7b29f
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 5 deletions.
14 changes: 12 additions & 2 deletions .github/workflows/check.yml
Original file line number Diff line number Diff line change
@@ -1,16 +1,26 @@
name: CI

on:
push:
branches:
- master
pull_request:
branches:
- master

jobs:
clang-format:
name: Check clang-format
runs-on: ubuntu-latest
container: archlinux:latest
steps:
- name: Install dependencies
run: |
pacman -Syu --noconfirm git clang diffutils
git config --global --add safe.directory $GITHUB_WORKSPACE
- uses: actions/checkout@v4
- uses: fcitx/github-actions@clang-format
check:
name: Build and test
needs: clang-format
runs-on: ubuntu-latest
container: archlinux:latest
strategy:
Expand Down
8 changes: 5 additions & 3 deletions src/imclient.c
Original file line number Diff line number Diff line change
Expand Up @@ -1486,12 +1486,14 @@ bool xcb_xim_unset_ic_focus(xcb_xim_t *im, xcb_xic_t ic) {
return !fail;
}

bool xcb_xim_forward_event(xcb_xim_t *im, xcb_xic_t ic, xcb_key_press_event_t *event) {
return xcb_xim_forward_event_full(im, ic, (im->event_sequence >> 16), event);
bool xcb_xim_forward_event(xcb_xim_t *im, xcb_xic_t ic,
xcb_key_press_event_t *event) {
return xcb_xim_forward_event_full(im, ic, (im->event_sequence >> 16),
event);
}

bool xcb_xim_forward_event_full(xcb_xim_t *im, xcb_xic_t ic, uint16_t sequence,
xcb_key_press_event_t *event) {
xcb_key_press_event_t *event) {
xcb_xim_request_queue_t *queue =
_xcb_xim_new_request(im, XCB_XIM_FORWARD_EVENT, 0, NULL, NULL);
if (!queue) {
Expand Down

0 comments on commit 5a7b29f

Please sign in to comment.