MCPcopy Create free account
hub / github.com/MaxBelkov/visualsyslog / LoadFormPosition

Function LoadFormPosition

sourcecommon/utils.cpp:669–680  ·  view source on GitHub ↗

---------------------------------------------------------------------------

Source from the content-addressed store, hash-verified

667extern char szPositionFile[];
668//---------------------------------------------------------------------------
669void LoadFormPosition(TMYIniFile * p, TForm * f)
670{
671 try
672 {
673 int l = p->ReadInteger(AnsiString(f->Name).c_str(), "Left", -10000);
674 int t = p->ReadInteger(AnsiString(f->Name).c_str(), "Top", -10000);
675 int w = p->ReadInteger(AnsiString(f->Name).c_str(), "Width", -10000);
676 int h = p->ReadInteger(AnsiString(f->Name).c_str(), "Height", -10000);
677 if( CorrectFormRect(l, t, w, h) ) f->SetBounds(l, t, w, h);
678 }
679 catch(...) {}
680}
681//---------------------------------------------------------------------------
682void SaveFormPosition(TMYIniFile * p, TForm * f)
683{

Callers 1

LoadPositionFunction · 0.85

Calls 2

CorrectFormRectFunction · 0.85
ReadIntegerMethod · 0.45

Tested by

no test coverage detected