core/com.nokia.carbide.templatewizard/src/com/nokia/carbide/internal/api/templatewizard/ui/TemplateWizardPage.java
changeset 606 f8c3b14b4f6b
parent 0 fb279309251b
child 1779 73303c546665
equal deleted inserted replaced
605:b428e782ad22 606:f8c3b14b4f6b
   115 		/** Set the current value */
   115 		/** Set the current value */
   116 		public void setValue(String value) {
   116 		public void setValue(String value) {
   117 			values.put(type.getId(), value);
   117 			values.put(type.getId(), value);
   118 			
   118 			
   119 			if (type instanceof UidFieldType) {
   119 			if (type instanceof UidFieldType) {
       
   120 				values.put(type.getId(), value.toLowerCase());
   120 				// least hacky way to support this without creating a language out of templates
   121 				// least hacky way to support this without creating a language out of templates
   121 				values.put(type.getId() + UIDComposite.WITHOUT_0X_PREFIX, 
   122 				values.put(type.getId() + UIDComposite.WITHOUT_0X_PREFIX, 
   122 						UIDComposite.getWithout0x(value));
   123 						UIDComposite.getWithout0x(value).toLowerCase());
   123 			}
   124 			}
   124 
   125 
   125 		}
   126 		}
   126 		
   127 		
   127 		/**
   128 		/**
   282 			this.composite = composite;
   283 			this.composite = composite;
   283 		}
   284 		}
   284 		
   285 		
   285 		@Override
   286 		@Override
   286 		public String getValue() {
   287 		public String getValue() {
   287 			return UIDComposite.makeCanonicalHexString(super.getValue().trim());
   288 			String value = super.getValue().trim();
       
   289 			if (!UIDComposite.isValidHexString(value))
       
   290 				return value;
       
   291 			return UIDComposite.makeCanonicalHexString(value);
   288 		}
   292 		}
   289 		
   293 		
   290 		@Override
   294 		@Override
   291 		public String validate() {
   295 		public String validate() {
   292 			String error = super.validate();
   296 			String error = super.validate();