W3C home > Mailing lists > Public > www-validator-cvs@w3.org > September 2009

2006/unicorn/src/org/w3c/unicorn UnicornCall.java,1.23,1.24

From: Thomas Gambet via cvs-syncmail <cvsmail@w3.org>
Date: Wed, 23 Sep 2009 09:27:36 +0000
To: www-validator-cvs@w3.org
Message-Id: <E1MqO8O-0004CQ-21@lionel-hutz.w3.org>
Update of /sources/public/2006/unicorn/src/org/w3c/unicorn
In directory hutz:/tmp/cvs-serv16128/src/org/w3c/unicorn

Modified Files:
	UnicornCall.java 
Log Message:
added temporary message in case the inputMethod has changed

Index: UnicornCall.java
===================================================================
RCS file: /sources/public/2006/unicorn/src/org/w3c/unicorn/UnicornCall.java,v
retrieving revision 1.23
retrieving revision 1.24
diff -u -d -r1.23 -r1.24
--- UnicornCall.java	21 Sep 2009 16:28:33 -0000	1.23
+++ UnicornCall.java	23 Sep 2009 09:27:33 -0000	1.24
@@ -150,15 +150,19 @@
 			String sObserverID = aObserver.getID();
 			// add only observer who handle the current mimetype
 			if (!aObserver.canHandleMimeType(aMimeType)) {
-				
-				//TODO Add messaged here
-				logger.debug("Observer " + sObserverID + " does not handle mime type "
-						+ aMimeType.toString());
+				logger.debug("Observer " + sObserverID + " does not handle mime type " + aMimeType.toString());
 				continue;
 			}
 			// the best available observation method
 			final InputMethod aInputMethod = aObserver
 					.getBestInputMethod(aEnumInputMethod);
+			
+			//TODO: add warning if inputMethod has changed
+			if (aInputMethod.getMethod() != inputParameter.getInputMethod()) {
+				
+				messages.add(new Message(Message.Level.WARNING, "Input method changed for observer: \"" + aObserver.getName(sLang) 
+						+ "\" from " + inputParameter.getInputMethod() + " to " + aInputMethod.getMethod(), null));
+			}
 
 			// create a new request with input parameter
 			final Request aRequest = Request.createRequest(
Received on Wednesday, 23 September 2009 09:27:45 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Thursday, 26 April 2012 12:55:14 GMT