Index: /ComponentRegistry/trunk/ComponentBrowserGui/src/main/flex/clarin/cmdi/componentregistry/common/components/LabelButton.as
===================================================================
--- /ComponentRegistry/trunk/ComponentBrowserGui/src/main/flex/clarin/cmdi/componentregistry/common/components/LabelButton.as	(revision 2139)
+++ /ComponentRegistry/trunk/ComponentBrowserGui/src/main/flex/clarin/cmdi/componentregistry/common/components/LabelButton.as	(revision 2139)
@@ -0,0 +1,22 @@
+package clarin.cmdi.componentregistry.common.components {
+	import flash.events.MouseEvent;
+	
+	import mx.controls.Label;
+
+	public class LabelButton extends Label {
+		public function LabelButton(clickHandler:Function, text:String=null) {
+			super();
+			if(text != null){
+				this.text = text;
+			}
+			addEventListener(MouseEvent.MOUSE_OVER, function(event:MouseEvent):void {
+				event.currentTarget.setStyle("textDecoration", "underline");
+			});
+			addEventListener(MouseEvent.MOUSE_OUT, function(event:MouseEvent):void {
+				event.currentTarget.setStyle("textDecoration", "none");
+			});
+			addEventListener(MouseEvent.CLICK, clickHandler);
+		}
+
+	}
+}
Index: /ComponentRegistry/trunk/ComponentBrowserGui/src/main/flex/clarin/cmdi/componentregistry/common/components/SpaceSwitch.mxml
===================================================================
--- /ComponentRegistry/trunk/ComponentBrowserGui/src/main/flex/clarin/cmdi/componentregistry/common/components/SpaceSwitch.mxml	(revision 2139)
+++ /ComponentRegistry/trunk/ComponentBrowserGui/src/main/flex/clarin/cmdi/componentregistry/common/components/SpaceSwitch.mxml	(revision 2139)
@@ -0,0 +1,32 @@
+<?xml version="1.0" encoding="utf-8"?>
+<mx:ComboBox xmlns:mx="http://www.adobe.com/2006/mxml"
+				 dataProvider="{spaces}"
+				 selectedIndex="{Config.instance.userSpace ? 1 : 0}"
+				 width="110"
+				 close="userSpaceCloseHandler(event);"
+				 >
+	
+	<mx:Script>
+		<![CDATA[
+			import clarin.cmdi.componentregistry.common.Credentials;
+			import clarin.cmdi.componentregistry.common.Login;
+			import clarin.cmdi.componentregistry.services.Config;
+			
+			import mx.collections.ArrayCollection;
+			
+			private static const USERSPACE_LABEL:String = "Work space";
+			private static const PUBLICSPACE_LABEL:String = "Public space";
+			[Bindable]
+			public static var spaces:ArrayCollection = new ArrayCollection([{label: PUBLICSPACE_LABEL, data: 1}, {label: USERSPACE_LABEL, data: 2}]);
+			
+			private function userSpaceCloseHandler(event:Event):void {
+				if (Credentials.instance.isLoggedIn()) {
+					Config.instance.userSpace = ComboBox(event.target).selectedItem.data == 2;
+				} else if (selectedIndex != 0) {
+					selectedIndex = 0;
+					new Login().show(this.parent.parent, Config.VIEW_BROWSE, Config.SPACE_USER, null);
+				}
+			}
+		]]>
+	</mx:Script>
+</mx:ComboBox>
Index: /ComponentRegistry/trunk/ComponentBrowserGui/src/main/flex/clarin/cmdi/componentregistry/editor/ComponentSummary.mxml
===================================================================
--- /ComponentRegistry/trunk/ComponentBrowserGui/src/main/flex/clarin/cmdi/componentregistry/editor/ComponentSummary.mxml	(revision 2139)
+++ /ComponentRegistry/trunk/ComponentBrowserGui/src/main/flex/clarin/cmdi/componentregistry/editor/ComponentSummary.mxml	(revision 2139)
@@ -0,0 +1,44 @@
+<?xml version="1.0" encoding="utf-8"?>
+<mx:VBox xmlns:mx="http://www.adobe.com/2006/mxml"
+		 includeInLayout="{visible}"
+		 paddingLeft="50"
+		 >
+	<mx:Script>
+		<![CDATA[
+			import clarin.cmdi.componentregistry.editor.model.CMDComponent;
+			import clarin.cmdi.componentregistry.services.ComponentListService;
+			
+			[Bindable]
+			public var component:CMDComponent;
+		]]>
+	</mx:Script>
+	
+	<mx:HBox>	
+		<mx:HBox minWidth="160"
+				 visible="{component.componentId == null || component.componentId == ''}"
+				 includeInLayout="{component.componentId == null || component.componentId == ''}"
+				 >			
+			<mx:Label text="Name: " fontWeight="bold"/>
+			<mx:Label text="{component.name}" />
+		</mx:HBox>
+		
+		<mx:HBox minWidth="160"
+				 visible="{component.componentId != null &amp;&amp; component.componentId != ''}"
+				 includeInLayout="{component.componentId != null &amp;&amp; component.componentId != ''}"
+				 >			
+			<mx:Label text="ComponentId: " fontWeight="bold"/>
+			<mx:Label text="{ComponentListService.findDescription(component.componentId).name}" />
+		</mx:HBox>
+		
+		<mx:HBox minWidth="160">
+			<mx:Label text="Cardinality: " fontWeight="bold"/>
+			<mx:Label text="{component.cardinalityMin+' - '+component.cardinalityMax}" />
+		</mx:HBox>
+
+		<mx:HBox visible="{ component.attributeList.length > 0}"
+				 includeInLayout="{component.attributeList.length > 0}">
+			<mx:Label text="Attribute count: " fontWeight="bold"/>
+			<mx:Label text="{component.attributeList.length}" />
+		</mx:HBox>
+	</mx:HBox>
+</mx:VBox>
Index: /ComponentRegistry/trunk/ComponentBrowserGui/src/main/flex/clarin/cmdi/componentregistry/editor/ElementSummary.mxml
===================================================================
--- /ComponentRegistry/trunk/ComponentBrowserGui/src/main/flex/clarin/cmdi/componentregistry/editor/ElementSummary.mxml	(revision 2139)
+++ /ComponentRegistry/trunk/ComponentBrowserGui/src/main/flex/clarin/cmdi/componentregistry/editor/ElementSummary.mxml	(revision 2139)
@@ -0,0 +1,59 @@
+<?xml version="1.0" encoding="utf-8"?>
+<mx:VBox xmlns:mx="http://www.adobe.com/2006/mxml"
+		 includeInLayout="{visible}"
+		 paddingLeft="50"
+		 >
+	<mx:Script>
+		<![CDATA[
+			import clarin.cmdi.componentregistry.editor.model.CMDComponentElement;
+			
+			[Bindable]
+			public var element:CMDComponentElement;
+		]]>
+	</mx:Script>
+	
+	<mx:HBox>	
+		<mx:HBox minWidth="160">			
+			<mx:Label text="Name: " fontWeight="bold"/>
+			<mx:Label text="{element.name}" />
+		</mx:HBox>
+		
+		<mx:HBox minWidth="120" visible="{element.valueSchemeSimple != null}" 
+				 includeInLayout="{element.valueSchemeSimple != null}">			
+			<mx:Label text="Type: " fontWeight="bold"/>
+			<mx:Label text="{element.valueSchemeSimple}" />
+		</mx:HBox>
+		
+		<mx:HBox minWidth="120" visible="{element.valueSchemePattern != null}" 
+				 includeInLayout="{element.valueSchemePattern != null}">			
+			<mx:Label text="Pattern: " fontWeight="bold"/>
+			<mx:Label text="{element.valueSchemePattern}" />
+		</mx:HBox>
+		
+		<mx:HBox minWidth="120" visible="{element.valueSchemeEnumeration != null}" 
+				 includeInLayout="{element.valueSchemeEnumeration != null}">			
+			<mx:Label text="Type: " fontWeight="bold"/>
+			<mx:Label text="vocabulary" />
+		</mx:HBox>
+	<!--
+	</mx:HBox>
+		
+	<mx:HBox>	
+		-->
+		<mx:HBox minWidth="160">
+			<mx:Label text="Cardinality: " fontWeight="bold"/>
+			<mx:Label text="{element.cardinalityMin+' - '+element.cardinalityMax}" />
+		</mx:HBox>
+	
+		<mx:HBox minWidth="120">
+			<mx:Label text="Display priority: " fontWeight="bold"/>
+			<mx:Label text="{element.displayPriority}" />
+		</mx:HBox>
+	
+		<mx:HBox visible="{element.attributeList.length > 0}"
+				 includeInLayout="{element.attributeList.length > 0}">
+			<mx:Label text="Attribute count: " fontWeight="bold"/>
+			<mx:Label text="{element.attributeList.length}" />
+		</mx:HBox>
+	</mx:HBox>
+</mx:VBox>
Index: /ComponentRegistry/trunk/ComponentBrowserGui/src/main/flex/clarin/cmdi/componentregistry/editor/ItemEdit.as
===================================================================
--- /ComponentRegistry/trunk/ComponentBrowserGui/src/main/flex/clarin/cmdi/componentregistry/editor/ItemEdit.as	(revision 2139)
+++ /ComponentRegistry/trunk/ComponentBrowserGui/src/main/flex/clarin/cmdi/componentregistry/editor/ItemEdit.as	(revision 2139)
@@ -0,0 +1,76 @@
+package clarin.cmdi.componentregistry.editor
+{
+	import clarin.cmdi.componentregistry.common.StyleConstants;
+	
+	import flash.display.DisplayObject;
+	
+	import mx.containers.Form;
+	import mx.core.Container;
+	
+	public class ItemEdit extends Form
+	{
+		private var showToggleBox:ShowToggleBox;
+		private var hideableForm:Form;
+		
+		public function ItemEdit()
+		{
+			super();
+			hideableForm = createHidableForm();
+			
+			showToggleBox = new ShowToggleBox();
+			showToggleBox.visibleState = true;
+			
+			showToggleBox.visibleContainer = hideableForm;
+		}
+		
+		private function createHidableForm():Form {
+			var form:Form = new Form();
+			form.styleName = StyleConstants.XMLBROWSER;
+			form.setStyle("paddingTop","0");
+			form.setStyle("paddingBottom","0");
+			form.verticalScrollPolicy = "off";
+			form.horizontalScrollPolicy = "off";
+			return form;
+		}
+		
+		protected function getShowToggleBox():ShowToggleBox{
+			return showToggleBox;
+		}
+		
+		protected function setSummaryContainer(container:Container):void{
+			showToggleBox.invisibleContainer = container;
+		}
+		
+		protected function getHideableForm():Form{
+			return hideableForm;
+		}
+		
+		protected function addToHideableForm(child:DisplayObject):void{
+			hideableForm.addChild(child);
+		}
+		
+		public function setDetailsVisibleState(visibleState:Boolean):void{
+			showToggleBox.visibleState = visibleState;
+		}
+		
+		
+		
+		protected function setAllVisibleState(visibleState:Boolean):void{
+			setDetailsVisibleState(visibleState);
+			for(var i:int=0;i<numChildren;i++){
+				var child:Object = getChildAt(i);
+				if(child is ElementEdit || child is ComponentEdit){
+					ItemEdit(child).setAllVisibleState(visibleState);
+				}
+			}
+		}
+		
+		public function collapseAll():void{
+			setAllVisibleState(false);
+		}
+		
+		public function expandAll():void{
+			setAllVisibleState(true);
+		}
+	}
+}
Index: /ComponentRegistry/trunk/ComponentBrowserGui/src/main/flex/clarin/cmdi/componentregistry/editor/ShowToggleBox.mxml
===================================================================
--- /ComponentRegistry/trunk/ComponentBrowserGui/src/main/flex/clarin/cmdi/componentregistry/editor/ShowToggleBox.mxml	(revision 2139)
+++ /ComponentRegistry/trunk/ComponentBrowserGui/src/main/flex/clarin/cmdi/componentregistry/editor/ShowToggleBox.mxml	(revision 2139)
@@ -0,0 +1,89 @@
+<?xml version="1.0" encoding="utf-8"?>
+<mx:Box xmlns:mx="http://www.adobe.com/2006/mxml"
+		borderStyle="solid"
+		initialize="initHandler(event)"
+		click="clickHandler(event)"
+		mouseOver="mouseOverHandler(event)"
+		mouseOut="mouseOutHandler(event)"
+		toolTip="Expand/collapse item details"
+		borderColor="#B7BABC"
+		>
+	<mx:Script>
+		<![CDATA[
+			import mx.binding.utils.BindingUtils;
+			import mx.core.Container;
+			import mx.events.FlexEvent;
+			
+			[Bindable]
+			public var visibleState:Boolean;
+			[Bindable]
+			public var visibleContainer:Container;
+			[Bindable]
+			public var invisibleContainer:Container;	
+			
+			protected function initHandler(event:FlexEvent):void
+			{
+				BindingUtils.bindSetter(updateState, this, "visibleState");
+			}
+			
+			protected function clickHandler(event:MouseEvent):void
+			{
+				visibleState = !visibleState;
+				//removeDrawFocus();
+			}
+			
+			protected function mouseOverHandler(event:MouseEvent):void
+			{
+				event.currentTarget.setStyle("borderColor", "#000000");
+				if(visibleContainer != null){
+					visibleContainer.drawFocus(visibleState);
+				}
+				if(invisibleContainer != null){
+					invisibleContainer.drawFocus(!visibleState);
+				}
+			}
+			
+			private function updateState(val:Boolean):void{
+				if(visibleContainer != null){
+					visibleContainer.visible = visibleState;
+					visibleContainer.includeInLayout = visibleState;
+					if(visibleState){
+						if(invisibleContainer != null){
+							invisibleContainer.drawFocus(false);
+						}
+						visibleContainer.drawFocus(true);
+					}
+				}
+				
+				if(invisibleContainer != null){
+					invisibleContainer.visible = !visibleState;
+					invisibleContainer.includeInLayout = !visibleState;
+					if(!visibleState){
+						if(visibleContainer != null){
+							visibleContainer.drawFocus(false);
+						}
+						invisibleContainer.drawFocus(true);
+					}					
+				}
+			}
+
+			protected function mouseOutHandler(event:MouseEvent):void
+			{
+				event.currentTarget.setStyle("borderColor", "#B7BABC");
+				removeDrawFocus();
+			}
+			
+			private function removeDrawFocus():void{
+				if(visibleContainer != null){
+					visibleContainer.drawFocus(false);
+				}
+				if(invisibleContainer != null){
+					invisibleContainer.drawFocus(false);
+				}
+			}
+
+		]]>
+	</mx:Script>
+	
+	<mx:Label textAlign="center" text="{visibleState?'-':'+'}" />
+</mx:Box>
