Fixed the GUI finally
This commit is contained in:
parent
58dded8116
commit
e2b4c2c8a3
17 changed files with 324 additions and 249 deletions
|
@ -1,10 +1,12 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<CONFIG>
|
||||
<ProjectOptions>
|
||||
<Version Value="11"/>
|
||||
<Version Value="12"/>
|
||||
<General>
|
||||
<Flags>
|
||||
<CompatibilityMode Value="True"/>
|
||||
</Flags>
|
||||
<SessionStorage Value="InProjectDir"/>
|
||||
<MainUnit Value="0"/>
|
||||
<Title Value="bandy2"/>
|
||||
<Scaled Value="True"/>
|
||||
<ResourceType Value="res"/>
|
||||
|
@ -14,8 +16,76 @@
|
|||
</XPManifest>
|
||||
<Icon Value="0"/>
|
||||
</General>
|
||||
<BuildModes Count="1">
|
||||
<BuildModes Count="3">
|
||||
<Item1 Name="Default" Default="True"/>
|
||||
<Item2 Name="Debug">
|
||||
<CompilerOptions>
|
||||
<Version Value="11"/>
|
||||
<Target>
|
||||
<Filename Value="bandy2"/>
|
||||
</Target>
|
||||
<SearchPaths>
|
||||
<IncludeFiles Value="$(ProjOutDir)"/>
|
||||
<UnitOutputDirectory Value="lib/$(TargetCPU)-$(TargetOS)"/>
|
||||
</SearchPaths>
|
||||
<Parsing>
|
||||
<SyntaxOptions>
|
||||
<IncludeAssertionCode Value="True"/>
|
||||
</SyntaxOptions>
|
||||
</Parsing>
|
||||
<CodeGeneration>
|
||||
<Checks>
|
||||
<IOChecks Value="True"/>
|
||||
<RangeChecks Value="True"/>
|
||||
<OverflowChecks Value="True"/>
|
||||
<StackChecks Value="True"/>
|
||||
</Checks>
|
||||
<VerifyObjMethodCallValidity Value="True"/>
|
||||
</CodeGeneration>
|
||||
<Linking>
|
||||
<Debugging>
|
||||
<DebugInfoType Value="dsDwarf3"/>
|
||||
<UseHeaptrc Value="True"/>
|
||||
<TrashVariables Value="True"/>
|
||||
<UseExternalDbgSyms Value="True"/>
|
||||
</Debugging>
|
||||
<Options>
|
||||
<Win32>
|
||||
<GraphicApplication Value="True"/>
|
||||
</Win32>
|
||||
</Options>
|
||||
</Linking>
|
||||
</CompilerOptions>
|
||||
</Item2>
|
||||
<Item3 Name="Release">
|
||||
<CompilerOptions>
|
||||
<Version Value="11"/>
|
||||
<Target>
|
||||
<Filename Value="bandy2"/>
|
||||
</Target>
|
||||
<SearchPaths>
|
||||
<IncludeFiles Value="$(ProjOutDir)"/>
|
||||
<UnitOutputDirectory Value="lib/$(TargetCPU)-$(TargetOS)"/>
|
||||
</SearchPaths>
|
||||
<CodeGeneration>
|
||||
<SmartLinkUnit Value="True"/>
|
||||
<Optimizations>
|
||||
<OptimizationLevel Value="3"/>
|
||||
</Optimizations>
|
||||
</CodeGeneration>
|
||||
<Linking>
|
||||
<Debugging>
|
||||
<GenerateDebugInfo Value="False"/>
|
||||
</Debugging>
|
||||
<LinkSmart Value="True"/>
|
||||
<Options>
|
||||
<Win32>
|
||||
<GraphicApplication Value="True"/>
|
||||
</Win32>
|
||||
</Options>
|
||||
</Linking>
|
||||
</CompilerOptions>
|
||||
</Item3>
|
||||
</BuildModes>
|
||||
<PublishOptions>
|
||||
<Version Value="2"/>
|
||||
|
@ -23,7 +93,6 @@
|
|||
</PublishOptions>
|
||||
<RunParams>
|
||||
<FormatVersion Value="2"/>
|
||||
<Modes Count="0"/>
|
||||
</RunParams>
|
||||
<RequiredPackages Count="1">
|
||||
<Item1>
|
||||
|
|
|
@ -1,9 +1,9 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<CONFIG>
|
||||
<ProjectSession>
|
||||
<Version Value="11"/>
|
||||
<BuildModes Active="Default"/>
|
||||
<Units Count="2">
|
||||
<Version Value="12"/>
|
||||
<BuildModes Active="Release"/>
|
||||
<Units Count="4">
|
||||
<Unit0>
|
||||
<Filename Value="bandy2.lpr"/>
|
||||
<IsPartOfProject Value="True"/>
|
||||
|
@ -11,7 +11,7 @@
|
|||
<WindowIndex Value="-1"/>
|
||||
<TopLine Value="-1"/>
|
||||
<CursorPos X="-1" Y="-1"/>
|
||||
<UsageCount Value="29"/>
|
||||
<UsageCount Value="36"/>
|
||||
</Unit0>
|
||||
<Unit1>
|
||||
<Filename Value="unit1.pas"/>
|
||||
|
@ -22,133 +22,160 @@
|
|||
<UnitName Value="Unit1"/>
|
||||
<IsVisibleTab Value="True"/>
|
||||
<TopLine Value="72"/>
|
||||
<CursorPos X="73" Y="75"/>
|
||||
<UsageCount Value="29"/>
|
||||
<CursorPos X="87" Y="101"/>
|
||||
<UsageCount Value="36"/>
|
||||
<Loaded Value="True"/>
|
||||
<LoadedDesigner Value="True"/>
|
||||
</Unit1>
|
||||
<Unit2>
|
||||
<Filename Value="../../../../tmp/fpc/lazarus/lcl/include/screen.inc"/>
|
||||
<EditorIndex Value="-1"/>
|
||||
<TopLine Value="667"/>
|
||||
<CursorPos Y="696"/>
|
||||
<UsageCount Value="10"/>
|
||||
</Unit2>
|
||||
<Unit3>
|
||||
<Filename Value="../../../../tmp/fpc/lazarus/lcl/customtimer.pas"/>
|
||||
<UnitName Value="CustomTimer"/>
|
||||
<EditorIndex Value="-1"/>
|
||||
<TopLine Value="163"/>
|
||||
<CursorPos Y="180"/>
|
||||
<UsageCount Value="10"/>
|
||||
</Unit3>
|
||||
</Units>
|
||||
<JumpHistory Count="29" HistoryIndex="28">
|
||||
<JumpHistory Count="30" HistoryIndex="29">
|
||||
<Position1>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="37" Column="26"/>
|
||||
<Caret Line="54" Column="13" TopLine="23"/>
|
||||
</Position1>
|
||||
<Position2>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="51" Column="13" TopLine="20"/>
|
||||
<Caret Line="55" Column="13" TopLine="24"/>
|
||||
</Position2>
|
||||
<Position3>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="53" Column="13" TopLine="22"/>
|
||||
<Caret Line="59" Column="38" TopLine="30"/>
|
||||
</Position3>
|
||||
<Position4>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="54" Column="13" TopLine="23"/>
|
||||
<Caret Line="60" Column="38" TopLine="31"/>
|
||||
</Position4>
|
||||
<Position5>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="55" Column="13" TopLine="24"/>
|
||||
<Caret Line="62" Column="38" TopLine="34"/>
|
||||
</Position5>
|
||||
<Position6>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="59" Column="38" TopLine="30"/>
|
||||
<Caret Line="63" Column="38" TopLine="35"/>
|
||||
</Position6>
|
||||
<Position7>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="60" Column="38" TopLine="31"/>
|
||||
<Caret Line="65" Column="38" TopLine="37"/>
|
||||
</Position7>
|
||||
<Position8>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="62" Column="38" TopLine="34"/>
|
||||
<Caret Line="80" Column="14" TopLine="44"/>
|
||||
</Position8>
|
||||
<Position9>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="63" Column="38" TopLine="35"/>
|
||||
<Caret Line="75" Column="14" TopLine="44"/>
|
||||
</Position9>
|
||||
<Position10>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="65" Column="38" TopLine="37"/>
|
||||
<Caret Column="13"/>
|
||||
</Position10>
|
||||
<Position11>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="80" Column="14" TopLine="44"/>
|
||||
<Caret Line="88" Column="21" TopLine="52"/>
|
||||
</Position11>
|
||||
<Position12>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="75" Column="14" TopLine="44"/>
|
||||
<Caret Line="81" Column="3" TopLine="55"/>
|
||||
</Position12>
|
||||
<Position13>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Column="13"/>
|
||||
<Caret Line="73" Column="21" TopLine="39"/>
|
||||
</Position13>
|
||||
<Position14>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="88" Column="21" TopLine="52"/>
|
||||
<Caret Line="77" Column="3" TopLine="48"/>
|
||||
</Position14>
|
||||
<Position15>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="81" Column="3" TopLine="55"/>
|
||||
<Caret Line="57" Column="34" TopLine="48"/>
|
||||
</Position15>
|
||||
<Position16>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="73" Column="21" TopLine="39"/>
|
||||
<Caret Line="88" Column="24" TopLine="52"/>
|
||||
</Position16>
|
||||
<Position17>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="77" Column="3" TopLine="48"/>
|
||||
<Caret Line="72" TopLine="39"/>
|
||||
</Position17>
|
||||
<Position18>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="57" Column="34" TopLine="48"/>
|
||||
<Caret Line="79" TopLine="43"/>
|
||||
</Position18>
|
||||
<Position19>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="88" Column="24" TopLine="52"/>
|
||||
<Caret Line="61" Column="27" TopLine="46"/>
|
||||
</Position19>
|
||||
<Position20>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="72" TopLine="39"/>
|
||||
<Caret Line="60" Column="27" TopLine="45"/>
|
||||
</Position20>
|
||||
<Position21>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="79" TopLine="43"/>
|
||||
<Caret Line="94" Column="74" TopLine="60"/>
|
||||
</Position21>
|
||||
<Position22>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="61" Column="27" TopLine="46"/>
|
||||
<Caret Line="93" Column="74" TopLine="59"/>
|
||||
</Position22>
|
||||
<Position23>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="60" Column="27" TopLine="45"/>
|
||||
<Caret Line="94" Column="74" TopLine="60"/>
|
||||
</Position23>
|
||||
<Position24>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="94" Column="74" TopLine="60"/>
|
||||
<Caret Line="101" Column="74" TopLine="67"/>
|
||||
</Position24>
|
||||
<Position25>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="93" Column="74" TopLine="59"/>
|
||||
<Caret Line="81" Column="94" TopLine="65"/>
|
||||
</Position25>
|
||||
<Position26>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="94" Column="74" TopLine="60"/>
|
||||
<Caret Line="83" Column="31" TopLine="66"/>
|
||||
</Position26>
|
||||
<Position27>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="101" Column="74" TopLine="67"/>
|
||||
<Caret Line="76" Column="8" TopLine="66"/>
|
||||
</Position27>
|
||||
<Position28>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="81" Column="94" TopLine="65"/>
|
||||
<Caret Line="79" Column="28" TopLine="66"/>
|
||||
</Position28>
|
||||
<Position29>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="83" Column="31" TopLine="66"/>
|
||||
<Caret Line="76" Column="8" TopLine="61"/>
|
||||
</Position29>
|
||||
<Position30>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="79" Column="38" TopLine="64"/>
|
||||
</Position30>
|
||||
</JumpHistory>
|
||||
<RunParams>
|
||||
<FormatVersion Value="2"/>
|
||||
<Modes Count="0" ActiveMode=""/>
|
||||
<Modes ActiveMode=""/>
|
||||
</RunParams>
|
||||
</ProjectSession>
|
||||
<Debugging>
|
||||
<Watches>
|
||||
<Item ClassAutoCast="True">
|
||||
<Expression Value="parse"/>
|
||||
<DisplayStyle Value="wdfString"/>
|
||||
</Item>
|
||||
</Watches>
|
||||
</Debugging>
|
||||
</CONFIG>
|
||||
|
|
|
@ -1,38 +1,38 @@
|
|||
object Form1: TForm1
|
||||
Left = 908
|
||||
Left = 474
|
||||
Height = 139
|
||||
Top = 408
|
||||
Width = 283
|
||||
Top = 463
|
||||
Width = 299
|
||||
Caption = 'Internet Traffic Monitor'
|
||||
ClientHeight = 139
|
||||
ClientWidth = 283
|
||||
ClientWidth = 299
|
||||
OnCreate = FormCreate
|
||||
LCLVersion = '2.0.12.0'
|
||||
LCLVersion = '2.2.5.0'
|
||||
object Label1: TLabel
|
||||
Left = 14
|
||||
Height = 18
|
||||
Height = 19
|
||||
Top = 23
|
||||
Width = 87
|
||||
Width = 113
|
||||
Caption = 'Today''s Usage'
|
||||
ParentColor = False
|
||||
end
|
||||
object Label2: TLabel
|
||||
Left = 120
|
||||
Left = 136
|
||||
Height = 1
|
||||
Top = 23
|
||||
Top = 24
|
||||
Width = 1
|
||||
ParentColor = False
|
||||
end
|
||||
object Label3: TLabel
|
||||
Left = 14
|
||||
Height = 18
|
||||
Height = 19
|
||||
Top = 48
|
||||
Width = 148
|
||||
Width = 189
|
||||
Caption = 'Computed Monthly Max'
|
||||
ParentColor = False
|
||||
end
|
||||
object Label4: TLabel
|
||||
Left = 176
|
||||
Left = 216
|
||||
Height = 1
|
||||
Top = 48
|
||||
Width = 1
|
||||
|
@ -40,23 +40,23 @@ object Form1: TForm1
|
|||
end
|
||||
object Label5: TLabel
|
||||
Left = 14
|
||||
Height = 18
|
||||
Height = 19
|
||||
Top = 71
|
||||
Width = 143
|
||||
Width = 182
|
||||
Caption = 'Current Monthly Usage'
|
||||
ParentColor = False
|
||||
end
|
||||
object Label6: TLabel
|
||||
Left = 176
|
||||
Left = 208
|
||||
Height = 1
|
||||
Top = 71
|
||||
Top = 72
|
||||
Width = 1
|
||||
ParentColor = False
|
||||
end
|
||||
object Button1: TButton
|
||||
Left = 169
|
||||
Left = 208
|
||||
Height = 25
|
||||
Top = 97
|
||||
Top = 104
|
||||
Width = 75
|
||||
Caption = 'Hide'
|
||||
OnClick = Button1Click
|
||||
|
@ -4372,7 +4372,7 @@ object Form1: TForm1
|
|||
Enabled = False
|
||||
Interval = 10000
|
||||
OnTimer = Timer1Timer
|
||||
Left = 50
|
||||
Top = 92
|
||||
Left = 56
|
||||
Top = 98
|
||||
end
|
||||
end
|
||||
|
|
|
@ -72,17 +72,18 @@ end;
|
|||
procedure TForm1.Timer1Timer(Sender: TObject);
|
||||
begin
|
||||
try
|
||||
webres := TFPCustomHTTPClient.SimpleGet('https://192.168.1.113/bnd.dat');
|
||||
webres := TFPCustomHTTPClient.SimpleGet('http://192.168.1.168/band/bnd.dat');
|
||||
parse := splitstring(webres,' ');
|
||||
vnstats.dom := parse[6];
|
||||
vnstats.cm := parse[8];
|
||||
vnstats.vnhourly := parse[10];
|
||||
vnstats.vnmonthly := parse[13];
|
||||
|
||||
vnstats.dom := parse[4];
|
||||
vnstats.cm := concat(parse[6],' GiB');
|
||||
vnstats.vnhourly := concat(parse[8],parse[9]);
|
||||
vnstats.vnmonthly := concat(parse[11],parse[12]);
|
||||
Label2.Caption := vnstats.vnhourly;
|
||||
Label6.Caption := vnstats.vnmonthly;
|
||||
Label4.Caption := vnstats.cm;
|
||||
Label7.Caption:= parse[11] ;
|
||||
Label8.Caption:= parse[14];
|
||||
//Label7.Caption:= parse[12] ;
|
||||
// Label8.Caption:= parse[15];
|
||||
Button1.Caption := 'Hide';
|
||||
except
|
||||
// Blah
|
||||
|
|
BIN
fpc/bandy2
Executable file
BIN
fpc/bandy2
Executable file
Binary file not shown.
|
@ -1,10 +1,12 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<CONFIG>
|
||||
<ProjectOptions>
|
||||
<Version Value="11"/>
|
||||
<Version Value="12"/>
|
||||
<General>
|
||||
<Flags>
|
||||
<CompatibilityMode Value="True"/>
|
||||
</Flags>
|
||||
<SessionStorage Value="InProjectDir"/>
|
||||
<MainUnit Value="0"/>
|
||||
<Title Value="bandy2"/>
|
||||
<Scaled Value="True"/>
|
||||
<ResourceType Value="res"/>
|
||||
|
@ -14,8 +16,76 @@
|
|||
</XPManifest>
|
||||
<Icon Value="0"/>
|
||||
</General>
|
||||
<BuildModes Count="1">
|
||||
<BuildModes Count="3">
|
||||
<Item1 Name="Default" Default="True"/>
|
||||
<Item2 Name="Debug">
|
||||
<CompilerOptions>
|
||||
<Version Value="11"/>
|
||||
<Target>
|
||||
<Filename Value="bandy2"/>
|
||||
</Target>
|
||||
<SearchPaths>
|
||||
<IncludeFiles Value="$(ProjOutDir)"/>
|
||||
<UnitOutputDirectory Value="lib/$(TargetCPU)-$(TargetOS)"/>
|
||||
</SearchPaths>
|
||||
<Parsing>
|
||||
<SyntaxOptions>
|
||||
<IncludeAssertionCode Value="True"/>
|
||||
</SyntaxOptions>
|
||||
</Parsing>
|
||||
<CodeGeneration>
|
||||
<Checks>
|
||||
<IOChecks Value="True"/>
|
||||
<RangeChecks Value="True"/>
|
||||
<OverflowChecks Value="True"/>
|
||||
<StackChecks Value="True"/>
|
||||
</Checks>
|
||||
<VerifyObjMethodCallValidity Value="True"/>
|
||||
</CodeGeneration>
|
||||
<Linking>
|
||||
<Debugging>
|
||||
<DebugInfoType Value="dsDwarf3"/>
|
||||
<UseHeaptrc Value="True"/>
|
||||
<TrashVariables Value="True"/>
|
||||
<UseExternalDbgSyms Value="True"/>
|
||||
</Debugging>
|
||||
<Options>
|
||||
<Win32>
|
||||
<GraphicApplication Value="True"/>
|
||||
</Win32>
|
||||
</Options>
|
||||
</Linking>
|
||||
</CompilerOptions>
|
||||
</Item2>
|
||||
<Item3 Name="Release">
|
||||
<CompilerOptions>
|
||||
<Version Value="11"/>
|
||||
<Target>
|
||||
<Filename Value="bandy2"/>
|
||||
</Target>
|
||||
<SearchPaths>
|
||||
<IncludeFiles Value="$(ProjOutDir)"/>
|
||||
<UnitOutputDirectory Value="lib/$(TargetCPU)-$(TargetOS)"/>
|
||||
</SearchPaths>
|
||||
<CodeGeneration>
|
||||
<SmartLinkUnit Value="True"/>
|
||||
<Optimizations>
|
||||
<OptimizationLevel Value="3"/>
|
||||
</Optimizations>
|
||||
</CodeGeneration>
|
||||
<Linking>
|
||||
<Debugging>
|
||||
<GenerateDebugInfo Value="False"/>
|
||||
</Debugging>
|
||||
<LinkSmart Value="True"/>
|
||||
<Options>
|
||||
<Win32>
|
||||
<GraphicApplication Value="True"/>
|
||||
</Win32>
|
||||
</Options>
|
||||
</Linking>
|
||||
</CompilerOptions>
|
||||
</Item3>
|
||||
</BuildModes>
|
||||
<PublishOptions>
|
||||
<Version Value="2"/>
|
||||
|
@ -23,7 +93,6 @@
|
|||
</PublishOptions>
|
||||
<RunParams>
|
||||
<FormatVersion Value="2"/>
|
||||
<Modes Count="0"/>
|
||||
</RunParams>
|
||||
<RequiredPackages Count="1">
|
||||
<Item1>
|
||||
|
|
164
fpc/bandy2.lps
164
fpc/bandy2.lps
|
@ -1,9 +1,9 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<CONFIG>
|
||||
<ProjectSession>
|
||||
<Version Value="11"/>
|
||||
<BuildModes Active="Default"/>
|
||||
<Units Count="2">
|
||||
<Version Value="12"/>
|
||||
<BuildModes Active="Release"/>
|
||||
<Units Count="4">
|
||||
<Unit0>
|
||||
<Filename Value="bandy2.lpr"/>
|
||||
<IsPartOfProject Value="True"/>
|
||||
|
@ -11,7 +11,7 @@
|
|||
<WindowIndex Value="-1"/>
|
||||
<TopLine Value="-1"/>
|
||||
<CursorPos X="-1" Y="-1"/>
|
||||
<UsageCount Value="31"/>
|
||||
<UsageCount Value="36"/>
|
||||
</Unit0>
|
||||
<Unit1>
|
||||
<Filename Value="unit1.pas"/>
|
||||
|
@ -21,134 +21,42 @@
|
|||
<ResourceBaseClass Value="Form"/>
|
||||
<UnitName Value="Unit1"/>
|
||||
<IsVisibleTab Value="True"/>
|
||||
<TopLine Value="70"/>
|
||||
<CursorPos X="28" Y="85"/>
|
||||
<UsageCount Value="31"/>
|
||||
<Loaded Value="True"/>
|
||||
<LoadedDesigner Value="True"/>
|
||||
<EditorIndex Value="-1"/>
|
||||
<TopLine Value="72"/>
|
||||
<CursorPos X="87" Y="101"/>
|
||||
<UsageCount Value="36"/>
|
||||
</Unit1>
|
||||
<Unit2>
|
||||
<Filename Value="../../../../tmp/fpc/lazarus/lcl/include/screen.inc"/>
|
||||
<EditorIndex Value="-1"/>
|
||||
<TopLine Value="667"/>
|
||||
<CursorPos Y="696"/>
|
||||
<UsageCount Value="10"/>
|
||||
</Unit2>
|
||||
<Unit3>
|
||||
<Filename Value="../../../../tmp/fpc/lazarus/lcl/customtimer.pas"/>
|
||||
<UnitName Value="CustomTimer"/>
|
||||
<EditorIndex Value="-1"/>
|
||||
<TopLine Value="163"/>
|
||||
<CursorPos Y="180"/>
|
||||
<UsageCount Value="10"/>
|
||||
</Unit3>
|
||||
</Units>
|
||||
<JumpHistory Count="29" HistoryIndex="28">
|
||||
<Position1>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="37" Column="26"/>
|
||||
</Position1>
|
||||
<Position2>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="51" Column="13" TopLine="20"/>
|
||||
</Position2>
|
||||
<Position3>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="53" Column="13" TopLine="22"/>
|
||||
</Position3>
|
||||
<Position4>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="54" Column="13" TopLine="23"/>
|
||||
</Position4>
|
||||
<Position5>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="55" Column="13" TopLine="24"/>
|
||||
</Position5>
|
||||
<Position6>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="59" Column="38" TopLine="30"/>
|
||||
</Position6>
|
||||
<Position7>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="60" Column="38" TopLine="31"/>
|
||||
</Position7>
|
||||
<Position8>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="62" Column="38" TopLine="34"/>
|
||||
</Position8>
|
||||
<Position9>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="63" Column="38" TopLine="35"/>
|
||||
</Position9>
|
||||
<Position10>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="65" Column="38" TopLine="37"/>
|
||||
</Position10>
|
||||
<Position11>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="80" Column="14" TopLine="44"/>
|
||||
</Position11>
|
||||
<Position12>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="75" Column="14" TopLine="44"/>
|
||||
</Position12>
|
||||
<Position13>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Column="13"/>
|
||||
</Position13>
|
||||
<Position14>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="88" Column="21" TopLine="52"/>
|
||||
</Position14>
|
||||
<Position15>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="81" Column="3" TopLine="55"/>
|
||||
</Position15>
|
||||
<Position16>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="73" Column="21" TopLine="39"/>
|
||||
</Position16>
|
||||
<Position17>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="77" Column="3" TopLine="48"/>
|
||||
</Position17>
|
||||
<Position18>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="57" Column="34" TopLine="48"/>
|
||||
</Position18>
|
||||
<Position19>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="88" Column="24" TopLine="52"/>
|
||||
</Position19>
|
||||
<Position20>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="72" TopLine="39"/>
|
||||
</Position20>
|
||||
<Position21>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="79" TopLine="43"/>
|
||||
</Position21>
|
||||
<Position22>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="61" Column="27" TopLine="46"/>
|
||||
</Position22>
|
||||
<Position23>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="60" Column="27" TopLine="45"/>
|
||||
</Position23>
|
||||
<Position24>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="94" Column="74" TopLine="60"/>
|
||||
</Position24>
|
||||
<Position25>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="93" Column="74" TopLine="59"/>
|
||||
</Position25>
|
||||
<Position26>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="94" Column="74" TopLine="60"/>
|
||||
</Position26>
|
||||
<Position27>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="101" Column="74" TopLine="67"/>
|
||||
</Position27>
|
||||
<Position28>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="81" Column="94" TopLine="65"/>
|
||||
</Position28>
|
||||
<Position29>
|
||||
<Filename Value="unit1.pas"/>
|
||||
<Caret Line="83" Column="31" TopLine="66"/>
|
||||
</Position29>
|
||||
</JumpHistory>
|
||||
<General>
|
||||
<ActiveWindowIndexAtStart Value="-1"/>
|
||||
</General>
|
||||
<JumpHistory HistoryIndex="-1"/>
|
||||
<RunParams>
|
||||
<FormatVersion Value="2"/>
|
||||
<Modes Count="0" ActiveMode=""/>
|
||||
<Modes ActiveMode=""/>
|
||||
</RunParams>
|
||||
</ProjectSession>
|
||||
<Debugging>
|
||||
<Watches>
|
||||
<Item ClassAutoCast="True">
|
||||
<Expression Value="parse"/>
|
||||
<DisplayStyle Value="wdfString"/>
|
||||
</Item>
|
||||
</Watches>
|
||||
</Debugging>
|
||||
</CONFIG>
|
||||
|
|
BIN
fpc/bandy2.res
BIN
fpc/bandy2.res
Binary file not shown.
|
@ -1,5 +1,5 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<CONFIG>
|
||||
<Compiler Value="/usr/bin/fpc" Date="1614890516"/>
|
||||
<Params Value=" -MObjFPC -Scghi -Cg -O1 -g -gl -l -vewnhibq -Fi/home/kake26/Code/FPC/bandy2/lib/x86_64-linux -Fu/usr/lib/lazarus/lcl/units/x86_64-linux/qt5 -Fu/usr/lib/lazarus/lcl/units/x86_64-linux -Fu/usr/lib/lazarus/components/lazutils/lib/x86_64-linux -Fu/usr/lib/lazarus/packager/units/x86_64-linux -Fu/home/kake26/Code/FPC/bandy2/ -FU/home/kake26/Code/FPC/bandy2/lib/x86_64-linux/ -FE/home/kake26/Code/FPC/bandy2/ -o/home/kake26/Code/FPC/bandy2/bandy2 -dLCL -dLCLqt5 bandy2.lpr"/>
|
||||
<Compiler Value="/usr/bin/fpc" Date="1621168742"/>
|
||||
<Params Value=" -MObjFPC -Scghi -CX -Cg -O3 -XX -l -vewnhibq -Fi/home/kake26/projects/pascal/bandmon/fpc/lib/x86_64-linux -Fu/home/kake26/tmp/fpc/lazarus/lcl/units/x86_64-linux/gtk2 -Fu/home/kake26/tmp/fpc/lazarus/lcl/units/x86_64-linux -Fu/home/kake26/tmp/fpc/lazarus/components/freetype/lib/x86_64-linux -Fu/home/kake26/tmp/fpc/lazarus/components/lazutils/lib/x86_64-linux -Fu/home/kake26/tmp/fpc/lazarus/packager/units/x86_64-linux -Fu/home/kake26/projects/pascal/bandmon/fpc/ -FU/home/kake26/projects/pascal/bandmon/fpc/lib/x86_64-linux/ -FE/home/kake26/projects/pascal/bandmon/fpc/ -o/home/kake26/projects/pascal/bandmon/fpc/bandy2 -dLCL -dLCLgtk2 bandy2.lpr"/>
|
||||
</CONFIG>
|
||||
|
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
|
@ -1,38 +1,38 @@
|
|||
object Form1: TForm1
|
||||
Left = 908
|
||||
Left = 474
|
||||
Height = 139
|
||||
Top = 408
|
||||
Width = 283
|
||||
Top = 463
|
||||
Width = 299
|
||||
Caption = 'Internet Traffic Monitor'
|
||||
ClientHeight = 139
|
||||
ClientWidth = 283
|
||||
ClientWidth = 299
|
||||
OnCreate = FormCreate
|
||||
LCLVersion = '2.0.12.0'
|
||||
LCLVersion = '2.2.5.0'
|
||||
object Label1: TLabel
|
||||
Left = 14
|
||||
Height = 18
|
||||
Height = 19
|
||||
Top = 23
|
||||
Width = 87
|
||||
Width = 113
|
||||
Caption = 'Today''s Usage'
|
||||
ParentColor = False
|
||||
end
|
||||
object Label2: TLabel
|
||||
Left = 120
|
||||
Left = 136
|
||||
Height = 1
|
||||
Top = 23
|
||||
Top = 24
|
||||
Width = 1
|
||||
ParentColor = False
|
||||
end
|
||||
object Label3: TLabel
|
||||
Left = 14
|
||||
Height = 18
|
||||
Height = 19
|
||||
Top = 48
|
||||
Width = 148
|
||||
Width = 189
|
||||
Caption = 'Computed Monthly Max'
|
||||
ParentColor = False
|
||||
end
|
||||
object Label4: TLabel
|
||||
Left = 176
|
||||
Left = 216
|
||||
Height = 1
|
||||
Top = 48
|
||||
Width = 1
|
||||
|
@ -40,23 +40,23 @@ object Form1: TForm1
|
|||
end
|
||||
object Label5: TLabel
|
||||
Left = 14
|
||||
Height = 18
|
||||
Height = 19
|
||||
Top = 71
|
||||
Width = 143
|
||||
Width = 182
|
||||
Caption = 'Current Monthly Usage'
|
||||
ParentColor = False
|
||||
end
|
||||
object Label6: TLabel
|
||||
Left = 176
|
||||
Left = 208
|
||||
Height = 1
|
||||
Top = 71
|
||||
Top = 72
|
||||
Width = 1
|
||||
ParentColor = False
|
||||
end
|
||||
object Button1: TButton
|
||||
Left = 169
|
||||
Left = 208
|
||||
Height = 25
|
||||
Top = 97
|
||||
Top = 104
|
||||
Width = 75
|
||||
Caption = 'Hide'
|
||||
OnClick = Button1Click
|
||||
|
@ -4372,7 +4372,7 @@ object Form1: TForm1
|
|||
Enabled = False
|
||||
Interval = 10000
|
||||
OnTimer = Timer1Timer
|
||||
Left = 50
|
||||
Top = 92
|
||||
Left = 56
|
||||
Top = 98
|
||||
end
|
||||
end
|
||||
|
|
Binary file not shown.
Binary file not shown.
|
@ -1,38 +1,38 @@
|
|||
object Form1: TForm1
|
||||
Left = 908
|
||||
Left = 474
|
||||
Height = 139
|
||||
Top = 408
|
||||
Width = 283
|
||||
Top = 463
|
||||
Width = 299
|
||||
Caption = 'Internet Traffic Monitor'
|
||||
ClientHeight = 139
|
||||
ClientWidth = 283
|
||||
ClientWidth = 299
|
||||
OnCreate = FormCreate
|
||||
LCLVersion = '2.0.12.0'
|
||||
LCLVersion = '2.2.5.0'
|
||||
object Label1: TLabel
|
||||
Left = 14
|
||||
Height = 18
|
||||
Height = 19
|
||||
Top = 23
|
||||
Width = 87
|
||||
Width = 113
|
||||
Caption = 'Today''s Usage'
|
||||
ParentColor = False
|
||||
end
|
||||
object Label2: TLabel
|
||||
Left = 120
|
||||
Left = 136
|
||||
Height = 1
|
||||
Top = 23
|
||||
Top = 24
|
||||
Width = 1
|
||||
ParentColor = False
|
||||
end
|
||||
object Label3: TLabel
|
||||
Left = 14
|
||||
Height = 18
|
||||
Height = 19
|
||||
Top = 48
|
||||
Width = 148
|
||||
Width = 189
|
||||
Caption = 'Computed Monthly Max'
|
||||
ParentColor = False
|
||||
end
|
||||
object Label4: TLabel
|
||||
Left = 176
|
||||
Left = 216
|
||||
Height = 1
|
||||
Top = 48
|
||||
Width = 1
|
||||
|
@ -40,23 +40,23 @@ object Form1: TForm1
|
|||
end
|
||||
object Label5: TLabel
|
||||
Left = 14
|
||||
Height = 18
|
||||
Height = 19
|
||||
Top = 71
|
||||
Width = 143
|
||||
Width = 182
|
||||
Caption = 'Current Monthly Usage'
|
||||
ParentColor = False
|
||||
end
|
||||
object Label6: TLabel
|
||||
Left = 176
|
||||
Left = 208
|
||||
Height = 1
|
||||
Top = 71
|
||||
Top = 72
|
||||
Width = 1
|
||||
ParentColor = False
|
||||
end
|
||||
object Button1: TButton
|
||||
Left = 169
|
||||
Left = 208
|
||||
Height = 25
|
||||
Top = 97
|
||||
Top = 104
|
||||
Width = 75
|
||||
Caption = 'Hide'
|
||||
OnClick = Button1Click
|
||||
|
@ -4372,7 +4372,7 @@ object Form1: TForm1
|
|||
Enabled = False
|
||||
Interval = 10000
|
||||
OnTimer = Timer1Timer
|
||||
Left = 50
|
||||
Top = 92
|
||||
Left = 56
|
||||
Top = 98
|
||||
end
|
||||
end
|
||||
|
|
|
@ -72,17 +72,18 @@ end;
|
|||
procedure TForm1.Timer1Timer(Sender: TObject);
|
||||
begin
|
||||
try
|
||||
webres := TFPCustomHTTPClient.SimpleGet('https://192.168.1.113/bnd.dat');
|
||||
webres := TFPCustomHTTPClient.SimpleGet('http://192.168.1.168/band/bnd.dat');
|
||||
parse := splitstring(webres,' ');
|
||||
vnstats.dom := parse[7];
|
||||
vnstats.cm := parse[9];
|
||||
vnstats.vnhourly := parse[11];
|
||||
vnstats.vnmonthly := parse[14];
|
||||
|
||||
vnstats.dom := parse[4];
|
||||
vnstats.cm := concat(parse[6],' GiB');
|
||||
vnstats.vnhourly := concat(parse[8],' ',parse[9]);
|
||||
vnstats.vnmonthly := concat(parse[11],' ', parse[12]);
|
||||
Label2.Caption := vnstats.vnhourly;
|
||||
Label6.Caption := vnstats.vnmonthly;
|
||||
Label4.Caption := vnstats.cm;
|
||||
Label7.Caption:= parse[12] ;
|
||||
Label8.Caption:= parse[15];
|
||||
//Label7.Caption:= parse[12] ;
|
||||
// Label8.Caption:= parse[15];
|
||||
Button1.Caption := 'Hide';
|
||||
except
|
||||
// Blah
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue