mirror of
https://github.com/HeidiSQL/HeidiSQL.git
synced 2025-08-14 10:02:10 +08:00
Give side-by-side group boxes on text import dialog the same width
This commit is contained in:
@ -17,6 +17,7 @@ object loaddataform: Tloaddataform
|
||||
OnClose = FormClose
|
||||
OnCreate = FormCreate
|
||||
OnDestroy = FormDestroy
|
||||
OnResize = FormResize
|
||||
OnShow = FormShow
|
||||
DesignSize = (
|
||||
509
|
||||
|
@ -69,6 +69,7 @@ type
|
||||
procedure FormClose(Sender: TObject; var Action: TCloseAction);
|
||||
procedure chklistColumnsClick(Sender: TObject);
|
||||
procedure btnCheckAllClick(Sender: TObject);
|
||||
procedure FormResize(Sender: TObject);
|
||||
private
|
||||
{ Private declarations }
|
||||
Encoding: TEncoding;
|
||||
@ -134,6 +135,24 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure Tloaddataform.FormResize(Sender: TObject);
|
||||
var
|
||||
HalfWidth, RightBoxX: Integer;
|
||||
begin
|
||||
// Rethink width of side-by-side group boxes
|
||||
HalfWidth := (ClientWidth - 3 * grpFilename.Left) div 2;
|
||||
RightBoxX := HalfWidth + 2 * grpFilename.Left;
|
||||
grpOptions.Width := HalfWidth;
|
||||
grpDuplicates.Width := HalfWidth;
|
||||
grpParseMethod.Width := HalfWidth;
|
||||
grpChars.Width := HalfWidth;
|
||||
grpDestination.Width := HalfWidth;
|
||||
// Move right boxes to the right position
|
||||
grpChars.Left := RightBoxX;
|
||||
grpDestination.Left := RightBoxX;
|
||||
end;
|
||||
|
||||
|
||||
procedure Tloaddataform.FormShow(Sender: TObject);
|
||||
begin
|
||||
FConnection := MainForm.ActiveConnection;
|
||||
|
Reference in New Issue
Block a user