1
0
mirror of https://github.com/winscp/winscp.git synced 2026-10-24 02:28:55 +03:00
Files
winscp/source/forms/Custom.h
Martin Prikryl 74fdf539de Clang imposed changes that should be noop and have no effect on classic compiler (2nd after 92ba1e3f0 + preceding commits)
Mostly
– explicit static global variables
– const, sign and down casts safety
– same-named variables in nested scopes
– incorrectly identified uninitialized variables
– semicolon after function implementation
– unused variables, fields, arguments and macros
– exact include filename case
– field initialization order
– typename use
– struct vs class declarations
– incorrectly identified uninitialized variables
– refactoring to solve Clang internal compiler error when using new variable in __finally block

Source commit: 3da995ff5169eefcfe3b3b7cc0d019c660096c07
2025-06-24 16:32:34 +02:00

75 lines
2.8 KiB
C++

//----------------------------------------------------------------------------
#ifndef CustomH
#define CustomH
//----------------------------------------------------------------------------
#include <System.Classes.hpp>
#include <Vcl.Controls.hpp>
#include <Vcl.StdCtrls.hpp>
//----------------------------------------------------------------------------
#include <windows.h>
#include <GUITools.h>
//----------------------------------------------------------------------------
class TCustomDialog : public TForm
{
__published:
TButton * OKButton;
TButton * CancelButton;
TButton * HelpButton;
void __fastcall HelpButtonClick(TObject *Sender);
private:
int FPos;
int FPrePos;
int FIndent;
int FHorizontalMargin;
int FControlPadding;
short FCount;
TGroupBox * FGroupBox;
void __fastcall Changed();
int __fastcall GetMaxControlWidth(TControl * Control);
int __fastcall GetParentClientWidth();
void __fastcall AdjustHeight(TControl * Control);
void __fastcall SetUpComboBox(TCustomCombo * Combo, TStrings * Items, bool OneLine);
protected:
DYNAMIC void __fastcall DoShow();
virtual bool __fastcall CloseQuery();
virtual void __fastcall DoChange(bool & CanSubmit);
virtual void __fastcall DoValidate();
virtual void __fastcall DoHelp();
void __fastcall Change(TObject * Sender);
INTERFACE_HOOK
public:
__fastcall TCustomDialog(UnicodeString HelpKeyword);
void __fastcall StartGroup(const UnicodeString & Caption);
TLabel * __fastcall CreateLabel(UnicodeString Label);
TCheckBox * __fastcall CreateAndAddCheckBox(const UnicodeString & Caption);
void __fastcall AddEditLikeControl(TWinControl * Edit, TLabel * Label, bool OneLine = false);
void __fastcall AddEdit(TCustomEdit * Edit, TLabel * Label, bool OneLine = false);
void __fastcall AddComboBox(TCustomCombo * Combo, TLabel * Label, TStrings * Items = NULL, bool OneLine = false);
void __fastcall AddShortCutComboBox(TComboBox * Combo, TLabel * Label, const TShortCuts & ShortCuts);
void __fastcall AddButtonControl(TButtonControl * Control);
void AddButtonNextToEdit(TButton * Control, TWinControl * Edit);
void __fastcall AddImage(const UnicodeString & ImageName);
void __fastcall AddWinControl(TWinControl * Control);
void __fastcall AddText(TLabel * Label);
void __fastcall AddText(TStaticText * Label);
void __fastcall AddSeparator();
void __fastcall AddDialogButton(TButton * Button);
void __fastcall RemoveCancelButton();
void __fastcall ScaleButtonControl(TButtonControl * Control);
TWinControl * __fastcall GetDefaultParent();
__property int HorizontalMargin = { read = FHorizontalMargin };
bool __fastcall Execute();
};
//----------------------------------------------------------------------------
#endif