#include "flutter/shell/platform/linux/fl_keyboard_manager.h"
#include <cstring>
#include <vector>
#include "flutter/shell/platform/embedder/test_utils/key_codes.g.h"
#include "flutter/shell/platform/linux/fl_engine_private.h"
#include "flutter/shell/platform/linux/key_mapping.h"
#include "flutter/shell/platform/linux/testing/fl_mock_binary_messenger.h"
#include "flutter/shell/platform/linux/testing/mock_keymap.h"
#include "gtest/gtest.h"
Go to the source code of this file.
◆ EXPECT_KEY_EVENT
#define EXPECT_KEY_EVENT |
( |
|
RECORD, |
|
|
|
TYPE, |
|
|
|
PHYSICAL, |
|
|
|
LOGICAL, |
|
|
|
CHAR, |
|
|
|
SYNTHESIZED |
|
) |
| |
Value: EXPECT_EQ((RECORD)->event_type, (TYPE)); \
EXPECT_EQ((RECORD)->event_physical, (PHYSICAL)); \
EXPECT_EQ((RECORD)->event_logical, (LOGICAL)); \
EXPECT_STREQ((RECORD)->event_character, (CHAR)); \
EXPECT_EQ((RECORD)->event_synthesized, (SYNTHESIZED));
Definition at line 21 of file fl_keyboard_manager_test.cc.
◆ VERIFY_DOWN
#define VERIFY_DOWN |
( |
|
OUT_LOGICAL, |
|
|
|
OUT_CHAR |
|
) |
| |
Value: EXPECT_EQ(
static_cast<CallRecord*
>(g_ptr_array_index(call_records, 0)) \
->event_type, \
kFlutterKeyEventTypeDown); \
EXPECT_EQ(
static_cast<CallRecord*
>(g_ptr_array_index(call_records, 0)) \
->event_logical, \
(OUT_LOGICAL)); \
EXPECT_STREQ(
static_cast<CallRecord*
>(g_ptr_array_index(call_records, 0)) \
->event_character, \
(OUT_CHAR)); \
EXPECT_EQ(
static_cast<CallRecord*
>(g_ptr_array_index(call_records, 0)) \
->event_synthesized, \
false); \
g_ptr_array_set_size(call_records, 0)
Definition at line 28 of file fl_keyboard_manager_test.cc.
◆ call_record_free()
static void call_record_free |
( |
CallRecord * |
record | ) |
|
|
static |
◆ call_record_new()
static CallRecord* call_record_new |
( |
const FlutterKeyEvent * |
event, |
|
|
FlutterKeyEventCallback |
callback, |
|
|
void * |
callback_user_data |
|
) |
| |
|
static |
◆ call_record_respond()
static void call_record_respond |
( |
CallRecord * |
record, |
|
|
bool |
handled |
|
) |
| |
|
static |