fep/aknfep/peninputplugins/peninputimeplugingeneric/src/peninputimeplugingeneric.cpp
branchRCL_3
changeset 5 a47de9135b21
parent 0 eb1f2e154e89
child 19 ac7e4d1d9209
equal deleted inserted replaced
3:f5a1e66df979 5:a47de9135b21
    48 
    48 
    49 _LIT(KHwrImeName, "Generic HWR");
    49 _LIT(KHwrImeName, "Generic HWR");
    50 _LIT(KVkbImeName, "Generic VKB");
    50 _LIT(KVkbImeName, "Generic VKB");
    51 _LIT(KFSQImeName, "Generic FSQ");
    51 _LIT(KFSQImeName, "Generic FSQ");
    52 _LIT(KSSQImeName, "Split View Qwerty");
    52 _LIT(KSSQImeName, "Split View Qwerty");
    53 
    53 _LIT(KFingerHwrImeName, "Generic Fingerhwr");
    54 _LIT(KHwrResourceFormatPattern, "peninputhwrwindowconfiginfo_*.rsc");
    54 _LIT(KHwrResourceFormatPattern, "peninputhwrwindowconfiginfo_*.rsc");
    55 _LIT(KVkbResourceFormatPattern, "peninputvkbwindowconfiginfo_*.rsc");
    55 _LIT(KVkbResourceFormatPattern, "peninputvkbwindowconfiginfo_*.rsc");
    56 _LIT(KSsqResourceFormatPattern, "peninputssqwinconfiginfo_*.rsc");
    56 _LIT(KSsqResourceFormatPattern, "peninputssqwinconfiginfo_*.rsc");
    57 
    57 
    58 _LIT(KPluginResourcePath, "z:\\RESOURCE\\Plugins\\");
    58 _LIT(KPluginResourcePath, "z:\\RESOURCE\\Plugins\\");
   205                 {
   205                 {
   206                 layoutId.iUid = KFsqUiId;
   206                 layoutId.iUid = KFsqUiId;
   207                 }
   207                 }
   208             }
   208             }
   209             break;
   209             break;
       
   210         case EPluginInputModeFingerHwr:
       
   211             {
       
   212             layoutId.iUid = KFingerHwrUiId;
       
   213             }
       
   214             break;            
   210         default:
   215         default:
   211             return NULL;
   216             return NULL;
   212         }
   217         }
   213     fepmanager = GetPluginUiL( aMode );
   218     fepmanager = GetPluginUiL( aMode );
   214     
   219     
   264         }
   269         }
   265     else if( aLayoutId == KFsqUiId )
   270     else if( aLayoutId == KFsqUiId )
   266         {
   271         {
   267         mode = EPluginInputModeFSQ;
   272         mode = EPluginInputModeFSQ;
   268         }
   273         }
       
   274     else if( aLayoutId == KFingerHwrUiId )
       
   275         {
       
   276         mode = EPluginInputModeFingerHwr;
       
   277         }
   269     else
   278     else
   270         {
   279         {
   271         return NULL;
   280         return NULL;
   272         }
   281         }
   273 
   282 
   352             }
   361             }
   353             break;
   362             break;
   354         case EPluginInputModeFSQ:
   363         case EPluginInputModeFSQ:
   355             {
   364             {
   356             id = KFsqUiId;
   365             id = KFsqUiId;
       
   366             }
       
   367             break;
       
   368         case EPluginInputModeFingerHwr:
       
   369             {
       
   370             id = KFingerHwrUiId;
   357             }
   371             }
   358             break;
   372             break;
   359         default:
   373         default:
   360             {
   374             {
   361             id = KInvalidImplId;
   375             id = KInvalidImplId;
   450     id.iUid = KHwrLayoutInterfaceId;
   464     id.iUid = KHwrLayoutInterfaceId;
   451     TBool hwr = EFalse;
   465     TBool hwr = EFalse;
   452     TBool vkb = EFalse;
   466     TBool vkb = EFalse;
   453     TBool fsq = EFalse;
   467     TBool fsq = EFalse;
   454     TBool ssq = EFalse;
   468     TBool ssq = EFalse;
   455     
   469     TBool fingerhwr = EFalse;  
   456     CleanupStack::PushL( TCleanupItem( Cleanup, &infoArray ) );
   470     CleanupStack::PushL( TCleanupItem( Cleanup, &infoArray ) );
   457     REComSession::ListImplementationsL(id, infoArray);
   471     REComSession::ListImplementationsL(id, infoArray);
   458         
   472         
   459     for (TInt i = 0; i < infoArray.Count(); ++i)
   473     for (TInt i = 0; i < infoArray.Count(); ++i)
   460         {
   474         {
   478         if (infoArray[i]->ImplementationUid().iUid == KSsqUiId
   492         if (infoArray[i]->ImplementationUid().iUid == KSsqUiId
   479                 && FeatureManager::FeatureSupported(KFeatureIdVirtualFullscrQwertyInput))
   493                 && FeatureManager::FeatureSupported(KFeatureIdVirtualFullscrQwertyInput))
   480             {
   494             {
   481             ssq = ETrue;
   495             ssq = ETrue;
   482             } 
   496             } 
       
   497         if (infoArray[i]->ImplementationUid().iUid == KFingerHwrUiId )
       
   498             {
       
   499             fingerhwr = ETrue;
       
   500             }          
   483         }
   501         }
   484     
   502     
   485     TImePlguinImplDetail detail;
   503     TImePlguinImplDetail detail;
   486     
   504     
   487     detail.iImplementationId = KInputMethodImplementationId;
   505     detail.iImplementationId = KInputMethodImplementationId;
   590                     }
   608                     }
   591                 }
   609                 }
   592             }
   610             }
   593         delete dir;
   611         delete dir;
   594         }    
   612         }    
       
   613     if( fingerhwr )
       
   614         {
       
   615         detail.iMode = EPluginInputModeFingerHwr;
       
   616         detail.iMeritValue = EImeMerit_Preferred;
       
   617         detail.iDisplayName.Copy(KFingerHwrImeName());
       
   618         detail.iLanguage = ELangArabic;
       
   619         aSupportList.Append(detail);
       
   620         }
   595 
   621 
   596     CleanupStack::PopAndDestroy(&infoArray); // infoArray    
   622     CleanupStack::PopAndDestroy(&infoArray); // infoArray    
   597     
   623     
   598     return 0;
   624     return 0;
   599     }
   625     }
   733     delete iPluginUiManager;
   759     delete iPluginUiManager;
   734     iPluginUiManager = NULL;
   760     iPluginUiManager = NULL;
   735     
   761     
   736     switch ( aMode )
   762     switch ( aMode )
   737         {
   763         {
       
   764         case EPluginInputModeFingerHwr:        
   738         case EPluginInputModeHwr:
   765         case EPluginInputModeHwr:
   739             {
   766             {
   740             return iPluginUiManager = CPluginFepManagerHwr::NewL(*this, iPenInputServer);
   767             return iPluginUiManager = CPluginFepManagerHwr::NewL(*this, iPenInputServer);
   741             }
   768             }
   742         case EPluginInputModeVkb:
   769         case EPluginInputModeVkb: