/usr/share/hotot/js/ui.add_to_list_dlg.js is in hotot-common 1:0.9.8.14-2.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
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 | if (typeof ui == 'undefined') var ui = {};
ui.AddToListDlg = {
id: '',
tpl: '<li class="mochi_list_item with_trigger"> \
<a href="#" list_id="{%ID%}" class="trigger page_nav"> \
<span class="widget more"></span> \
<label for="" class="label">{%NAME%}</label> \
</a> \
</li>',
load:
function load(name) {
$('#add_to_list_dlg').find('.trigger').unbind();
var container = $('#add_to_list_dlg ul').empty();
var arr = [];
for (var i = 0; i < globals.my_lists.length; i += 1) {
var html = ui.AddToListDlg.tpl.replace(/{%ID%}/, globals.my_lists[i].id_str);
html = html.replace(/{%NAME%}/g, globals.my_lists[i].name);
arr.push(html);
}
container.append(arr.join('\n'));
container.find('.trigger').click(function () {
var id = $(this).attr('list_id');
globals.twitterClient.create_list_member(
id, name,
function () {
toast.set('Add @' + name + ' to List.').show();
},
function () {
toast.set('Failed to add @' + name + ' to List.').show();
});
globals.add_to_list_dialog.close();
});
}
}
|