summaryrefslogtreecommitdiff
path: root/src/gui
diff options
context:
space:
mode:
authorgraemeg <graemeg@ae50a9b5-8222-0410-bf8d-8a13f76226bf>2008-03-25 06:48:36 +0000
committergraemeg <graemeg@ae50a9b5-8222-0410-bf8d-8a13f76226bf>2008-03-25 06:48:36 +0000
commitccdd9caa8827cc117be6fb94920f82f26971e69c (patch)
tree35c52723f6c245dee66bd77f67ad823475571e86 /src/gui
parent529d90f24a75126e3db72283cbaf9612be76b3fb (diff)
downloadfpGUI-ccdd9caa8827cc117be6fb94920f82f26971e69c.tar.xz
* Minor changes to menu and About fpGUI dialog.
Diffstat (limited to 'src/gui')
-rw-r--r--src/gui/gui_menu.pas10
-rw-r--r--src/gui/messagedialog.inc4
2 files changed, 8 insertions, 6 deletions
diff --git a/src/gui/gui_menu.pas b/src/gui/gui_menu.pas
index c2f8dc01..5ae11e41 100644
--- a/src/gui/gui_menu.pas
+++ b/src/gui/gui_menu.pas
@@ -1134,7 +1134,7 @@ var
mi: TfpgMenuItem;
begin
if Assigned(FBeforeShow) then
- FBeforeShow(self);
+ BeforeShow(self);
// Collecting visible items
FItems.Count := 0;
@@ -1150,9 +1150,9 @@ begin
end;
// Measuring sizes
- h := 0;
- tw := 0;
- hkw := 0;
+ h := 0; // height
+ tw := 0; // text width
+ hkw := 0; // hotkey width
FSymbolWidth := 0;
for n := 1 to VisibleCount do
begin
@@ -1172,7 +1172,7 @@ begin
end;
if hkw > 0 then
- hkw := hkw + 5;
+ hkw := hkw + 10; // spacing between text and hotkey text
FHeight := FMargin*2 + h;
FWidth := (FMargin+FTextMargin)*2 + FSymbolWidth + tw + hkw;
diff --git a/src/gui/messagedialog.inc b/src/gui/messagedialog.inc
index c642415f..d364d96d 100644
--- a/src/gui/messagedialog.inc
+++ b/src/gui/messagedialog.inc
@@ -1416,7 +1416,6 @@ class procedure TfpgMessageDialog.AboutFPGui(const ATitle: string);
var
dlg: TfpgMessageDialog;
begin
-// writeln('** Implement TfpgMessageDialog.AboutFPGui');
dlg := TfpgMessageDialog.Create(nil);
try
dlg.FDialogType := mtAbout;
@@ -1424,6 +1423,9 @@ begin
dlg.WindowTitle := Format(rsAbout, [fpGUIName])
else
dlg.WindowTitle := ATitle;
+ dlg.Buttons := [mbOK];
+ dlg.DefaultButton := mbOK;
+ dlg.PrepareLayout;
dlg.ShowModal;
finally
dlg.Free;