Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members

FXDirDialog.h
1 /********************************************************************************
2 * *
3 * D i r e c t o r y S e l e c t i o n D i a l o g *
4 * *
5 *********************************************************************************
6 * Copyright (C) 2000,2017 by Jeroen van der Zijp. All Rights Reserved. *
7 *********************************************************************************
8 * This library is free software; you can redistribute it and/or modify *
9 * it under the terms of the GNU Lesser General Public License as published by *
10 * the Free Software Foundation; either version 3 of the License, or *
11 * (at your option) any later version. *
12 * *
13 * This library is distributed in the hope that it will be useful, *
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of *
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
16 * GNU Lesser General Public License for more details. *
17 * *
18 * You should have received a copy of the GNU Lesser General Public License *
19 * along with this program. If not, see <http://www.gnu.org/licenses/> *
20 ********************************************************************************/
21 #ifndef FXDIRDIALOG_H
22 #define FXDIRDIALOG_H
23 
24 #ifndef FXDIALOGBOX_H
25 #include "FXDialogBox.h"
26 #endif
27 
28 namespace FX {
29 
30 
31 class FXFileAssociations;
32 class FXDirSelector;
33 
34 
41 class FXAPI FXDirDialog : public FXDialogBox {
42  FXDECLARE(FXDirDialog)
43 protected:
44  FXDirSelector *dirbox; // Directory selection widget
45 protected:
46  FXDirDialog(){}
47  void initdialog();
48 private:
49  FXDirDialog(const FXDirDialog&);
50  FXDirDialog &operator=(const FXDirDialog&);
51 public:
52 
54  FXDirDialog(FXWindow* owner,const FXString& name,FXuint opts=0,FXint x=0,FXint y=0,FXint w=400,FXint h=300);
55 
57  FXDirDialog(FXApp* a,const FXString& name,FXuint opts=0,FXint x=0,FXint y=0,FXint w=400,FXint h=300);
58 
60  virtual void hide();
61 
63  void setDirectory(const FXString& path);
64 
66  FXString getDirectory() const;
67 
69  void setPattern(const FXString& ptrn);
70 
72  FXString getPattern() const;
73 
75  FXuint getMatchMode() const;
76 
78  void setMatchMode(FXuint mode);
79 
81  FXbool showFiles() const;
82 
84  void showFiles(FXbool showing);
85 
87  FXbool showHiddenFiles() const;
88 
90  void showHiddenFiles(FXbool showing);
91 
93  void setDirBoxStyle(FXuint style);
94 
96  FXuint getDirBoxStyle() const;
97 
99  void setAssociations(FXFileAssociations* assoc,FXbool owned=false);
100 
102  FXFileAssociations* getAssociations() const;
103 
105  static FXString getOpenDirectory(FXWindow* owner,const FXString& caption,const FXString& path);
106 
108  virtual void save(FXStream& store) const;
109 
111  virtual void load(FXStream& store);
112 
114  virtual ~FXDirDialog();
115  };
116 
117 }
118 
119 #endif

Copyright © 1997-2016 Jeroen van der Zijp