summaryrefslogtreecommitdiffstats
path: root/comm/chat/protocols/yahoo
diff options
context:
space:
mode:
Diffstat (limited to 'comm/chat/protocols/yahoo')
-rw-r--r--comm/chat/protocols/yahoo/components.conf15
-rw-r--r--comm/chat/protocols/yahoo/icons/prpl-yahoo-32.pngbin0 -> 1438 bytes
-rw-r--r--comm/chat/protocols/yahoo/icons/prpl-yahoo-48.pngbin0 -> 2439 bytes
-rw-r--r--comm/chat/protocols/yahoo/icons/prpl-yahoo.pngbin0 -> 531 bytes
-rw-r--r--comm/chat/protocols/yahoo/jar.mn9
-rw-r--r--comm/chat/protocols/yahoo/moz.build14
-rw-r--r--comm/chat/protocols/yahoo/yahoo.sys.mjs60
7 files changed, 98 insertions, 0 deletions
diff --git a/comm/chat/protocols/yahoo/components.conf b/comm/chat/protocols/yahoo/components.conf
new file mode 100644
index 0000000000..5ca1d8ad10
--- /dev/null
+++ b/comm/chat/protocols/yahoo/components.conf
@@ -0,0 +1,15 @@
+# -*- Mode: python; indent-tabs-mode: nil; tab-width: 40 -*-
+# vim: set filetype=python:
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0. If a copy of the MPL was not distributed with this
+# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+
+Classes = [
+ {
+ 'cid': '{50ea817e-5d79-4657-91ae-aa0a52bdb98c}',
+ 'contract_ids': ['@mozilla.org/chat/yahoo;1'],
+ 'esModule': 'resource:///modules/yahoo.sys.mjs',
+ 'constructor': 'YahooProtocol',
+ 'categories': {'im-protocol-plugin': 'prpl-yahoo'},
+ },
+]
diff --git a/comm/chat/protocols/yahoo/icons/prpl-yahoo-32.png b/comm/chat/protocols/yahoo/icons/prpl-yahoo-32.png
new file mode 100644
index 0000000000..aefe383c32
--- /dev/null
+++ b/comm/chat/protocols/yahoo/icons/prpl-yahoo-32.png
Binary files differ
diff --git a/comm/chat/protocols/yahoo/icons/prpl-yahoo-48.png b/comm/chat/protocols/yahoo/icons/prpl-yahoo-48.png
new file mode 100644
index 0000000000..f454f26d3c
--- /dev/null
+++ b/comm/chat/protocols/yahoo/icons/prpl-yahoo-48.png
Binary files differ
diff --git a/comm/chat/protocols/yahoo/icons/prpl-yahoo.png b/comm/chat/protocols/yahoo/icons/prpl-yahoo.png
new file mode 100644
index 0000000000..4cff5da7fc
--- /dev/null
+++ b/comm/chat/protocols/yahoo/icons/prpl-yahoo.png
Binary files differ
diff --git a/comm/chat/protocols/yahoo/jar.mn b/comm/chat/protocols/yahoo/jar.mn
new file mode 100644
index 0000000000..31d6e9cf0b
--- /dev/null
+++ b/comm/chat/protocols/yahoo/jar.mn
@@ -0,0 +1,9 @@
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0. If a copy of the MPL was not distributed with this
+# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+
+chat.jar:
+% skin prpl-yahoo classic/1.0 %skin/classic/prpl/yahoo/
+ skin/classic/prpl/yahoo/icon32.png (icons/prpl-yahoo-32.png)
+ skin/classic/prpl/yahoo/icon48.png (icons/prpl-yahoo-48.png)
+ skin/classic/prpl/yahoo/icon.png (icons/prpl-yahoo.png)
diff --git a/comm/chat/protocols/yahoo/moz.build b/comm/chat/protocols/yahoo/moz.build
new file mode 100644
index 0000000000..b2e5ab78d6
--- /dev/null
+++ b/comm/chat/protocols/yahoo/moz.build
@@ -0,0 +1,14 @@
+# vim: set filetype=python:
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0. If a copy of the MPL was not distributed with this
+# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+
+JAR_MANIFESTS += ["jar.mn"]
+
+EXTRA_JS_MODULES += [
+ "yahoo.sys.mjs",
+]
+
+XPCOM_MANIFESTS += [
+ "components.conf",
+]
diff --git a/comm/chat/protocols/yahoo/yahoo.sys.mjs b/comm/chat/protocols/yahoo/yahoo.sys.mjs
new file mode 100644
index 0000000000..c44d27e8e5
--- /dev/null
+++ b/comm/chat/protocols/yahoo/yahoo.sys.mjs
@@ -0,0 +1,60 @@
+/* This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
+
+import { XPCOMUtils } from "resource://gre/modules/XPCOMUtils.sys.mjs";
+import { l10nHelper } from "resource:///modules/imXPCOMUtils.sys.mjs";
+import {
+ GenericAccountPrototype,
+ GenericProtocolPrototype,
+} from "resource:///modules/jsProtoHelper.sys.mjs";
+
+const lazy = {};
+
+XPCOMUtils.defineLazyGetter(lazy, "_", () =>
+ l10nHelper("chrome://chat/locale/yahoo.properties")
+);
+
+function YahooAccount(aProtoInstance, aImAccount) {
+ this._init(aProtoInstance, aImAccount);
+}
+YahooAccount.prototype = {
+ __proto__: GenericAccountPrototype,
+
+ connect() {
+ this.WARN(
+ "The legacy versions of Yahoo Messenger was disabled on August " +
+ "5, 2016. It is currently not possible to connect to Yahoo " +
+ "Messenger. See bug 1316000."
+ );
+ this.reportDisconnecting(
+ Ci.prplIAccount.ERROR_OTHER_ERROR,
+ lazy._("yahoo.disabled")
+ );
+ this.reportDisconnected();
+ },
+
+ // Nothing to do.
+ unInit() {},
+ remove() {},
+};
+
+export function YahooProtocol() {}
+YahooProtocol.prototype = {
+ __proto__: GenericProtocolPrototype,
+ get id() {
+ return "prpl-yahoo";
+ },
+ get normalizedName() {
+ return "yahoo";
+ },
+ get name() {
+ return "Yahoo";
+ },
+ get iconBaseURI() {
+ return "chrome://prpl-yahoo/skin/";
+ },
+ getAccount(aImAccount) {
+ return new YahooAccount(this, aImAccount);
+ },
+};