You've already forked lazarus-ccr
SpkToolbar: Simplification of RTL
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@8959 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
@ -2716,12 +2716,13 @@ end;
|
|||||||
|
|
||||||
procedure TSpkToolbar.SetBiDiMode(Value: TBiDiMode);
|
procedure TSpkToolbar.SetBiDiMode(Value: TBiDiMode);
|
||||||
begin
|
begin
|
||||||
if BiDiMode = Value then exit;
|
if BiDiMode <> Value then
|
||||||
inherited SetBiDiMode(Value);
|
begin
|
||||||
FTabs.IsRightToLeft := IsRightToLeft;
|
inherited SetBiDiMode(Value);
|
||||||
SetMetricsInvalid;
|
SetMetricsInvalid;
|
||||||
if not (FInternalUpdating or FUpdating) then
|
if not (FInternalUpdating or FUpdating) then
|
||||||
Repaint;
|
Repaint;
|
||||||
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
end.
|
end.
|
||||||
|
@ -31,7 +31,6 @@ type
|
|||||||
FDisabledLargeImages: TImageList;
|
FDisabledLargeImages: TImageList;
|
||||||
FImagesWidth: Integer;
|
FImagesWidth: Integer;
|
||||||
FLargeImagesWidth: Integer;
|
FLargeImagesWidth: Integer;
|
||||||
FIsRightToLeft: Boolean;
|
|
||||||
|
|
||||||
// *** Getters and setters ***
|
// *** Getters and setters ***
|
||||||
procedure SetToolbarDispatch(const Value: TSpkBaseToolbarDispatch);
|
procedure SetToolbarDispatch(const Value: TSpkBaseToolbarDispatch);
|
||||||
@ -43,7 +42,6 @@ type
|
|||||||
procedure SetDisabledLargeImages(const Value: TImageList);
|
procedure SetDisabledLargeImages(const Value: TImageList);
|
||||||
procedure SetImagesWidth(const Value: Integer);
|
procedure SetImagesWidth(const Value: Integer);
|
||||||
procedure SetLargeImagesWidth(const Value: Integer);
|
procedure SetLargeImagesWidth(const Value: Integer);
|
||||||
procedure SetIsRightToLeft(const Value: Boolean);
|
|
||||||
|
|
||||||
public
|
public
|
||||||
function AddLargeButton: TSpkLargeButton;
|
function AddLargeButton: TSpkLargeButton;
|
||||||
@ -64,7 +62,6 @@ type
|
|||||||
property DisabledLargeImages: TImageList read FDisabledLargeImages write SetDisabledLargeImages;
|
property DisabledLargeImages: TImageList read FDisabledLargeImages write SetDisabledLargeImages;
|
||||||
property ImagesWidth: Integer read FImagesWidth write SetImagesWidth;
|
property ImagesWidth: Integer read FImagesWidth write SetImagesWidth;
|
||||||
property LargeImagesWidth: Integer read FLargeImagesWidth write SetLargeImagesWidth;
|
property LargeImagesWidth: Integer read FLargeImagesWidth write SetLargeImagesWidth;
|
||||||
property IsRightToLeft: Boolean read FIsRightToLeft write SetIsRightToLeft;
|
|
||||||
end;
|
end;
|
||||||
|
|
||||||
implementation
|
implementation
|
||||||
@ -184,12 +181,6 @@ begin
|
|||||||
Items[i].ImagesWidth := Value;
|
Items[i].ImagesWidth := Value;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TSpkItems.SetIsRightToLeft(const Value: Boolean);
|
|
||||||
begin
|
|
||||||
if FIsRightToLeft = Value then exit;
|
|
||||||
FIsRightToLeft := Value;
|
|
||||||
end;
|
|
||||||
|
|
||||||
procedure TSpkItems.SetLargeImages(const Value: TImageList);
|
procedure TSpkItems.SetLargeImages(const Value: TImageList);
|
||||||
var
|
var
|
||||||
i: Integer;
|
i: Integer;
|
||||||
|
@ -146,8 +146,6 @@ type
|
|||||||
end;
|
end;
|
||||||
|
|
||||||
TSpkPanes = class(TSpkCollection)
|
TSpkPanes = class(TSpkCollection)
|
||||||
private
|
|
||||||
FIsRightToLeft: Boolean;
|
|
||||||
protected
|
protected
|
||||||
FToolbarDispatch: TSpkBaseToolbarDispatch;
|
FToolbarDispatch: TSpkBaseToolbarDispatch;
|
||||||
FAppearance: TSpkToolbarAppearance;
|
FAppearance: TSpkToolbarAppearance;
|
||||||
@ -168,7 +166,6 @@ type
|
|||||||
procedure SetDisabledLargeImages(const Value: TImageList);
|
procedure SetDisabledLargeImages(const Value: TImageList);
|
||||||
procedure SetImagesWidth(const Value: Integer);
|
procedure SetImagesWidth(const Value: Integer);
|
||||||
procedure SetLargeImagesWidth(const Value: Integer);
|
procedure SetLargeImagesWidth(const Value: Integer);
|
||||||
procedure SetIsRightToLeft(const Value: Boolean);
|
|
||||||
|
|
||||||
public
|
public
|
||||||
// *** Adding and inserting elements ***
|
// *** Adding and inserting elements ***
|
||||||
@ -187,7 +184,6 @@ type
|
|||||||
property LargeImages: TImageList read FLargeImages write SetLargeImages;
|
property LargeImages: TImageList read FLargeImages write SetLargeImages;
|
||||||
property DisabledLargeImages: TImageList read FDisabledLargeImages write SetDisabledLargeImages;
|
property DisabledLargeImages: TImageList read FDisabledLargeImages write SetDisabledLargeImages;
|
||||||
property ImagesWidth: Integer read FImagesWidth write SetImagesWidth;
|
property ImagesWidth: Integer read FImagesWidth write SetImagesWidth;
|
||||||
property IsRightToLeft: Boolean read FIsRightToLeft write SetIsRightToLeft;
|
|
||||||
property LargeImagesWidth: Integer read FLargeImagesWidth write SetLargeImagesWidth;
|
property LargeImagesWidth: Integer read FLargeImagesWidth write SetLargeImagesWidth;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
@ -1373,16 +1369,6 @@ begin
|
|||||||
Items[i].ImagesWidth := Value;
|
Items[i].ImagesWidth := Value;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TSpkPanes.SetIsRightToLeft(const Value: Boolean);
|
|
||||||
var
|
|
||||||
i: Integer;
|
|
||||||
begin
|
|
||||||
if FIsRightToLeft = Value then exit;
|
|
||||||
FIsRightToLeft := Value;
|
|
||||||
for i := 0 to Count-1 do
|
|
||||||
Items[i].Items.IsRightToLeft := Value;
|
|
||||||
end;
|
|
||||||
|
|
||||||
procedure TSpkPanes.SetLargeImages(const Value: TImageList);
|
procedure TSpkPanes.SetLargeImages(const Value: TImageList);
|
||||||
var
|
var
|
||||||
I: Integer;
|
I: Integer;
|
||||||
|
@ -151,7 +151,6 @@ type
|
|||||||
FDisabledLargeImages: TImageList;
|
FDisabledLargeImages: TImageList;
|
||||||
FImagesWidth: Integer;
|
FImagesWidth: Integer;
|
||||||
FLargeImagesWidth: Integer;
|
FLargeImagesWidth: Integer;
|
||||||
FIsRightToLeft: Boolean;
|
|
||||||
procedure SetToolbarDispatch(const Value: TSpkBaseToolbarDispatch);
|
procedure SetToolbarDispatch(const Value: TSpkBaseToolbarDispatch);
|
||||||
function GetItems(AIndex: integer): TSpkTab; reintroduce;
|
function GetItems(AIndex: integer): TSpkTab; reintroduce;
|
||||||
procedure SetAppearance(const Value: TSpkToolbarAppearance);
|
procedure SetAppearance(const Value: TSpkToolbarAppearance);
|
||||||
@ -160,7 +159,6 @@ type
|
|||||||
procedure SetLargeImages(const Value: TImageList);
|
procedure SetLargeImages(const Value: TImageList);
|
||||||
procedure SetDisabledLargeImages(const Value: TImageList);
|
procedure SetDisabledLargeImages(const Value: TImageList);
|
||||||
procedure SetImagesWidth(const Value: Integer);
|
procedure SetImagesWidth(const Value: Integer);
|
||||||
procedure SetIsRightToLeft(const Value: Boolean);
|
|
||||||
procedure SetLargeImagesWidth(const Value: Integer);
|
procedure SetLargeImagesWidth(const Value: Integer);
|
||||||
public
|
public
|
||||||
function Add: TSpkTab;
|
function Add: TSpkTab;
|
||||||
@ -177,7 +175,6 @@ type
|
|||||||
property DisabledLargeImages: TImageList read FDisabledLargeImages write SetDisabledLargeImages;
|
property DisabledLargeImages: TImageList read FDisabledLargeImages write SetDisabledLargeImages;
|
||||||
property ImagesWidth: Integer read FImagesWidth write SetImagesWidth;
|
property ImagesWidth: Integer read FImagesWidth write SetImagesWidth;
|
||||||
property LargeImagesWidth: Integer read FLargeImagesWidth write SetLargeImagesWidth;
|
property LargeImagesWidth: Integer read FLargeImagesWidth write SetLargeImagesWidth;
|
||||||
property IsRightToLeft: boolean read FIsRightToLeft write SetIsRightToLeft;
|
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
|
||||||
@ -767,16 +764,6 @@ begin
|
|||||||
Items[i].ImagesWidth := Value;
|
Items[i].ImagesWidth := Value;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TSpkTabs.SetIsRightToLeft(const Value: Boolean);
|
|
||||||
var
|
|
||||||
i: Integer;
|
|
||||||
begin
|
|
||||||
if FIsRightToLeft = Value then exit;
|
|
||||||
FIsRightToLeft := Value;
|
|
||||||
for i := 0 to Count-1 do
|
|
||||||
Items[i].Panes.IsRightToLeft := Value;
|
|
||||||
end;
|
|
||||||
|
|
||||||
procedure TSpkTabs.SetLargeImages(const Value: TImageList);
|
procedure TSpkTabs.SetLargeImages(const Value: TImageList);
|
||||||
var
|
var
|
||||||
i: Integer;
|
i: Integer;
|
||||||
|
Reference in New Issue
Block a user