Просто вариант. Да и размер вроде ...
code_25531.txt
------------ Дoбавленo в 14.59:
После оптимизации
Add(MainForm,7866967,140,147)
{
Width=616
Height=205
link(onCreate,2685136:doWork,[])
}
Add(ListBox,9247758,189,105)
{
Left=5
Top=15
Width=255
Height=140
Font=[MS Sans Serif,8,0,0,204]
Strings=#28:import org.bukkit.ChatColor;|35:import org.bukkit.block.BlockState;|34:import org.bukkit.command.Command;|42:import org.bukkit.command.CommandExecutor;|40:import org.bukkit.command.CommandSender;|32:import org.bukkit.entity.Player;|39:import org.bukkit.event.Event.Priority;|35:import org.bukkit.event.Event.Type;|46:import org.bukkit.event.player.PlayerListener;|42:import org.bukkit.plugin.java.JavaPlugin; |
}
Add(ListBox,4653911,259,161)
{
Left=315
Top=15
Width=270
Height=140
Font=[MS Sans Serif,8,0,0,204]
}
Add(InlineCode,2685136,203,161)
{
WorkPoints=#6:doWork|
EventPoints=#5:onRes|7:onClear|
DataPoints=#6:_Array|
Code=#15:unit HiAsmUnit;|0:|9:interface|0:|21:uses kol,Share,Debug;|0:|4:type|28: THiAsmClass = class(TDebug)|10: private|15: Item:TData;|17: eIndex:TData;|9: public|37: _Array, onRes, onClear: THI_Event;|49: procedure doWork(var _Data:TData; Index:Word);|5: end;|0:|14:implementation|29:procedure THiAsmClass.doWork;|15:var Arr:PArray;|23: k,Ind,i, l:integer;|13: s:string;|5:BEGIN|28: _hi_OnEvent(onClear,'');|29: Arr := ReadArray(_Array);|11: k := 1;|13: Ind := 0;|25: dtInteger(eIndex,Ind);|38: while Arr._Get(eIndex,Item) do begin|23: s:= toString(Item);|29: s:=COPY(s,8,Length(s)-8);|56: for i:=Length(s) downto 1 do If s[i]='.' then break;|19: s[i]:= Chr(32);|26: Insert(' import',s,i);|33: _hi_OnEvent(onRes,'from '+s);|15: inc(Ind,k);|26: dtInteger(eIndex,Ind);|6: end;|0:|4:END;|4:end.|
link(onRes,4653911:doAdd,[])
link(onClear,4653911:doClear,[])
link(_Array,9247758:Array,[])
}
72727 lines, 51284 bytes code, 2049 bytes data.