mcpp index

compat.mtdev

#include

mtdev 1.1.7 — kernel multitouch protocol A to B translation, for libinput

#include <mtdev.h>
mcpp add compat.mtdev@1.1.7

用法

来自本仓库自己的测试项目 —— CI 真的编译并运行过,不是为了网站写的。

// compat.mtdev — behavioral test, no input device required.
//
// mtdev translates kernel multitouch protocol A into protocol B. The test
// exercises the translator's own state machine rather than a device: the
// interesting failure is a package that links but whose slot machinery was
// compiled out, and that shows up here rather than on a touchscreen.

#ifdef __linux__

#include <mtdev.h>
#include <mtdev-plumbing.h>
#include <linux/input.h>

#include <cstdio>
#include <cstring>

namespace {
int failures = 0;
void check(bool ok, const char *what)
{
    std::printf("%-58s %s\n", what, ok ? "ok" : "FAILED");
    if (!ok) ++failures;
// …

tests/examples/mtdev/tests/mtdev.cpp · 项目 tests/examples/mtdev

构建

targets
mtdev (lib)
language
c++23
C standard
c11
import std
no
include dirs
*/include, */src

源文件 (5)

  • */src/caps.c
  • */src/core.c
  • */src/iobuf.c
  • */src/match.c
  • */src/match_four.c

版本

版本平台 镜像sha256
1.1.7 最新 Linux GLOBAL CN a55bd02a9af4…