<?xml version="1.0"?>
<?xml-stylesheet href="chrome://global/skin/" type="text/css"?>

<!DOCTYPE dialog SYSTEM "chrome://gproxy/locale/locale.dtd">

<dialog buttons="accept" 
		id="gproxyCookieDialog"
		ondialogaccept="gproxy_managerClose(); gproxy_openerFocus(); return true;"
		ondialogcancel="gproxy_openerFocus(); return true;"
		onload="gproxy_initProxy();"
		title="&common.manage.label;" persist="height, width"
		xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
	
	<script type="application/x-javascript" src="chrome://gproxy/content/globals.js"></script>
	<script type="application/x-javascript" src="chrome://gproxy/content/datasource.js"></script>
	<script type="application/x-javascript" src="chrome://gproxy/content/proxy.js"></script>
	<script>
	<![CDATA[
		function gproxy_managerClose(){
			try{
				var oPrefs	= Components.classes["@mozilla.org/preferences-service;1"].getService(Components.interfaces.nsIPrefBranch);
					oPrefs.setIntPref("gproxy.proxy.rdf.lastupdate", (new Date()).getTime());
			} catch(e){ alert(e); }
		}
	]]>
	</script>
			
	<hbox align="top" flex="1" style="overflow: auto;">
		<listbox id="manage-proxy-list" flex="2" rows="10"></listbox>
		<vbox>
			<button id="new-button" label=" &common.add.label;" onclick="gproxy_editProxyDialog(true)" image="chrome://gproxy/content/icons/new.png" />
			<button id="edit-button" label=" &common.edit.label;" onclick="gproxy_editProxyDialog(false)" image="chrome://gproxy/content/icons/pencil.png" />
			<button id="remove-button" label=" &common.remove.label;" onclick="gproxy_removeProxy(false)" image="chrome://gproxy/content/icons/cross.png" />
		</vbox>
	</hbox>
</dialog>