bluetoothengine/btnotif/inc/btninqui.h
branchRCL_3
changeset 35 95674584745d
parent 0 f63038272f30
equal deleted inserted replaced
21:53b7818cd282 35:95674584745d
   109 
   109 
   110         /**
   110         /**
   111          * Check if Eir device name available.
   111          * Check if Eir device name available.
   112          * @param TNameEntry    Decode it to get device name
   112          * @param TNameEntry    Decode it to get device name
   113          * @param TBTDeviceName Device name returned
   113          * @param TBTDeviceName Device name returned
       
   114          * @param TBool         Is the name returned complete
   114          * @return ETrue if Eir data contains name.
   115          * @return ETrue if Eir data contains name.
   115          */
   116          */
   116         static TBool CheckEirDeviceName( TNameEntry& aEntry, TBTDeviceName& aName );
   117         static TBool CheckEirDeviceName( TNameEntry& aEntry, TBTDeviceName& aName, TBool& aIsComplete );
   117 
   118 
   118     private: // Functions from base classes
   119     private: // Functions from base classes
   119         
   120         
   120         /**
   121         /**
   121          * From MBTNotifActiveObserver
   122          * From MBTNotifActiveObserver
   191         * Updates friendly name of given device if one is found from registry.
   192         * Updates friendly name of given device if one is found from registry.
   192         * @param aDevice The device to be added to list.
   193         * @param aDevice The device to be added to list.
   193         * @param aSignalStrength The signal bar for RSSI
   194         * @param aSignalStrength The signal bar for RSSI
   194         * @return None.
   195         * @return None.
   195         */
   196         */
   196         void UpdateDeviceListL(CBTDevice* aDevice, const TInt aSignalStrength = 0 );             
   197         void AddToDeviceListBoxL(CBTDevice* aDevice, const TInt aSignalStrength = 0 );             
   197 		
   198 		
   198 		/**
   199 		/**
   199         * Creates and adds local bitmap to icon array.
   200         * Creates and adds local bitmap to icon array.
   200         * @param aID Item ID of the masked bitmap to be created.
   201         * @param aID Item ID of the masked bitmap to be created.
   201         * @param aFilename Filename to be used to construct the item.
   202         * @param aFilename Filename to be used to construct the item.
   280         
   281         
   281         /**
   282         /**
   282          * Adds found Bluetooth device into popup list.
   283          * Adds found Bluetooth device into popup list.
   283          * @param aInquiryResultRecord TNameEntry and flag, which indicates if Eir device.
   284          * @param aInquiryResultRecord TNameEntry and flag, which indicates if Eir device.
   284          */
   285          */
   285         void DeviceAvailableL( const TNameRecord& aNameRecord, const TDesC& aDevName);
   286         void DeviceAvailableL( const TNameRecord& aNameRecord, const TDesC& aDevName, TBool aIsNameComplete );
   286         
   287         
   287         /**
   288         /**
   288         * The inquiry has been completed.
   289         * The inquiry has been completed.
   289         * @param aError Status code of the operation.
   290         * @param aError Status code of the operation.
   290         * @return None.
   291         * @return None.
   294         /**
   295         /**
   295          * Inform the caller of the properties of found BTdevice, 
   296          * Inform the caller of the properties of found BTdevice, 
   296          * which passes the search filter. Its name will be retrived later
   297          * which passes the search filter. Its name will be retrived later
   297          */
   298          */
   298         void HandleInquiryDeviceL();
   299         void HandleInquiryDeviceL();
   299         
   300 
   300         void HandleFoundNameL();   
   301         /**
   301         
   302          * Name lookup complete for the current device in the unnamed devices queue.
       
   303          */
       
   304         void HandleFoundNameL();  
       
   305 
       
   306         /**
       
   307          * Name lookup complete for device aLastSeenIndex in the last seen array
       
   308          * (this is done for devices with partial names returned by EIR).
       
   309          */
       
   310         void HandleUpdatedNameL(TInt aLastSeenIndex);
       
   311 
   302         /**
   312         /**
   303          * Allow/Disallow dialer and app key presses.
   313          * Allow/Disallow dialer and app key presses.
   304          * @param aAllow ETrue to allow  key press; EFalse to disallow.
   314          * @param aAllow ETrue to allow  key press; EFalse to disallow.
   305          */
   315          */
   306         void AllowDialerAndAppKeyPress( TBool aAllow );
   316         void AllowDialerAndAppKeyPress( TBool aAllow );
   307 
   317 
       
   318         /**
       
   319          * Update the inquiry list box with a new (complete) device name
       
   320          * (this is done for devices with partial names returned by EIR).
       
   321          */
       
   322         void DeviceNameUpdatedL(const TNameRecord& aNameRecord, TInt aLastSeenIndex);
       
   323         void DeviceUpdatedL(TInt aSignalStrength, TInt aLastSeenIndex);
       
   324 
       
   325         /**
       
   326          * React to page timeout on a device that's already in the inquiry list box
       
   327          * (which can happen for devices with partial names returned by EIR).
       
   328          */
       
   329         void PageTimeoutOnDeviceWithPartialNameL(TInt aLastSeenIndex);
       
   330 
       
   331         void FormatListBoxEntryL(CBTDevice& aDevice, const TInt aSignalStrength, TPtr aFormatString);
       
   332 
       
   333         TBool HaveDevsWithPartialName(TInt& aFirstFoundIndex);
       
   334 
   308     private:  // Data
   335     private:  // Data
   309         CBTNotifUIUtil*         iUiUtil;
   336         CBTNotifUIUtil*         iUiUtil;
   310         CBTDeviceArray*         iLastSeenDevicesArray;            // Last seen devices array from BTInqNotifier
   337         CBTDeviceArray*         iLastSeenDevicesArray;           // Last seen devices array from BTInqNotifier
       
   338         RArray<TBool>           iLastSeenDevicesNameComplete;    // Is the name in corresponding cell of iLastSeenDevicesArray complete ?
   311         CBTDeviceArray*         iLastUsedDevicesArray;           // Used devices from BT registry
   339         CBTDeviceArray*         iLastUsedDevicesArray;           // Used devices from BT registry
   312         CBTDeviceArray*         iPairedDevicesArray;             // Paired devices from Bluetooth registry
   340         CBTDeviceArray*         iPairedDevicesArray;             // Paired devices from Bluetooth registry
   313         CBTDeviceArray*         iAdjustedUsedDeviceArray;         // 5 Lately used devices + All the Paired devices 
   341         CBTDeviceArray*         iAdjustedUsedDeviceArray;         // 5 Lately used devices + All the Paired devices 
   314         CBTEngDevMan*           iDevMan;                        //Async deviceHandler
   342         CBTEngDevMan*           iDevMan;                        //Async deviceHandler
   315          
   343          
   340         RHostResolver       iHostResolver;      // Host resolver object
   368         RHostResolver       iHostResolver;      // Host resolver object
   341         TInquirySockAddr    iInquirySockAddr;   // Socket address record
   369         TInquirySockAddr    iInquirySockAddr;   // Socket address record
   342         TNameEntry          iEntry;             // Inquiry results record
   370         TNameEntry          iEntry;             // Inquiry results record
   343         TBool               iPageForName;    // Flag for inquiry name
   371         TBool               iPageForName;    // Flag for inquiry name
   344         RArray<TNameRecord> iDevsWithoutName;    // Devices without dev name 
   372         RArray<TNameRecord> iDevsWithoutName;    // Devices without dev name 
   345         TInt                iIndex;             // Current btdevice to inquiry its name 
   373         TInt                iCurrentlyResolvingUnnamedDeviceIndex;             // Current btdevice to inquiry its name 
   346         MBTNDeviceSearchObserver* iDevSearchObserver;
   374         MBTNDeviceSearchObserver* iDevSearchObserver;
   347 
   375 
   348 		TBool               iExcludePairedDevices;
   376 		TBool               iExcludePairedDevices;
   349 		
   377 		
   350 
   378