|
1 /******************************************************************************* |
|
2 * Copyright (c) 2007, 2010 Nokia Corporation and/or its subsidiary(-ies). |
|
3 * All rights reserved. This program and the accompanying materials |
|
4 * are made available under the terms of the Eclipse Public License v1.0 |
|
5 * which accompanies this distribution, and is available at |
|
6 * http://www.eclipse.org/legal/epl-v10.html |
|
7 * |
|
8 * Contributors: |
|
9 * Nokia Corporation - S60 implementation |
|
10 *******************************************************************************/ |
|
11 |
|
12 |
|
13 #ifndef SWTCOMMONFILEDIALOGS_H |
|
14 #define SWTCOMMONFILEDIALOGS_H |
|
15 |
|
16 |
|
17 #include <e32def.h> |
|
18 #include <e32cmn.h> |
|
19 |
|
20 |
|
21 enum TSwtFileDialogType |
|
22 { |
|
23 ESwtFileDialogFileSelect = 0, |
|
24 ESwtFileDialogFileSave, |
|
25 ESwtFileDialogFolderSelect |
|
26 }; |
|
27 |
|
28 |
|
29 /** |
|
30 * SwtCommonFileDialogs |
|
31 * @lib eswt |
|
32 */ |
|
33 NONSHARABLE_CLASS(SwtCommonFileDialogs) |
|
34 { |
|
35 public: |
|
36 /** |
|
37 * Run file or folder selection dialog(s). If the given path is |
|
38 * empty a memory selection dialog is run first. Next a file or |
|
39 * folder selection dialog will be run. In the case of a file |
|
40 * save dialog a prompt dialog will be run in the end. |
|
41 * @param aFileDialogType See TSwtFileDialogType. |
|
42 * @param aPath Cannot be NULL. The path to the selected folder |
|
43 * or file goes here. If initial path is given, the dialog |
|
44 * will be browsing only from that path onwords. |
|
45 * @param aTitle title to be applied to the dialog(s). |
|
46 * @return ETrue if dialog submitted, EFalse if dialog cancelled |
|
47 */ |
|
48 static TBool RunFileDialogLD( |
|
49 TSwtFileDialogType aFileDialogType, |
|
50 const TDesC& aTitle, |
|
51 HBufC* aPath); |
|
52 }; |
|
53 |
|
54 #endif // SWTCOMMONFILEDIALOGS_H |