There can be more than Notion and Miro. AFFiNE(pronounced [ə‘fain]) is a next-gen knowledge base that brings planning, sorting and creating all together. Privacy first, open-source, customizable and ready to use.
TypeScript appcrdteditorelectronknowledge-basemarkdownmironotesnotionnotion-alternativerustrust-langrust-languagetabletableviewwhiteboardwikiworkspace
feat(electron): should listen to app audio input event for isRunning check (#11315)
pengx17ac096f533a44
diff --git a/packages/frontend/native/media_capture/src/macos/screen_capture_kit.rs b/packages/frontend/native/media_capture/src/macos/screen_capture_kit.rsindex 620b224995..149f88eecf 100644--- a/packages/frontend/native/media_capture/src/macos/screen_capture_kit.rs+++ b/packages/frontend/native/media_capture/src/macos/screen_capture_kit.rs@@ -16,8 +16,9 @@ use core_foundation::{use coreaudio::sys::{kAudioHardwarePropertyProcessObjectList, kAudioObjectPropertyElementMain,kAudioObjectPropertyScopeGlobal, kAudioObjectSystemObject, kAudioProcessPropertyBundleID,- kAudioProcessPropertyIsRunning, kAudioProcessPropertyPID, AudioObjectAddPropertyListenerBlock,- AudioObjectID, AudioObjectPropertyAddress, AudioObjectRemovePropertyListenerBlock,+ kAudioProcessPropertyIsRunning, kAudioProcessPropertyIsRunningInput, kAudioProcessPropertyPID,+ AudioObjectAddPropertyListenerBlock, AudioObjectID, AudioObjectPropertyAddress,+ AudioObjectRemovePropertyListenerBlock,};use libc;use napi::{@@ -422,7 +423,7 @@ impl TappableApplication {pub fn get_is_running(&self) -> Result<bool> {// Use catch_unwind to prevent any panicslet result = std::panic::catch_unwind(|| {- match get_process_property(&self.object_id, kAudioProcessPropertyIsRunning) {+ match get_process_property(&self.object_id, kAudioProcessPropertyIsRunningInput) {Ok(is_running) => Ok(is_running),Err(_) => Ok(false),}