[Lazarus] ImageListEditor problem

Bart bartjunk64 at gmail.com
Thu Nov 10 18:35:35 CET 2011


Hi,

I have a mysterious problem with my Lazarus.
When I open the ImageListEditor the ImageListEditor opens with the Imagelist.
So far so good. The ImageListEditor shows up with the correct images
from the ImageList.

Now, whenI click on Add.. nothing happens (a TOpenPictureFileDialog is
supposed to open here).

This happened to me in r33269, when some days ago the same revision
worked perfectly.

I started Lazarus with a clean profile: no luck.
I rebuild Lazarus (clean + all): no luck.
I updated to r33459 and rebuilt (make clean all): no luck.

The bizarre part is that when I write a test program invoking the
ImageListEditor:

procedure TForm1.Button1Click(Sender: TObject);
var
  ImageListEditorDlg: TImageListEditorDlg;
begin
    ImageListEditorDlg := TImageListEditorDlg.Create(Application);
    try
      ImageListEditorDlg.LoadFromImageList(ImageList1);
      if ImageListEditorDlg.ShowModal = mrOk then
        ImageListEditorDlg.SaveToImageList;
    finally
      ImageListEditorDlg.Free;
    end;
end;

This works perfectly: the ImageListEditor shows with the correct
images, and clicking the Add button shows a PictureOpenDialog, and I
can add pictures and they are saved in teh ImageList.

I then added some debugstatements to

procedure TImageListEditorDlg.BtnAddClick(Sender: TObject);
var
  I: Integer;
begin
  if OpenDialog.Execute then
  begin
    TreeView.BeginUpdate;
[snip]

And this showed me that OpenDialog.Execute returned False.

I then copied the lazarus.exe to another computer (where I first
updated to same revision and rebuild), and the ImageListEditor (in the
copied lazarus.exe) worked just fine.
I also copied the original lazarus.exe (built there) from the other
computer to mine, and the problem persists.

Does anyone have an idea?

Bart




More information about the Lazarus mailing list