Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- script.
- var ext_id = "haefbbimkpppfdgddidickljcpbhpmmp";
- var sites = {
- 'jas': {
- name: 'LiveJasmin',
- open: {
- link: 'http://modelcenter.jasmin.com/en/login',
- user: '#{acct.conturi.lj.user}',
- pass: '#{acct.conturi.lj.pass}'
- },
- exec: {
- name: 'AutoLJ.exe',
- args: '#{acct.conturi.lj.user} #{acct.conturi.lj.pass}'
- }
- },
- 'mat': {
- name: 'Streamate',
- open: {
- link: 'https://www.streamatemodels.com/login.php',
- user: '#{acct.conturi.mate.user}',
- pass: '#{acct.conturi.mate.pass}'
- },
- },
- 'mfc': {
- name: 'MFC',
- open: {
- link: 'https://www.myfreecams.com/modelweb/',
- user: '#{acct.conturi.mfc.user}',
- pass: '#{acct.conturi.mfc.pass}'
- },
- },
- 'nkd': {
- name: 'Naked',
- open: {
- link: 'http://models.naked.com/login',
- user: '#{acct.conturi.naked.user}',
- pass: '#{acct.conturi.naked.pass}'
- },
- exec: {
- name: 'AutoNK.exe',
- args: '#{acct.conturi.naked.user} #{acct.conturi.naked.pass}'
- }
- },
- 'skype': {
- name: 'Skype',
- exec: {
- name: 'AutoSky.exe',
- args: ''
- }
- }
- }
- chrome.runtime.sendMessage(ext_id, { command: 'sites', sites: sites }); //seteaza date situri in extensie
- $(document).ready(function()
- {
- for (var id in sites) { //adauga butoane
- var btn = $('<a id="' + id + '" href="#">' + sites[id].name + '</a>');
- btn.click(function(event)
- {
- $(event.target).hide(); //ascunde butonul, ar trebui disable
- chrome.runtime.sendMessage(ext_id, { command: 'start', id: event.target.id });
- setTimeout(function() { $(event.target).show(); }, 5000); //activeaza butonul din nou dupa X secunde
- });
- $("#sites").append(btn);
- }
- });
- div#sites
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement