You've already forked lazarus-ccr
TvPlanit/FullDemo: Fix updating of the MonthView popup menu translation.
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@8295 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
@ -269,6 +269,7 @@ type
|
|||||||
|
|
||||||
{ Popup menu }
|
{ Popup menu }
|
||||||
procedure InitializeDefaultPopup;
|
procedure InitializeDefaultPopup;
|
||||||
|
procedure PopupDropDownEvent(Sender: TObject);
|
||||||
procedure PopupToday(Sender: TObject);
|
procedure PopupToday(Sender: TObject);
|
||||||
procedure PopupNextMonth(Sender: TObject);
|
procedure PopupNextMonth(Sender: TObject);
|
||||||
procedure PopupPrevMonth(Sender: TObject);
|
procedure PopupPrevMonth(Sender: TObject);
|
||||||
@ -521,6 +522,7 @@ begin
|
|||||||
Width := 300;
|
Width := 300;
|
||||||
|
|
||||||
FDefaultPopup := TPopupMenu.Create(Self);
|
FDefaultPopup := TPopupMenu.Create(Self);
|
||||||
|
FDefaultPopup.OnPopup := PopupDropDownEvent;
|
||||||
Self.PopupMenu := FDefaultPopup;
|
Self.PopupMenu := FDefaultPopup;
|
||||||
LoadLanguage;
|
LoadLanguage;
|
||||||
|
|
||||||
@ -1211,6 +1213,8 @@ procedure TVpMonthView.InitializeDefaultPopup;
|
|||||||
var
|
var
|
||||||
NewItem : TMenuItem;
|
NewItem : TMenuItem;
|
||||||
begin
|
begin
|
||||||
|
FDefaultPopup.Items.Clear;
|
||||||
|
|
||||||
if RSToday <> '' then begin
|
if RSToday <> '' then begin
|
||||||
NewItem := TMenuItem.Create(Self);
|
NewItem := TMenuItem.Create(Self);
|
||||||
NewItem.Caption := RSToday;
|
NewItem.Caption := RSToday;
|
||||||
@ -1254,7 +1258,11 @@ begin
|
|||||||
FDefaultPopup.Items.Add(NewItem);
|
FDefaultPopup.Items.Add(NewItem);
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
{=====}
|
|
||||||
|
procedure TVpMonthView.PopupDropDownEvent(Sender: TObject);
|
||||||
|
begin
|
||||||
|
InitializeDefaultPopup;
|
||||||
|
end;
|
||||||
|
|
||||||
procedure TVpMonthView.PopupToday(Sender: TObject);
|
procedure TVpMonthView.PopupToday(Sender: TObject);
|
||||||
begin
|
begin
|
||||||
|
Reference in New Issue
Block a user