      1 Deluge.Preferences.addPage({
      2 	border: false,
      3 	title: _('Bandwidth'),
      4 	xtype: 'form',
      5 	layout: 'form',
      6 	labelWidth: 10,
      7 	items: [{
      8 		xtype: 'fieldset',
      9 		border: false,
     10 		title: _('Global Bandwidth Usage'),
     11 		autoHeight: true,
     12 		labelWidth: 200,
     13 		style: 'margin-bottom: 0px; padding-bottom: 0px;',
     14 		defaultType: 'uxspinner',
     15 		items: [{
     16 			name: 'max_connections',
     17 			fieldLabel: _('Maximum Connections'),
     18 			width: 60,
     19 			value: -1
     20 		}, {
     21 			name: 'max_upload_slots',
     22 			fieldLabel: _('Maximum Upload Slots'),
     23 			width: 60,
     24 			value: -1
     25 		}, {
     26 			name: 'max_download_speed',
     27 			fieldLabel: _('Maximum Download Speed (KiB/s)'),
     28 			width: 60,
     29 			value: -1
     30 		}, {
     31 			name: 'max_upload_speed',
     32 			fieldLabel: _('Maximum Upload Speed (KiB/s)'),
     33 			width: 60,
     34 			value: -1
     35 		}, {
     36 			name: 'max_half_open_connections',
     37 			fieldLabel: _('Maximum Half-Open Connections'),
     38 			width: 60,
     39 			value: -1
     40 		}, {
     41 			name: 'max_connections_per_second',
     42 			fieldLabel: _('Maximum Connection Attempts per Second'),
     43 			width: 60,
     44 			value: -1
     45 		}]
     46 	}, {
     47 		xtype: 'fieldset',
     48 		border: false,
     49 		title: '',
     50 		autoHeight: true,
     51 		style: 'padding-top: 0px; margin-top: 0px; margin-bottom: 0px;',
     52 		items: [{
     53 			xtype: 'checkbox',
     54 			name: 'ignore_local',
     55 			fieldLabel: '',
     56 			labelSeparator: '',
     57 			boxLabel: _('Ignore limits on local network'),
     58 			value: -1
     59 		}, {
     60 			xtype: 'checkbox',
     61 			name: 'limit_ip_overhead',
     62 			fieldLabel: '',
     63 			labelSeparator: '',
     64 			boxLabel: _('Rate limit IP overhead'),
     65 			value: -1
     66 		}]
     67 	}, {
     68 		xtype: 'fieldset',
     69 		border: false,
     70 		title: _('Per Torrent Bandwidth Usage'),
     71 		autoHeight: true,
     72 		labelWidth: 200,
     73 		defaultType: 'uxspinner',
     74 		items: [{
     75 			name: 'max_connections_per_torrent',
     76 			fieldLabel: _('Maximum Connections'),
     77 			width: 60,
     78 			value: -1
     79 		}, {
     80 			name: 'max_upload_slots_per_torrent',
     81 			fieldLabel: _('Maximum Upload Slots'),
     82 			width: 60,
     83 			value: -1
     84 		}, {
     85 			name: 'max_download_speed_per_torrent',
     86 			fieldLabel: _('Maximum Download Speed (KiB/s)'),
     87 			width: 60,
     88 			value: -1
     89 		}, {
     90 			name: 'max_upload_speed_per_torrent',
     91 			fieldLabel: _('Maximum Upload Speed (KiB/s)'),
     92 			width: 60,
     93 			value: -1
     94 		}]
     95 	}]
     96 });