EditorPreferences.h 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960
  1. //---------------------------------------------------------------------------
  2. #ifndef EditorPreferencesH
  3. #define EditorPreferencesH
  4. //---------------------------------------------------------------------------
  5. #include <Classes.hpp>
  6. #include <Controls.hpp>
  7. #include <StdCtrls.hpp>
  8. #include <Forms.hpp>
  9. #include "HistoryComboBox.hpp"
  10. //---------------------------------------------------------------------------
  11. #include <GUITools.h>
  12. //---------------------------------------------------------------------------
  13. class TEditorPreferencesDialog : public TForm
  14. {
  15. __published:
  16. TGroupBox *ExternalEditorGroup;
  17. TCheckBox *ExternalEditorTextCheck;
  18. TCheckBox *SDIExternalEditorCheck;
  19. TGroupBox *EditorGroup2;
  20. TRadioButton *EditorInternalButton;
  21. TRadioButton *EditorExternalButton;
  22. THistoryComboBox *ExternalEditorEdit;
  23. TButton *ExternalEditorBrowseButton;
  24. TGroupBox *MaskGroup;
  25. TLabel *MaskLabel;
  26. THistoryComboBox *MaskEdit;
  27. TButton *OkButton;
  28. TButton *CancelButton;
  29. TButton *HelpButton;
  30. TCheckBox *RememberCheck;
  31. TRadioButton *EditorOpenButton;
  32. TButton *DefaultButton;
  33. void __fastcall ExternalEditorEditExit(TObject *Sender);
  34. void __fastcall ExternalEditorBrowseButtonClick(TObject *Sender);
  35. void __fastcall HelpButtonClick(TObject *Sender);
  36. void __fastcall ControlChange(TObject *Sender);
  37. void __fastcall FormCloseQuery(TObject *Sender, bool &CanClose);
  38. void __fastcall MaskEditExit(TObject *Sender);
  39. void __fastcall FormShow(TObject *Sender);
  40. void __fastcall DefaultButtonClick(TObject *Sender);
  41. public:
  42. virtual __fastcall TEditorPreferencesDialog(TComponent * Owner);
  43. void __fastcall Init(TEditorPreferencesMode Mode, bool MayRemote);
  44. bool __fastcall Execute(TEditorData * Editor, bool & Remember);
  45. private:
  46. void __fastcall UpdateControls();
  47. TEditorData __fastcall GetExternalEditorDefaults();
  48. void __fastcall ExternalEditorOptionsAutodetect();
  49. bool FMayRemote;
  50. UnicodeString FSystemExternalEditor;
  51. TEditorData FExternalEditorDefaults;
  52. INTERFACE_HOOK;
  53. };
  54. //---------------------------------------------------------------------------
  55. #endif