-
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathMessageTypes.cs
More file actions
87 lines (61 loc) Β· 3.66 KB
/
Copy pathMessageTypes.cs
File metadata and controls
87 lines (61 loc) Β· 3.66 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
/*
ImageGlass.SDK β ImageGlass 10 Plugins Development Kit
Copyright (C) 2026 DUONG DIEU PHAP
Project homepage: https://imageglass.org
MIT License
*/
namespace ImageGlass.SDK.Tools;
/// <summary>
/// ALL_CAP_SNAKE_CASE constants for the IPC message protocol.
/// </summary>
public static class MessageTypes
{
// Host -> Tool events
/// <summary>Host β tool: sent once after connection to deliver initial settings.</summary>
public const string INIT = "INIT";
/// <summary>Host β tool: the current photo changed or was unloaded.</summary>
public const string PHOTO_CHANGED = "PHOTO_CHANGED";
/// <summary>Host β tool: the application theme changed.</summary>
public const string THEME_CHANGED = "THEME_CHANGED";
/// <summary>Host β tool: the UI language changed.</summary>
public const string LANGUAGE_CHANGED = "LANGUAGE_CHANGED";
/// <summary>Host β tool: the viewer color profile changed.</summary>
public const string COLOR_PROFILE_CHANGED = "COLOR_PROFILE_CHANGED";
/// <summary>Host β tool: the pointer moved over the viewer (requires subscription).</summary>
public const string POINTER_MOVED = "POINTER_MOVED";
/// <summary>Host β tool: the pointer was pressed on the viewer (requires subscription).</summary>
public const string POINTER_PRESSED = "POINTER_PRESSED";
/// <summary>Host β tool: the selection rectangle changed (requires subscription).</summary>
public const string SELECTION_CHANGED = "SELECTION_CHANGED";
/// <summary>Host β tool: the current animation frame changed (requires subscription).</summary>
public const string FRAME_CHANGED = "FRAME_CHANGED";
/// <summary>Host β tool: the tool should shut down and disconnect.</summary>
public const string SHUTDOWN = "SHUTDOWN";
/// <summary>Host β tool: the user invoked the tool's primary action.</summary>
public const string EXECUTE = "EXECUTE";
// Tool -> Host requests / events
/// <summary>Tool β host: read a single pixel color at source coordinates.</summary>
public const string READ_PIXEL = "READ_PIXEL";
/// <summary>Tool β host: acquire the full pixel buffer via a memory-mapped file.</summary>
public const string GET_PIXEL_BUFFER = "GET_PIXEL_BUFFER";
/// <summary>Tool β host: release a previously acquired pixel buffer.</summary>
public const string RELEASE_PIXEL_BUFFER = "RELEASE_PIXEL_BUFFER";
/// <summary>Tool β host: get the source image dimensions.</summary>
public const string GET_SOURCE_SIZE = "GET_SOURCE_SIZE";
/// <summary>Tool β host: get the current selection rectangle.</summary>
public const string GET_SELECTION = "GET_SELECTION";
/// <summary>Tool β host: set or clear the selection rectangle.</summary>
public const string SET_SELECTION = "SET_SELECTION";
/// <summary>Tool β host: enable or disable selection mode on the viewer.</summary>
public const string ENABLE_SELECTION = "ENABLE_SELECTION";
/// <summary>Tool β host: declare which real-time events the tool wants to receive.</summary>
public const string SUBSCRIBE_EVENTS = "SUBSCRIBE_EVENTS";
/// <summary>Tool β host: invoke a named ImageGlass API method.</summary>
public const string RUN_API = "RUN_API";
/// <summary>Tool β host: get metadata for the current photo.</summary>
public const string GET_PHOTO_METADATA = "GET_PHOTO_METADATA";
/// <summary>Tool β host: get the list of photos in the current collection.</summary>
public const string GET_PHOTO_LIST = "GET_PHOTO_LIST";
/// <summary>Tool β host: get the current theme information.</summary>
public const string GET_THEME_INFO = "GET_THEME_INFO";
}