forked from ModdersLink/RimeExamplePlugin
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathRimeExamplePlugin.cs
More file actions
35 lines (29 loc) · 1.34 KB
/
RimeExamplePlugin.cs
File metadata and controls
35 lines (29 loc) · 1.34 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
using System.Windows.Controls;
using RimeCommon.Content.Messages;
using RimeCommon.Logging;
using RimeCommon.Messaging;
using RimeCommon.Plugins;
namespace RimePluginExample
{
public class RimeExamplePlugin : RimePlugin
{
public override string Name { get { return "Rime Example Plugin"; } }
public override string Author { get { return "Example Author"; } }
public override string Version { get { return "1.0"; } }
public override string Description { get { return "An description for the example plugin, hmmm.... what should it be?"; } }
public override string Extension { get { return "_rime-plugin-example"; } }
public override UserControl MainControl { get { return null; } }
public override MountPoint Mount { get { return MountPoint.None; } }
public override void Init(params object[] p_Params)
{
RegisterListener(MessagingSubSystem.Content);
RegisterMessageCallback(typeof(ContentRequestOpen), OnContentRequestOpen);
WriteLog(LogsLevel.All, "RimeExamplePlugin Init called.");
}
private void OnContentRequestOpen(RimeMessage p_Message)
{
var s_Message = (ContentRequestOpen) p_Message;
WriteLog(LogsLevel.All, "Swag, Swag, Swag, Swag");
}
}
}