textinput/peninputarc/src/peninputserverapp/peninputserver.cpp
changeset 13 3b79bedfdc20
parent 0 eb1f2e154e89
--- a/textinput/peninputarc/src/peninputserverapp/peninputserver.cpp	Tue Feb 02 01:02:04 2010 +0200
+++ b/textinput/peninputarc/src/peninputserverapp/peninputserver.cpp	Fri Apr 16 15:17:40 2010 +0300
@@ -1100,18 +1100,6 @@
             aMessage.WriteL(0,msg);
     	    }
     	    break;            
-            
-    	case EPeninputRequestSetInputLanguage:
-    		{
-			TPckg<TInt> msg(iInputLanguage);
-			aMessage.ReadL(0,msg); 
-			if(iUiLayout)
-				{
-				iUiLayout->HandleCommand(ECmdPenInputLanguage,
-						                 (unsigned char*)&iInputLanguage);  
-				}
-    	    }
-    	    break;            
         default: //Let user pluging handling the user command
             break;
         }
@@ -2112,7 +2100,16 @@
     {
     // No spcified logic now, so just store the disabled layout in the CFepUiLayoutBase class.
     TInt allowedPlugin = EPluginInputModeNone;// EPluginInputModeHwr | EPluginInputModeVkb | EPluginInputModeItut | EPluginInputModeFSc;
-    TInt curLanguage = iInputLanguage;
+    
+    CRepository* repository = NULL;
+    TRAPD(ret, repository = CRepository::NewL(KCRUidAknFep));
+    if (ret != KErrNone)
+        {
+        return EPluginInputModeAll;
+        }
+    TInt curLanguage ;
+    repository->Get(KAknFepInputTxtLang, curLanguage);
+    delete repository;
     
     if (curLanguage == 401) curLanguage = 102;
     if (curLanguage == 402) curLanguage = 103;
@@ -2686,7 +2683,16 @@
 
 TInt CPeninputServer::GetSupportModeL()
     {
-    TInt curLanguage = iInputLanguage;
+    CRepository* repository = NULL;
+    TRAPD(ret, repository = CRepository::NewL(KCRUidAknFep));
+    if (ret != KErrNone)
+        {
+        return ret;
+        }
+    TInt curLanguage ;
+    repository->Get(KAknFepInputTxtLang, curLanguage);
+    delete repository;
+    repository = NULL;
     
     if (curLanguage == 401) curLanguage = 102;
     if (curLanguage == 402) curLanguage = 103;