Skip to main content

Mountain/Vine/Server/Notification/
WindowShowTextDocument.rs

1#![allow(non_snake_case)]
2//! Cocoon → Mountain `window.showTextDocument` notification.
3//! Fires when an extension calls
4//! `vscode.window.showTextDocument(uri, options)`. Extension activation
5//! commonly uses this for "jump to definition" and "reveal config".
6//! Forwarded on `sky://window/showTextDocument`.
7
8use serde_json::Value;
9use tauri::Emitter;
10
11use crate::{Vine::Server::MountainVinegRPCService::MountainVinegRPCService, dev_log};
12
13pub async fn WindowShowTextDocument(Service:&MountainVinegRPCService, Parameter:&Value) {
14	if let Err(Error) = Service.ApplicationHandle().emit("sky://window/showTextDocument", Parameter) {
15		dev_log!(
16			"grpc",
17			"warn: [MountainVinegRPCService] sky://window/showTextDocument emit failed: {}",
18			Error
19		);
20	}
21}