View difference between Paste ID: 740vsrFh and SRMJJLzs
SHOW: | | - or go back to the newest paste.
1
$.nette.ext('copyAddressFromHeader', {
2
	init: function () {
3-
		$('body').on('change', 'a#copyAddressFromHeader', function () {
3+
		var self = this;
4
		this.bind($('body'));
5
		this.ext('snippets').after(function () {
6
			self.bind(snippet); // todo: nevim z hlavy
7
		});
8
	}
9
}, {
10
    bind: function ($el) {
11
        $el.find('a#copyAddressFromHeader').each(function () {
12
			el = $(this);
13
			el.zclip({
14
				path: el.data('basepath') + '/js/ZeroClipboard.swf',
15
				copy: function () {
16
					return el.data('url');
17
				},
18
				clickAfter: false
19
			});
20
		});
21
    }
22
});