~efargaspro/+junk/codeblocks-16.01-release

« back to all changes in this revision

Viewing changes to src/plugins/contrib/envvars/envvars_cfgdlg.h

  • Committer: damienlmoore at gmail
  • Date: 2016-02-02 02:43:22 UTC
  • Revision ID: damienlmoore@gmail.com-20160202024322-yql5qmtbwdyamdwd
Code::BlocksĀ 16.01

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*
 
2
 * This file is part of the Code::Blocks IDE and licensed under the GNU General Public License, version 3
 
3
 * http://www.gnu.org/licenses/gpl-3.0.html
 
4
 */
 
5
 
 
6
#ifndef ENVVARS_CFGDLG_H
 
7
#define ENVVARS_CFGDLG_H
 
8
 
 
9
#include <wx/event.h>
 
10
#include <wx/string.h>
 
11
#include <wx/window.h>
 
12
 
 
13
#include "configurationpanel.h"
 
14
 
 
15
class EnvVars;
 
16
class wxChoice;
 
17
 
 
18
// ----- ----- ----- ----- ----- ----- ----- ----- ----- ----- ----- -----
 
19
 
 
20
class EnvVarsConfigDlg : public cbConfigurationPanel
 
21
{
 
22
public:
 
23
  /// Ctor
 
24
           EnvVarsConfigDlg(wxWindow* parent);
 
25
  /// Dtor
 
26
  virtual ~EnvVarsConfigDlg()
 
27
  { };
 
28
 
 
29
  /// returns the title of the plugin configuration panel
 
30
  virtual wxString GetTitle() const
 
31
  { return _("Environment variables"); }
 
32
 
 
33
  /// returns the title of the plugin's bitmap to use for configuration dialog
 
34
  virtual wxString GetBitmapBaseName() const
 
35
  { return _T("envvars"); }
 
36
 
 
37
protected:
 
38
  /// Fires if the UI is being updated (wx event)
 
39
  void OnUpdateUI         (wxUpdateUIEvent& event);
 
40
 
 
41
private:
 
42
  /// Fires if the "apply" button is pressed inside C::B settings
 
43
  virtual void OnApply()
 
44
  { SaveSettings(); }
 
45
 
 
46
  /// Fires if the "cancel" button is pressed inside C::B settings
 
47
  virtual void OnCancel()
 
48
  { ; }
 
49
 
 
50
  /// Load all settings (envvar sets) from global C::B config
 
51
  void LoadSettings();
 
52
  /// Save all settings (envvar sets) to global C::B config
 
53
  void SaveSettings();
 
54
  /// Save settings (of specific active envvar set) to global C::B config
 
55
  void SaveSettingsActiveSet(wxString active_set);
 
56
 
 
57
  /// Fires when a (new) envvar set is selected
 
58
  void OnSetClick         (wxCommandEvent&  event);
 
59
  /// Fires when the button to create an envvar set is pressed
 
60
  void OnCreateSetClick   (wxCommandEvent&  event);
 
61
  /// Fires when the button to clone an envvar set is pressed
 
62
  void OnCloneSetClick    (wxCommandEvent&  event);
 
63
  /// Fires when the button to remove an envvar set is pressed
 
64
  void OnRemoveSetClick   (wxCommandEvent&  event);
 
65
 
 
66
  /// Fires when the checkbox to toggle an envvar is changed
 
67
  void OnToggleEnvVarClick(wxCommandEvent&  event);
 
68
  /// Fires when the button to add an envvar is pressed
 
69
  void OnAddEnvVarClick   (wxCommandEvent&  event);
 
70
  /// Fires when the button to edit an envvar is pressed
 
71
  void OnEditEnvVarClick  (wxCommandEvent&  event);
 
72
  /// Fires when the button to delete an envvar is pressed
 
73
  void OnDeleteEnvVarClick(wxCommandEvent&  event);
 
74
  /// Fires when the button to clear all envvars is pressed
 
75
  void OnClearEnvVarsClick(wxCommandEvent&  event);
 
76
  /// Fires when the button to set all envvars is pressed
 
77
  void OnSetEnvVarsClick  (wxCommandEvent&  event);
 
78
 
 
79
  /// Verifies that an envvar set is unique
 
80
  bool VerifySetUnique(const wxChoice* choSet, wxString set);
 
81
 
 
82
  DECLARE_EVENT_TABLE()
 
83
};
 
84
 
 
85
#endif // ENVVARS_CFGDLG_H