mirror of https://gitlab.com/basile.b/dexed.git
fix #178 - possible to insert unamed object in DUB json
This commit is contained in:
parent
26b44a2f0e
commit
b671bfe40e
|
@ -8,7 +8,7 @@ uses
|
||||||
Classes, SysUtils, FileUtil, TreeFilterEdit, Forms, Controls, Graphics,
|
Classes, SysUtils, FileUtil, TreeFilterEdit, Forms, Controls, Graphics,
|
||||||
Dialogs, ExtCtrls, Menus, StdCtrls, Buttons, ComCtrls, jsonparser, fpjson,
|
Dialogs, ExtCtrls, Menus, StdCtrls, Buttons, ComCtrls, jsonparser, fpjson,
|
||||||
ce_widget, ce_common, ce_interfaces, ce_observer, ce_dubproject, ce_sharedres,
|
ce_widget, ce_common, ce_interfaces, ce_observer, ce_dubproject, ce_sharedres,
|
||||||
ce_dsgncontrols;
|
ce_dsgncontrols, ce_dialogs;
|
||||||
|
|
||||||
type
|
type
|
||||||
|
|
||||||
|
@ -220,8 +220,13 @@ begin
|
||||||
1: tpe := TJSONtype.jtObject;
|
1: tpe := TJSONtype.jtObject;
|
||||||
else tpe := TJSONtype.jtString;
|
else tpe := TJSONtype.jtString;
|
||||||
end;
|
end;
|
||||||
fEvent(fEdName.Text, tpe);
|
if (tpe in [jtObject, jtString]) and (fEdName.Text = '') then
|
||||||
Close;
|
dlgOkError('This property requires a name')
|
||||||
|
else
|
||||||
|
begin
|
||||||
|
fEvent(fEdName.Text, tpe);
|
||||||
|
Close;
|
||||||
|
end;
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
{$ENDREGION}
|
{$ENDREGION}
|
||||||
|
|
Loading…
Reference in New Issue