Symbian3/PDK/Source/GUID-AC53C0A0-6990-4BF8-91E9-9AE14169A7BC.dita
changeset 5 f345bda72bc4
parent 1 25a17d01db0c
child 14 578be2adaf3e
equal deleted inserted replaced
4:4816d766a08a 5:f345bda72bc4
    10 <!DOCTYPE concept
    10 <!DOCTYPE concept
    11   PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
    11   PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
    12 <concept id="GUID-AC53C0A0-6990-4BF8-91E9-9AE14169A7BC" xml:lang="en"><title>Creating
    12 <concept id="GUID-AC53C0A0-6990-4BF8-91E9-9AE14169A7BC" xml:lang="en"><title>Creating
    13 a Privacy Verification Notifier</title><shortdesc>To use the LBS Privacy Notifiers for privacy verification and privacy
    13 a Privacy Verification Notifier</title><shortdesc>To use the LBS Privacy Notifiers for privacy verification and privacy
    14 notification a licensee must implement a Privacy Verification Notifier that
    14 notification a licensee must implement a Privacy Verification Notifier that
    15 extends from the Extended Notifier Framework base class <apiname>MEikSrvNotifierBase2</apiname>.
    15 extends from the Extended Notifier Framework base class <codeph>MEikSrvNotifierBase2</codeph>.
    16 The licensee must override the asynchronous <apiname>MEikSrvNotifierBase2::StartL()</apiname> method
    16 The licensee must override the asynchronous <codeph>MEikSrvNotifierBase2::StartL()</codeph> method
    17 so that the LBS subsystem can receive a privacy response from the user via
    17 so that the LBS subsystem can receive a privacy response from the user via
    18 the notifier. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
    18 the notifier. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
    19 <p>This topic describes how to implement a Privacy Verification Notifier.
    19 <p>This topic describes how to implement a Privacy Verification Notifier.
    20 The notifier is used to handle privacy verification requests.   </p>
    20 The notifier is used to handle privacy verification requests.   </p>
    21 <p>A dialog is shown to the user when verification of a privacy request is
    21 <p>A dialog is shown to the user when verification of a privacy request is
    30 some licensee UI framework-specific subclass). </p></li>
    30 some licensee UI framework-specific subclass). </p></li>
    31 <li><p>Override the necessary virtual methods of the licensee notifier and
    31 <li><p>Override the necessary virtual methods of the licensee notifier and
    32 dialog to handle privacy requests and send the appropriate response when the
    32 dialog to handle privacy requests and send the appropriate response when the
    33 user dismisses the dialog. </p></li>
    33 user dismisses the dialog. </p></li>
    34 </ul>
    34 </ul>
    35 <section>       <title>Defining the Privacy Verification Notifier</title> 
    35 <section id="GUID-0BA4DF3B-7363-4353-9A99-E7272500967B">       <title>Defining the Privacy Verification Notifier</title> 
    36      <p>The code below shows a definition of a Privacy Verification Notifier
    36      <p>The code below shows a definition of a Privacy Verification Notifier
    37 class.     </p><p>The notifier owns a <xref href="GUID-BFDCA64A-1F55-34E8-8C4D-B0EABBE3A17C.dita"><apiname>CMyLBSPrivacyVerifierDialog</apiname></xref> dialog
    37 class.     </p><p>The notifier owns a <xref href="GUID-BFDCA64A-1F55-34E8-8C4D-B0EABBE3A17C.dita"><apiname>CMyLBSPrivacyVerifierDialog</apiname></xref> dialog
    38 class to show details of the privacy request to the end user and to obtain
    38 class to show details of the privacy request to the end user and to obtain
    39 the response.  </p><codeblock xml:space="preserve">/*
    39 the response.  </p><codeblock xml:space="preserve">/*
    40 ============================================================================
    40 ============================================================================
   113   // Verification Dialog
   113   // Verification Dialog
   114   CMyLBSPrivacyVerifierDialog* iDlg;
   114   CMyLBSPrivacyVerifierDialog* iDlg;
   115   };
   115   };
   116 
   116 
   117 #endif  // __MYLBSPRIVACYNOTIFIER_H__</codeblock>     </section>
   117 #endif  // __MYLBSPRIVACYNOTIFIER_H__</codeblock>     </section>
   118 <section><title>Defining the Privacy Verification Dialog </title><p>The following
   118 <section id="GUID-807AAC06-8975-41C8-8D4C-CF6103D0678D"><title>Defining the Privacy Verification Dialog </title><p>The following
   119 is the definition of the dialog used by the example Privacy Verification Notifier:</p><codeblock xml:space="preserve">/*
   119 is the definition of the dialog used by the example Privacy Verification Notifier:</p><codeblock xml:space="preserve">/*
   120 ============================================================================
   120 ============================================================================
   121  Name		: MyLBSPrivacyVerifier.cpp
   121  Name		: MyLBSPrivacyVerifier.cpp
   122  Description : Source for LBS privacy verification notifier and dialog
   122  Description : Source for LBS privacy verification notifier and dialog
   123 ============================================================================
   123 ============================================================================
   257 #define __MYLBSNOTIFIERSCHANNEL_H_
   257 #define __MYLBSNOTIFIERSCHANNEL_H_
   258 
   258 
   259 const TUid KScreenOutputChannel={0x1000ABEF};
   259 const TUid KScreenOutputChannel={0x1000ABEF};
   260 
   260 
   261 #endif /*MYLBSNOTIFIERSCHANNEL_H_*/</codeblock></section>
   261 #endif /*MYLBSNOTIFIERSCHANNEL_H_*/</codeblock></section>
   262 <section><title>Creating the notifier </title><p>The most important thing
   262 <section id="GUID-877CB502-8329-4441-8B1A-D8F85C932A38"><title>Creating the notifier </title><p>The most important thing
   263 to consider when creating a notifier object is if the dialog resources should
   263 to consider when creating a notifier object is if the dialog resources should
   264 also be created at the same time.     </p><p>The ECOM framework calls the
   264 also be created at the same time.     </p><p>The ECOM framework calls the
   265 notifier's <codeph>NewL()</codeph> when the notifier server starts up. Privacy
   265 notifier's <codeph>NewL()</codeph> when the notifier server starts up. Privacy
   266 requests and location requests may need to be handled in low memory conditions
   266 requests and location requests may need to be handled in low memory conditions
   267 (where licensees and operators need to support emergency location requests).
   267 (where licensees and operators need to support emergency location requests).
   284 // in low memory conditions
   284 // in low memory conditions
   285 void CMyLBSPrivacyVerifier::ConstructL()
   285 void CMyLBSPrivacyVerifier::ConstructL()
   286   {	
   286   {	
   287   iDlg = CMyLBSPrivacyVerifierDialog::NewLD(this, iResponseParams);
   287   iDlg = CMyLBSPrivacyVerifierDialog::NewLD(this, iResponseParams);
   288   }</codeblock></section>
   288   }</codeblock></section>
   289 <section><title>Registering the notifier </title><p><xref href="GUID-DE445C4B-22EF-3A1F-8A69-57CB703BFAD0.dita#GUID-DE445C4B-22EF-3A1F-8A69-57CB703BFAD0/GUID-7863DC49-9664-390C-AAE1-B3BE043CA108"><apiname>MEikSrvNotifierBase2::RegisterL()</apiname></xref> and <xref href="GUID-DE445C4B-22EF-3A1F-8A69-57CB703BFAD0.dita#GUID-DE445C4B-22EF-3A1F-8A69-57CB703BFAD0/GUID-EC4180F5-AB27-3744-8755-BA59B3BCE19C"><apiname>MEikSrvNotifierBase2::Info()</apiname></xref> are standard notifier methods that can be implemented as shown below: </p><codeblock xml:space="preserve">// Called by notifier framework once to register the notifier with ECOM
   289 <section id="GUID-02E6910A-662A-4663-A3AA-AA3D9EBB449D"><title>Registering the notifier </title><p><xref href="GUID-DE445C4B-22EF-3A1F-8A69-57CB703BFAD0.dita#GUID-DE445C4B-22EF-3A1F-8A69-57CB703BFAD0/GUID-7863DC49-9664-390C-AAE1-B3BE043CA108"><apiname>MEikSrvNotifierBase2::RegisterL()</apiname></xref> and <xref href="GUID-DE445C4B-22EF-3A1F-8A69-57CB703BFAD0.dita#GUID-DE445C4B-22EF-3A1F-8A69-57CB703BFAD0/GUID-EC4180F5-AB27-3744-8755-BA59B3BCE19C"><apiname>MEikSrvNotifierBase2::Info()</apiname></xref> are standard notifier methods that can be implemented as shown below: </p><codeblock xml:space="preserve">// Called by notifier framework once to register the notifier with ECOM
   290 MEikSrvNotifierBase2::TNotifierInfo CMyLBSPrivacyVerifier::RegisterL()
   290 MEikSrvNotifierBase2::TNotifierInfo CMyLBSPrivacyVerifier::RegisterL()
   291   {
   291   {
   292   iInfo.iUid = KLbsExtLocationRequestVerifyUid;
   292   iInfo.iUid = KLbsExtLocationRequestVerifyUid;
   293   iInfo.iChannel = KScreenOutputChannel;
   293   iInfo.iChannel = KScreenOutputChannel;
   294 
   294 
   302   return iInfo;
   302   return iInfo;
   303   }</codeblock><note>The value <codeph>KLbsExtLocationRequestVerifyUid</codeph> as
   303   }</codeblock><note>The value <codeph>KLbsExtLocationRequestVerifyUid</codeph> as
   304 defined in <filepath>lbsextprivacynotifiers.h</filepath> must be used for
   304 defined in <filepath>lbsextprivacynotifiers.h</filepath> must be used for
   305 the notifier registration. The choice of notifier priority is a licensee decision,
   305 the notifier registration. The choice of notifier priority is a licensee decision,
   306 but a high priority is recommended because a user response is required. </note></section>
   306 but a high priority is recommended because a user response is required. </note></section>
   307 <section><title>Starting the notifier </title><p>A Privacy Verification Notifier
   307 <section id="GUID-C1D1F5AA-9C94-43F1-9A14-003A42B7FDF1"><title>Starting the notifier </title><p>A Privacy Verification Notifier
   308 must implement the asynchronous form of <xref href="GUID-650E29C8-3B2B-3B77-A4E5-766DED0F83F0.dita#GUID-650E29C8-3B2B-3B77-A4E5-766DED0F83F0/GUID-93746BF4-4F20-304A-BC72-2CE0C776D001"><apiname>MEikSrvNortifierBase2::StartL()</apiname></xref>.
   308 must implement the asynchronous form of <xref href="GUID-650E29C8-3B2B-3B77-A4E5-766DED0F83F0.dita#GUID-650E29C8-3B2B-3B77-A4E5-766DED0F83F0/GUID-93746BF4-4F20-304A-BC72-2CE0C776D001"><apiname>MEikSrvNortifierBase2::StartL()</apiname></xref>.
   309 The code example below shows how to do this. The LBS subsystem sends a <codeph>TLbsPrivacyNotifierParamsPckg</codeph> object
   309 The code example below shows how to do this. The LBS subsystem sends a <codeph>TLbsPrivacyNotifierParamsPckg</codeph> object
   310 to the notifier from which the <codeph>TLbsExternalRequestInfo</codeph> can
   310 to the notifier from which the <codeph>TLbsExternalRequestInfo</codeph> can
   311 be extracted. </p><codeblock xml:space="preserve">// Asynchronous StartL is used for privacy verification because a response is required
   311 be extracted. </p><codeblock xml:space="preserve">// Asynchronous StartL is used for privacy verification because a response is required
   312 void CMyLBSPrivacyVerifier::StartL(const TDesC8&amp; aBuffer,
   312 void CMyLBSPrivacyVerifier::StartL(const TDesC8&amp; aBuffer,
   329   // Show the dialog with the requester details
   329   // Show the dialog with the requester details
   330   iDlg-&gt;ShowDialog(info);
   330   iDlg-&gt;ShowDialog(info);
   331   }</codeblock><note>A Privacy Verification Notifier need only implement an
   331   }</codeblock><note>A Privacy Verification Notifier need only implement an
   332 empty implementation of the synchronous <xref href="GUID-DE445C4B-22EF-3A1F-8A69-57CB703BFAD0.dita#GUID-DE445C4B-22EF-3A1F-8A69-57CB703BFAD0/GUID-5DC8D35F-FFA5-3CE8-A06D-303A7E3ECC9B"><apiname>MEikSrvNotifierBase2::StartL()</apiname></xref> method.
   332 empty implementation of the synchronous <xref href="GUID-DE445C4B-22EF-3A1F-8A69-57CB703BFAD0.dita#GUID-DE445C4B-22EF-3A1F-8A69-57CB703BFAD0/GUID-5DC8D35F-FFA5-3CE8-A06D-303A7E3ECC9B"><apiname>MEikSrvNotifierBase2::StartL()</apiname></xref> method.
   333  </note></section>
   333  </note></section>
   334 <section><title>Getting the privacy response parameters </title><p>The example
   334 <section id="GUID-7CB6FB2E-6C29-40E1-97FF-2F7F79DA5237"><title>Getting the privacy response parameters </title><p>The example
   335 notifier has a method called <codeph>DialogDismissed()</codeph> which is called
   335 notifier has a method called <codeph>DialogDismissed()</codeph> which is called
   336 by the verification dialog when it is closed (either by pressing <uicontrol>Accept</uicontrol> or <uicontrol>Cancel</uicontrol>).
   336 by the verification dialog when it is closed (either by pressing <uicontrol>Accept</uicontrol> or <uicontrol>Cancel</uicontrol>).
   337 The method implementation below shows how to package up the privacy response
   337 The method implementation below shows how to package up the privacy response
   338 into a <codeph>TLbsPrivacyReponseParamsPckg</codeph>, complete the message
   338 into a <codeph>TLbsPrivacyReponseParamsPckg</codeph>, complete the message
   339 and cancel the notifier. </p><codeblock xml:space="preserve">// Called when dialog is dismissed
   339 and cancel the notifier. </p><codeblock xml:space="preserve">// Called when dialog is dismissed
   350 
   350 
   351     // Cancel the notifier
   351     // Cancel the notifier
   352     iManager-&gt;CancelNotifier(KLbsExtLocationRequestVerifyUid);
   352     iManager-&gt;CancelNotifier(KLbsExtLocationRequestVerifyUid);
   353 		  }
   353 		  }
   354   }</codeblock></section>
   354   }</codeblock></section>
   355 <section><title>Cancelling the notifier </title><p>The LBS subsystem has a
   355 <section id="GUID-23311FBA-CC3B-4F85-8796-0EEB75C8E6F8"><title>Cancelling the notifier </title><p>The LBS subsystem has a
   356 timeout for Privacy Notifiers that calls the <xref href="GUID-DE445C4B-22EF-3A1F-8A69-57CB703BFAD0.dita#GUID-DE445C4B-22EF-3A1F-8A69-57CB703BFAD0/GUID-D53FC05F-B90A-3CB6-874E-39C4709310C9"><apiname>MEikSrvNotifierBase2::Cancel()</apiname></xref> method. </p><codeblock xml:space="preserve">// Called to cancel the notification (for example for a request timeout)
   356 timeout for Privacy Notifiers that calls the <xref href="GUID-DE445C4B-22EF-3A1F-8A69-57CB703BFAD0.dita#GUID-DE445C4B-22EF-3A1F-8A69-57CB703BFAD0/GUID-D53FC05F-B90A-3CB6-874E-39C4709310C9"><apiname>MEikSrvNotifierBase2::Cancel()</apiname></xref> method. </p><codeblock xml:space="preserve">// Called to cancel the notification (for example for a request timeout)
   357 // The LBS subsystem sets the timeout for privacy notifiers
   357 // The LBS subsystem sets the timeout for privacy notifiers
   358 void CMyLBSPrivacyVerifier::Cancel()
   358 void CMyLBSPrivacyVerifier::Cancel()
   359   {
   359   {
   360   if (!iMessage.IsNull())
   360   if (!iMessage.IsNull())
   361     {
   361     {
   362 		  iMessage.Complete(KErrCancel);
   362 		  iMessage.Complete(KErrCancel);
   363 		  }
   363 		  }
   364   iDlg-&gt;HideDialog();
   364   iDlg-&gt;HideDialog();
   365   }</codeblock></section>
   365   }</codeblock></section>
   366 <section><title>Releasing the notifier </title><p>The ECOM release method
   366 <section id="GUID-E5FEA4BE-C9C2-4017-85CD-D1078DE08DD2"><title>Releasing the notifier </title><p>The ECOM release method
   367 just calls delete on the notifier.</p><codeblock xml:space="preserve">// Just delete the notifier
   367 just calls delete on the notifier.</p><codeblock xml:space="preserve">// Just delete the notifier
   368 void CMyLBSPrivacyVerifier::Release()
   368 void CMyLBSPrivacyVerifier::Release()
   369   {
   369   {
   370   delete this;
   370   delete this;
   371   }</codeblock></section>
   371   }</codeblock></section>
   372 <section><title>Notifier destructor </title><p>The destructor method just
   372 <section id="GUID-EE7AF256-6146-4176-AA26-AE6C2A4D46FA"><title>Notifier destructor </title><p>The destructor method just
   373 deletes the dialog object that was created in the notifier's <codeph>ConstructL()</codeph>. </p><codeblock xml:space="preserve">CMyLBSPrivacyVerifier::~CMyLBSPrivacyVerifier()
   373 deletes the dialog object that was created in the notifier's <codeph>ConstructL()</codeph>. </p><codeblock xml:space="preserve">CMyLBSPrivacyVerifier::~CMyLBSPrivacyVerifier()
   374   {
   374   {
   375   if (iDlg)
   375   if (iDlg)
   376     {
   376     {
   377     // Delete the dialog
   377     // Delete the dialog
   378     delete iDlg;
   378     delete iDlg;
   379     }
   379     }
   380   }</codeblock></section>
   380   }</codeblock></section>
   381 <section><title>Constructing the dialog </title><p>These methods show how
   381 <section id="GUID-C0E3B59D-BDD1-4838-B592-CB924866690A"><title>Constructing the dialog </title><p>These methods show how
   382 the dialog is constructed. A reference to the response parameters object owned
   382 the dialog is constructed. A reference to the response parameters object owned
   383 by the parent notifier is passed by reference in the <codeph>NewLD()</codeph> method.
   383 by the parent notifier is passed by reference in the <codeph>NewLD()</codeph> method.
   384 This is written to when the user chooses to accept or reject the privacy request. </p><codeblock xml:space="preserve">// Static function to create new dialog
   384 This is written to when the user chooses to accept or reject the privacy request. </p><codeblock xml:space="preserve">// Static function to create new dialog
   385 // Response parameters passed by reference
   385 // Response parameters passed by reference
   386 // They are written when the dialog closes
   386 // They are written when the dialog closes
   410 // Second stage constructor - load dialog resources
   410 // Second stage constructor - load dialog resources
   411 void CMyLBSPrivacyVerifierDialog::ConstructL()
   411 void CMyLBSPrivacyVerifierDialog::ConstructL()
   412   {
   412   {
   413   LoadResourceL();	
   413   LoadResourceL();	
   414   }</codeblock></section>
   414   }</codeblock></section>
   415 <section><title>Loading dialog resources </title><p>For the example shown,
   415 <section id="GUID-4D973BCC-62F4-416A-B6E4-E0A4B5AC94CC"><title>Loading dialog resources </title><p>For the example shown,
   416 the dialog resources are loaded when it is constructed (a sleeping dialog).
   416 the dialog resources are loaded when it is constructed (a sleeping dialog).
   417 This is a good design decision for dialogs that must be shown in low memory
   417 This is a good design decision for dialogs that must be shown in low memory
   418 conditions, which is the case for the LBS dialogs that must notify of emergency
   418 conditions, which is the case for the LBS dialogs that must notify of emergency
   419 location requests. </p><codeblock xml:space="preserve">// Load resources for the dialog
   419 location requests. </p><codeblock xml:space="preserve">// Load resources for the dialog
   420 void CMyLBSPrivacyVerifierDialog::LoadResourceL()
   420 void CMyLBSPrivacyVerifierDialog::LoadResourceL()
   444   TInt offset = iEikonEnv-&gt;AddLibraryL(&amp;fileName);
   444   TInt offset = iEikonEnv-&gt;AddLibraryL(&amp;fileName);
   445   TRAPD(err, ConstructSleepingDialogL(R_LBS_VERIFY_DIALOG));
   445   TRAPD(err, ConstructSleepingDialogL(R_LBS_VERIFY_DIALOG));
   446   iEikonEnv-&gt;DeleteResourceFile(offset);
   446   iEikonEnv-&gt;DeleteResourceFile(offset);
   447   User::LeaveIfError(err);
   447   User::LeaveIfError(err);
   448   }</codeblock></section>
   448   }</codeblock></section>
   449 <section><title>Showing the dialog </title><p>The method <codeph>ShowDialog()</codeph> is
   449 <section id="GUID-9ADFD48F-E51E-41D5-A292-CC3663A215A0"><title>Showing the dialog </title><p>The method <codeph>ShowDialog()</codeph> is
   450 called by the notifier when it is started by a call to <xref href="GUID-DE445C4B-22EF-3A1F-8A69-57CB703BFAD0.dita#GUID-DE445C4B-22EF-3A1F-8A69-57CB703BFAD0/GUID-5DC8D35F-FFA5-3CE8-A06D-303A7E3ECC9B"><apiname>MEikSrvNotifierBase2::StartL()</apiname></xref>.
   450 called by the notifier when it is started by a call to <xref href="GUID-DE445C4B-22EF-3A1F-8A69-57CB703BFAD0.dita#GUID-DE445C4B-22EF-3A1F-8A69-57CB703BFAD0/GUID-5DC8D35F-FFA5-3CE8-A06D-303A7E3ECC9B"><apiname>MEikSrvNotifierBase2::StartL()</apiname></xref>.
   451 In this example, all dialog resources were allocated at start-up so it is
   451 In this example, all dialog resources were allocated at start-up so it is
   452 only necessary to show it. </p><codeblock xml:space="preserve">void CMyLBSPrivacyVerifierDialog::ShowDialog(TLbsExternalRequestInfo&amp; aInfo)
   452 only necessary to show it. </p><codeblock xml:space="preserve">void CMyLBSPrivacyVerifierDialog::ShowDialog(TLbsExternalRequestInfo&amp; aInfo)
   453   {
   453   {
   454   iInfo = aInfo;
   454   iInfo = aInfo;
   477   edwin -&gt;SetTextL(&amp;clientName.Expand());
   477   edwin -&gt;SetTextL(&amp;clientName.Expand());
   478   edwin-&gt;SetReadOnly(ETrue);
   478   edwin-&gt;SetReadOnly(ETrue);
   479 	
   479 	
   480   // Could also show the requesterId and externalId in the dialog...
   480   // Could also show the requesterId and externalId in the dialog...
   481   }</codeblock></section>
   481   }</codeblock></section>
   482 <section><title>Making a privacy response </title><p>The dialog's <xref href="GUID-DC21E927-18B3-3BBF-9B67-496F2D158B03.dita#GUID-DC21E927-18B3-3BBF-9B67-496F2D158B03/GUID-6AFDB981-BBA2-3A5E-A7A5-BA6B39BC4CE9"><apiname>CEikDialog::OkToExitL()</apiname></xref> method
   482 <section id="GUID-A68D683A-89AE-4D97-AE69-787ABFB21D5B"><title>Making a privacy response </title><p>The dialog's <xref href="GUID-DC21E927-18B3-3BBF-9B67-496F2D158B03.dita#GUID-DC21E927-18B3-3BBF-9B67-496F2D158B03/GUID-6AFDB981-BBA2-3A5E-A7A5-BA6B39BC4CE9"><apiname>CEikDialog::OkToExitL()</apiname></xref> method
   483 is called when the user selects <uicontrol>Accept</uicontrol> or <uicontrol>Cancel</uicontrol>.
   483 is called when the user selects <uicontrol>Accept</uicontrol> or <uicontrol>Cancel</uicontrol>.
   484 This method is implemented to set the <codeph>TLbsPrivacyResponseParameters</codeph> in
   484 This method is implemented to set the <codeph>TLbsPrivacyResponseParameters</codeph> in
   485 the parent notifier with the user response, which is either to accept or reject
   485 the parent notifier with the user response, which is either to accept or reject
   486 the privacy request.</p><codeblock xml:space="preserve">// From CEikDialog - called when a dialog button is pressed
   486 the privacy request.</p><codeblock xml:space="preserve">// From CEikDialog - called when a dialog button is pressed
   487 TBool CMyLBSPrivacyVerifierDialog::OkToExitL(TInt aButtonId)
   487 TBool CMyLBSPrivacyVerifierDialog::OkToExitL(TInt aButtonId)
   503   // Inform the notifier that this dialog is exiting
   503   // Inform the notifier that this dialog is exiting
   504   // so that it can inform the notifier manager
   504   // so that it can inform the notifier manager
   505   iNotifier-&gt;DialogDismissed();
   505   iNotifier-&gt;DialogDismissed();
   506   return ETrue;
   506   return ETrue;
   507   }</codeblock></section>
   507   }</codeblock></section>
   508 <section><title>Hiding the dialog and freeing resources</title><p>The dialog's <codeph>HideDialog()</codeph> method
   508 <section id="GUID-E9090E47-1FBC-434B-8FB1-BF8AD4D7FBA3"><title>Hiding the dialog and freeing resources</title><p>The dialog's <codeph>HideDialog()</codeph> method
   509 is called by the notifier when LBS cancels the notifier, for example if a
   509 is called by the notifier when LBS cancels the notifier, for example if a
   510 timeout occurs or another privacy request is sent (a new privacy request cancels
   510 timeout occurs or another privacy request is sent (a new privacy request cancels
   511 any outstanding privacy request). In this example, the dialog resources are
   511 any outstanding privacy request). In this example, the dialog resources are
   512 not freed because the dialog is a sleeping dialog. </p><codeblock xml:space="preserve">// Hide the dialog and report to the notifier
   512 not freed because the dialog is a sleeping dialog. </p><codeblock xml:space="preserve">// Hide the dialog and report to the notifier
   513 void CMyLBSPrivacyVerifierDialog::HideDialog()
   513 void CMyLBSPrivacyVerifierDialog::HideDialog()