browserui/browser/BrowserAppInc/BrowserAppDocument.inl
branchRCL_3
changeset 64 6385c4c93049
parent 63 4baee4f15982
child 65 8e6fa1719340
equal deleted inserted replaced
63:4baee4f15982 64:6385c4c93049
     1 /*
       
     2 * Copyright (c) 2002-2004 Nokia Corporation and/or its subsidiary(-ies).
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of the License "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description:  Inline methods for CBrowserAppDocument.
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 #ifndef BROWSER_APP_DOCUMENT_INL
       
    20 #define BROWSER_APP_DOCUMENT_INL
       
    21 
       
    22 // CONSTANTS
       
    23 _LIT( KBrowserAppDocPanicString, "BrowserAppDoc" );
       
    24 
       
    25 // ============================ MEMBER FUNCTIONS ==============================
       
    26 
       
    27 // ----------------------------------------------------------------------------
       
    28 // CBrowserAppDocument::SetDownloadedContentHandler
       
    29 // Implementation info:
       
    30 // Only one of the DownloadedContentHandler is allowed to be set the same time!
       
    31 // The following example will cause Panic:
       
    32 //   browserAppDocument->SetDownloadedContentHandler( this );
       
    33 //   browserAppDocument->SetFileDownloadedContentHandler( that );
       
    34 // It should be used like:
       
    35 //   browserAppDocument->SetDownloadedContentHandler( NULL );
       
    36 //   browserAppDocument->SetFileDownloadedContentHandler( this );
       
    37 // ----------------------------------------------------------------------------
       
    38 //
       
    39 inline void CBrowserAppDocument::SetDownloadedContentHandler
       
    40             ( MDownloadedContentHandler* aObserver )
       
    41     {
       
    42     if ( aObserver != NULL )
       
    43         {
       
    44         __ASSERT_ALWAYS( iDownloadedContentHandler == NULL, 
       
    45             User::Panic( KBrowserAppDocPanicString, 
       
    46             Util::EFileDownloadedContentHandlerAlreadyInitialized ) );
       
    47         }
       
    48     iDownloadedContentHandler = aObserver;
       
    49     }
       
    50 
       
    51 #endif /* BROWSER_APP_DOCUMENT_INL */
       
    52 
       
    53 // End of File