2 * Copyright 2004-2012, Haiku, Inc. All rights reserved.
3 * Copyright 2001 Dr. Zoidberg Enterprises. All rights reserved.
5 * Distributed under the terms of the MIT License.
7 #ifndef _FILE_CONFIG_VIEW_H
8 #define _FILE_CONFIG_VIEW_H
12 #include <FilePanel.h>
16 class BMailAddOnSettings
;
23 class FileControl
: public BView
{
25 FileControl(const char* name
, const char* label
,
26 const char* pathOfFile
= NULL
,
27 uint32 flavors
= B_DIRECTORY_NODE
);
28 virtual ~FileControl();
30 virtual void AttachedToWindow();
31 virtual void MessageReceived(BMessage
* message
);
33 void SetText(const char* pathOfFile
);
34 const char* Text() const;
36 void SetEnabled(bool enabled
);
48 class MailFileConfigView
: public FileControl
{
50 MailFileConfigView(const char* label
,
51 const char* name
, bool useMeta
= false,
52 const char* defaultPath
= NULL
,
53 uint32 flavors
= B_DIRECTORY_NODE
);
55 void SetTo(const BMessage
* archive
,
57 status_t
SaveInto(BMailAddOnSettings
& settings
) const;
68 } // namespace BPrivate
71 #endif // _FILE_CONFIG_VIEW_H