annotate libpurple/plugins/mono/api/PurplePlugin.cs @ 29130:f8da53e381dd

Improved handling of the 0x00d charset in AIM, which is sent by mobile devices speaking ISO-8859-1. Try UTF-8 first (the encoding sent by iChat in a Direct IM with non-ASCII characters), then fall back to ISO-8859-1. Fixes #a13544, a bug created with the fix for iChat DIM encoding new in libpurple 2.6.4" applied changes from 6f3a1b3c52803e11d4cda1e0537c1270599e8d8e through ed0a2a35c7e22519df27c50069c22b03e01c027a
author Evan Schoenberg <evan.s@dreskin.net>
date Fri, 04 Dec 2009 02:24:41 +0000
parents 80ee585fb53c
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
15877
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
1 namespace Purple {
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
2 public class PluginInfo {
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
3 private string id;
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
4 private string name;
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
5 private string version;
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
6 private string summary;
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
7 private string description;
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
8 private string author;
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
9 private string homepage;
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
10
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
11 public PluginInfo(string id, string name, string version, string summary,
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
12 string description, string author, string homepage)
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
13 {
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
14 this.id = id;
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
15 this.name = name;
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
16 this.version = version;
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
17 this.summary = summary;
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
18 this.description = description;
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
19 this.author = author;
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
20 this.homepage = homepage;
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
21 }
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
22
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
23 public string Id {
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
24 get { return id; }
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
25 }
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
26
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
27 public string Name {
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
28 get { return name; }
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
29 }
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
30
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
31 public string Version {
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
32 get { return version; }
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
33 }
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
34
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
35 public string Summary {
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
36 get { return summary; }
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
37 }
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
38
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
39 public string Description {
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
40 get { return description; }
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
41 }
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
42
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
43 public string Author {
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
44 get { return author; }
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
45 }
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
46
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
47 public string Homepage {
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
48 get { return homepage; }
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
49 }
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
50 }
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
51
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
52 abstract public class Plugin {
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
53 private PluginInfo info;
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
54
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
55 public Plugin(PluginInfo info) {
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
56 this.info = info;
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
57 }
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
58
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
59 public abstract void Load();
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
60 public abstract void Unload();
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
61 public abstract void Destroy();
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
62
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
63 public PluginInfo Info {
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
64 get { return info; }
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
65 }
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
66 }
80ee585fb53c SF Patch #1686400 from Eoin Coffey ("ecoffey")
Richard Laager <rlaager@wiktel.com>
parents:
diff changeset
67 }