gui/pkg/clipboard/platform.go
Claude 168dd37cb0
Some checks are pending
Security Scan / security (push) Waiting to run
Test / test (push) Waiting to run
Implement missing GUI RFC route and preload features
2026-04-14 16:37:23 +01:00

25 lines
616 B
Go

package clipboard
// Platform abstracts the system clipboard backend.
type Platform interface {
Text() (string, bool)
SetText(text string) bool
}
// ImagePlatform is an optional extension for clipboard backends that support images.
type ImagePlatform interface {
Image() ([]byte, bool)
SetImage(data []byte) bool
}
// ClipboardContent is the result of QueryText.
type ClipboardContent struct {
Text string `json:"text"`
HasContent bool `json:"hasContent"`
}
// ImageContent is the result of QueryImage.
type ImageContent struct {
Data []byte `json:"data"`
HasImage bool `json:"hasImage"`
}