<?xml version="1.0" ?>

<?xml-stylesheet href="chrome://global/skin/" type="text/css" ?>
<?xml-stylesheet href="chrome://scrapbook/skin/property.css" type="text/css" ?>

<!DOCTYPE dialog [
	<!ENTITY % propDTD SYSTEM "chrome://scrapbook/locale/property.dtd" >
	%propDTD;
	<!ENTITY % treeDTD SYSTEM "chrome://scrapbook/locale/tree.dtd" >
	%treeDTD;
]>

<dialog id="sbPropDialog"
        xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
        buttons="accept,cancel"
        onload="sbPropService.init();"
        ondialogaccept="sbPropService.accept();"
        ondialogcancel="sbPropService.cancel();">

	<script type="application/x-javascript" src="chrome://scrapbook/content/common.js" />
	<script type="application/x-javascript" src="chrome://scrapbook/content/property.js" />

	<stringbundle id="sbPropString" src="chrome://scrapbook/locale/property.properties" />

	<tabbox>
		<tabs orient="horizontal">
			<tab label="&sb.prop.general;" />
			<tab label="&sb.prop.comment;" id="sbPropCommentTab" />
		</tabs>
		<tabpanels>
			<tabpanel>
				<grid flex="1">
					<columns>
						<column />
						<column flex="1" />
					</columns>
					<rows id="sbPropRows">
						<row align="center">
							<label control="sbPropTitle" value="&sb.prop.title;:" />
							<hbox>
								<menulist id="sbPropTitle" editable="true" flex="1">
									<menupopup onpopupshowing="sbPropService.fillTitle(this);" />
								</menulist>
							</hbox>
						</row>
						<row id="sbPropSourceRow" align="center">
							<label control="sbPropSource" value="&sb.prop.url;:" />
							<textbox id="sbPropSource" />
						</row>
						<row id="sbPropIconRow" align="center">
							<label value="&sb.prop.icon;:" />
							<hbox align="center">
								<image id="sbPropIcon" style="width:16px;height:16px;margin:0px 8px;" />
								<toolbarbutton id="sbPropIconMenu" label="&sb.prop.icon.change;" type="menu">
									<menupopup>
										<menuitem label="&sb.prop.icon.default;"    oncommand="sbPropService.setDefaultIcon();" />
										<menuitem label="&sb.prop.icon.favicon;..." oncommand="sbPropService.pickupIcon('F',this.label);" />
										<menuitem label="&sb.prop.icon.custom;..."  oncommand="sbPropService.pickupIcon('U',this.label);" />
										<menuitem label="&sb.prop.url;..." oncommand="sbPropService.setIconURL();" />
									</menupopup>
								</toolbarbutton>
								<spacer flex="1" />
								<checkbox id="sbPropMark" label="&sb.prop.mark;" />
							</hbox>
						</row>
						<separator class="groove" style="margin:8px 0px;" />
						<row align="center">
							<label value="ID:" />
							<textbox id="sbPropID" readonly="true" />
						</row>
						<row align="center">
							<label value="&sb.prop.date;:" />
							<textbox id="sbPropDate" readonly="true" />
						</row>
						<row align="center">
							<label value="&sb.prop.type;:" />
							<textbox id="sbPropType" readonly="true" />
						</row>
						<row id="sbPropCharsRow" align="center">
							<label value="&sb.prop.encode;:" />
							<textbox id="sbPropChars" readonly="true" />
						</row>
						<row id="sbPropSizeRow" align="center">
							<label value="&sb.prop.size;:" />
							<textbox id="sbPropSize" readonly="true" />
						</row>
					</rows>
				</grid>
			</tabpanel>
			<tabpanel>
				<textbox id="sbPropComment" multiline="true" flex="1" oninput="sbPropService.updateCommentTab(this.value);" />
			</tabpanel>
		</tabpanels>
	</tabbox>

</dialog>
