MCPcopy Create free account
hub / github.com/NativeScript/SimDeck / send_multitouch

Method send_multitouch

packages/server/src/native/bridge.rs:991–1015  ·  view source on GitHub ↗
(
        &self,
        x1: f64,
        y1: f64,
        x2: f64,
        y2: f64,
        phase: &str,
    )

Source from the content-addressed store, hash-verified

989 }
990
991 pub fn send_multitouch(
992 &self,
993 x1: f64,
994 y1: f64,
995 x2: f64,
996 y2: f64,
997 phase: &str,
998 ) -> Result<(), AppError> {
999 let phase = CString::new(phase).map_err(|e| AppError::bad_request(e.to_string()))?;
1000 unsafe {
1001 let mut error = ptr::null_mut();
1002 bool_result(
1003 ffi::xcw_native_input_send_multitouch(
1004 self.handle,
1005 x1,
1006 y1,
1007 x2,
1008 y2,
1009 phase.as_ptr(),
1010 &mut error,
1011 ),
1012 error,
1013 )
1014 }
1015 }
1016
1017 pub fn send_key(&self, key_code: u16, modifiers: u32) -> Result<(), AppError> {
1018 unsafe {

Callers 4

run_multitouch_framesFunction · 0.45
run_batch_stepFunction · 0.45
run_control_messageFunction · 0.45

Calls 3

bool_resultFunction · 0.85

Tested by

no test coverage detected