First public contribution.
2 * Copyright (c) 2004-2009 Nokia Corporation and/or its subsidiary(-ies).
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".
9 * Initial Contributors:
10 * Nokia Corporation - initial contribution.
15 * This defines an interface used by the F32 Agent to display information on
16 * the screen. The default implementation does nothing. Licensees wishing to allow the F32
17 * agent to display information on the screen should replace this DLL with
18 * a DLL that does display information on screen.
29 #ifndef __F32AGENTUI_H__
30 #define __F32AGENTUI_H__
36 namespace ContentAccess
38 /** Interface that must be implemented in order for the F32 agent to display
39 information on the screen
41 class CF32AgentUi : public CBase
44 /** The implementation of this API will display a dialog asking the user to confirm deletion
45 of a file. The implementation will display the dialog if the appropriate setting,
46 TAgentProperty::EAgentPropertyAgentUI, has been set using CF32AgentUi::SetProperty, enabling
47 the Agent UI. If the user selects to delete the file ETrue will be returned, EFalse if the
48 file is not to be deleted. If the Agent UI is not enabled a default value of ETrue will be
51 The function should only return once the dialog has completed
53 @param aFileName The name of the file that is about to be deleted
54 @return Whether to delete the file
55 @return ETrue If the file is to be deleted
56 @return EFalse If the file is not to be deleted
58 virtual TBool ConfirmDeleteL(const TDesC& aFileName) = 0;
61 /** Display information describing the supplied file
63 The file will already be open before calling this function.
64 The function should only return once the dialog has completed
66 @param aInfo The information to display, from ContentAccess::TDisplayInfo
67 @param aFile The file to display
68 @return KErrNone or one of the system wide error codes
70 virtual void DisplayInfoL(TInt aInfo, RFile& aFile) = 0;
72 /** The implementation of this API will action/remember Agent properties applicable to the Agent UI.
74 Currently the F32 Agent only supports one UI property - TAgentProperty::EAgentPropertyAgentUI,
75 enabling or disabling the Agent UI. The implementation of this function should store the property
76 that has been set and subsequent requests to the interface should be dealt with in accordance
77 with these properties.
79 @see CF32AgentUi::ConfirmDeleteL
81 The implementation will return KErrNone if the property has been set correctly or KErrCANotSupported
82 if the property supplied is not supported.
84 @param aProperty The property to set, from ContentAccess::TAgentProperty
85 @param aValue The value of the property
86 @return Whether the property was set
87 @return KErrNone if the property was set correctly
88 @return KErrCANotSupported if the property is not supported
90 virtual TInt SetProperty(TInt aProperty, TInt aValue) = 0;
93 /** Factory function that creates the F32 Agent UI
94 @return a CF32AgentUi object
96 class TF32AgentUiFactory
99 IMPORT_C static CF32AgentUi* CreateF32AgentUiL();
105 #endif // __F32AGENTUI_H__