On Sunday 06 October 2013 09:08:12 Ivanko B wrote:
> So we have 2 order options available - oncreate-oncreated-onloaded and
> oncreate-onloaded-oncreated.
> How to know if load = true to choose correct one?
>
If load=true the order can be oncreate-onloaded-oncreated or 
oncreate-oncreated-onloaded. tform.create() normally calls 
tform.create(load=true).
"
constructor tcustommseform.create(aowner: tcomponent; load: boolean);

begin
 ficon:= tmaskedbitmap.create(false);
 ficon.onchange:= {$ifdef FPC}@{$endif}iconchanged;
 fwidgetrect.x:= 100;
 fwidgetrect.y:= 100;
 options:= defaultformoptions;
 docreate(aowner);
 aftercreate;
 registerhandlers;
 if load and not (csdesigning in componentstate) and
          (cs_ismodule in fmsecomponentstate) then begin
  loadmsemodule(self,tcustommseform);
 end;
 if not (acs_dooncreatecalled in factstate) then begin
  dooncreate;
 end;
 if not load then begin
//  autoreadstat;
  doafterload;
 end;
 if (fo_createmodal in foptions) and 
         (componentstate*[csdesigning,csdestroying,csloading] = []) and
                                                           showing then begin
  show(true);
 end;
end;

constructor tcustommseform.create(aowner: tcomponent);
begin
 create(aowner,not (cs_noload in fmsecomponentstate));
end;
"
Martin

------------------------------------------------------------------------------
October Webinars: Code for Performance
Free Intel webinars can help you accelerate application performance.
Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from 
the latest Intel processors and coprocessors. See abstracts and register >
http://pubads.g.doubleclick.net/gampad/clk?id=60134791&iu=/4140/ostg.clktrk
_______________________________________________
mseide-msegui-talk mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mseide-msegui-talk

Reply via email to