42 lines
1.3 KiB
TypeScript
42 lines
1.3 KiB
TypeScript
/// <reference types="vite/client" />
|
|
|
|
interface ProcessedDesktopSource {
|
|
id: string;
|
|
name: string;
|
|
display_id: string;
|
|
thumbnail: string | null;
|
|
appIcon: string | null;
|
|
}
|
|
|
|
interface Window {
|
|
electronAPI: {
|
|
getSources: (opts: Electron.SourcesOptions) => Promise<ProcessedDesktopSource[]>
|
|
switchToEditor: () => Promise<void>
|
|
openSourceSelector: () => Promise<void>
|
|
selectSource: (source: any) => Promise<any>
|
|
getSelectedSource: () => Promise<any>
|
|
startMouseTracking: () => Promise<{ success: boolean; startTime?: number }>
|
|
stopMouseTracking: () => Promise<{ success: boolean; data?: any }>
|
|
storeRecordedVideo: (videoData: ArrayBuffer, fileName: string) => Promise<{
|
|
success: boolean
|
|
path?: string
|
|
message: string
|
|
error?: string
|
|
}>
|
|
storeMouseTrackingData: (fileName: string) => Promise<{
|
|
success: boolean
|
|
path?: string
|
|
eventCount?: number
|
|
message: string
|
|
error?: string
|
|
}>
|
|
getRecordedVideoPath: () => Promise<{
|
|
success: boolean
|
|
path?: string
|
|
message?: string
|
|
error?: string
|
|
}>
|
|
setRecordingState: (recording: boolean) => Promise<void>
|
|
onStopRecordingFromTray: (callback: () => void) => () => void
|
|
}
|
|
} |