ide: fix few issues in object inspector options page

git-svn-id: trunk@17370 -
This commit is contained in:
paul 2008-11-13 14:02:20 +00:00
parent aa6e9e64dd
commit 509b623bab

View File

@ -104,7 +104,7 @@ end;
procedure TOIOptionsFrame.ColorBoxChange(Sender: TObject); procedure TOIOptionsFrame.ColorBoxChange(Sender: TObject);
begin begin
if not FLoaded then if not FLoaded or (ColorsListBox.ItemIndex < 0) then
Exit; Exit;
ColorsListBox.Items.Objects[ColorsListBox.ItemIndex] := TObject(PtrInt(ColorBox.Selected)); ColorsListBox.Items.Objects[ColorsListBox.ItemIndex] := TObject(PtrInt(ColorBox.Selected));
end; end;
@ -112,7 +112,7 @@ end;
procedure TOIOptionsFrame.ColorsListBoxSelectionChange(Sender: TObject; procedure TOIOptionsFrame.ColorsListBoxSelectionChange(Sender: TObject;
User: boolean); User: boolean);
begin begin
if not FLoaded then if not (FLoaded and User) then
Exit; Exit;
ColorBox.Selected := ColorsListBox.Selected; ColorBox.Selected := ColorsListBox.Selected;
end; end;