telepathy-client: Minor coding style fix

Use camelCase for JS properties.
This commit is contained in:
Florian Müllner 2011-06-23 23:57:48 +02:00
parent e5fadb3b42
commit 42adc38609

View File

@ -77,18 +77,18 @@ Client.prototype = {
// The second argument, recover, means _observeChannels will be run // The second argument, recover, means _observeChannels will be run
// for any existing channel as well. // for any existing channel as well.
let dbus = Tp.DBusDaemon.dup(); let dbus = Tp.DBusDaemon.dup();
this._tp_client = new Shell.TpClient({ 'dbus_daemon': dbus, this._tpClient = new Shell.TpClient({ 'dbus_daemon': dbus,
'name': 'GnomeShell', 'name': 'GnomeShell',
'uniquify-name': true }) 'uniquify-name': true })
this._tp_client.set_observe_channels_func( this._tpClient.set_observe_channels_func(
Lang.bind(this, this._observeChannels)); Lang.bind(this, this._observeChannels));
this._tp_client.set_approve_channels_func( this._tpClient.set_approve_channels_func(
Lang.bind(this, this._approveChannels)); Lang.bind(this, this._approveChannels));
this._tp_client.set_handle_channels_func( this._tpClient.set_handle_channels_func(
Lang.bind(this, this._handleChannels)); Lang.bind(this, this._handleChannels));
try { try {
this._tp_client.register(); this._tpClient.register();
} catch (e) { } catch (e) {
throw new Error('Couldn\'t register Telepathy client. Error: \n' + e); throw new Error('Couldn\'t register Telepathy client. Error: \n' + e);
} }
@ -141,12 +141,12 @@ Client.prototype = {
if (this._sources[channel.get_object_path()]) if (this._sources[channel.get_object_path()])
return; return;
let source = new Source(account, conn, channel, contact, this._tp_client); let source = new Source(account, conn, channel, contact, this._tpClient);
this._sources[channel.get_object_path()] = source; this._sources[channel.get_object_path()] = source;
source.connect('destroy', Lang.bind(this, source.connect('destroy', Lang.bind(this,
function() { function() {
if (this._tp_client.is_handling_channel(channel)) { if (this._tpClient.is_handling_channel(channel)) {
// The chat box has been destroyed so it can't // The chat box has been destroyed so it can't
// handle the channel any more. // handle the channel any more.
channel.close_async(null); channel.close_async(null);
@ -167,7 +167,7 @@ Client.prototype = {
continue; continue;
} }
if (this._tp_client.is_handling_channel(channel)) { if (this._tpClient.is_handling_channel(channel)) {
// We are already handling the channel, display the source // We are already handling the channel, display the source
let source = this._sources[channel.get_object_path()]; let source = this._sources[channel.get_object_path()];
if (source) if (source)
@ -179,7 +179,7 @@ Client.prototype = {
_approveChannels: function(approver, account, conn, channels, _approveChannels: function(approver, account, conn, channels,
dispatchOp, context) { dispatchOp, context) {
// Approve the channels right away as we are going to handle it // Approve the channels right away as we are going to handle it
dispatchOp.claim_with_async(this._tp_client, dispatchOp.claim_with_async(this._tpClient,
Lang.bind (this, function(dispatchOp, result) { Lang.bind (this, function(dispatchOp, result) {
try { try {
dispatchOp.claim_with_finish(result); dispatchOp.claim_with_finish(result);