1 /*
2   FXiTe - The Free eXtensIble Text Editor
3   Copyright (c) 2009-2012 Jeffrey Pohlmeyer <yetanothergeek@gmail.com>
4 
5   This program is free software; you can redistribute it and/or modify it
6   under the terms of the GNU General Public License version 3 as
7   published by the Free Software Foundation.
8 
9   This software is distributed in the hope that it will be useful,
10   but WITHOUT ANY WARRANTY; without even the implied warranty of
11   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12   GNU General Public License for more details.
13 
14   You should have received a copy of the GNU General Public License
15   along with this program; if not, write to the Free Software
16   Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
17 */
18 
19 
20 #include "dual_list.h"
21 
22 class ToolbarPrefs: public DualListForm {
23 private:
24   FXDECLARE(ToolbarPrefs);
ToolbarPrefs()25   ToolbarPrefs(){}
26   FXButton* custom_btn;
27   virtual void PopulateAvail();
28   virtual void PopulateUsed();
29   virtual void CheckCount();
30   void NotifyChanged(FXuint what);
31   Settings* prefs;
32   UserMenu**user_menus;
33   FXint invalid;
34 public:
35   long onRemoveItem(FXObject*o, FXSelector sel, void*p);
36   long onInsertCustomItem(FXObject*o, FXSelector sel, void*p);
37   long onChangeBtnSize(FXObject*o,FXSelector sel,void*p);
38   long onChangeBtnWrap(FXObject*o,FXSelector sel,void*p);
39   ToolbarPrefs(FXComposite*p, UserMenu**ums, FXSelector lastid, FXObject*tgt=NULL, FXSelector sel=0);
40   enum {
41     ID_INSERT_CUSTOM=DualListForm::ID_LAST,
42     ID_CHANGE_BTN_WRAP,
43     ID_CHANGE_BTN_SIZE,
44     ID_LAST
45   };
46 };
47 
48 
49 
50 class PopupPrefs: public DualListForm {
51 private:
52   FXDECLARE(PopupPrefs);
PopupPrefs()53   PopupPrefs(){}
54   FXButton* custom_btn;
55   FXButton* separator_btn;
56   virtual void PopulateAvail();
57   virtual void PopulateUsed();
58   virtual void CheckCount();
59   UserMenu**user_menus;
60   FXint invalid;
61 public:
62   PopupPrefs(FXComposite*p, UserMenu**ums, FXSelector lastid, FXObject*tgt=NULL, FXSelector sel=0);
63   long onInsertCustomItem( FXObject*o, FXSelector sel, void*p);
64   long onInsertSeparator(  FXObject*o, FXSelector sel, void*p);
65   enum {
66     ID_INSERT_CUSTOM=DualListForm::ID_LAST,
67     ID_INSERT_SEPARATOR,
68     ID_LAST
69   };
70 };
71 
72