Folder:AddItem new ::Dialogs Position

Folder:AddItem new ::Dialogs Position

Postby Jimmy » Sun Feb 12, 2023 6:11 am

hi,

when using AddItem of TFolder() / TFolderEx() the new ::Dialogs have different Position as 0,0 :?:
Image
it disappear when "resize" ::Dialogs

is there a Workaround without "resize" :?:
greeting,
Jimmy
User avatar
Jimmy
 
Posts: 1732
Joined: Thu Sep 05, 2019 5:32 am
Location: Hamburg, Germany

Re: Folder:AddItem new ::Dialogs Position

Postby Antonio Linares » Mon Feb 13, 2023 8:20 am

Dear Jimmy,

When Method AddItem() is called, the new dialog gets created at zero, zero:
Code: Select all  Expand view
  if Empty( cResName )
      DEFINE DIALOG oDlg OF Self STYLE WS_CHILD ;
         FROM 0, 0 TO oThis:nHeight - oThis:nFdHeight - 5, oThis:nWidth - 6 PIXEL
   else
      DEFINE DIALOG oDlg OF Self STYLE WS_CHILD ;
         FROM 0, 0 TO oThis:nHeight - oThis:nFdHeight - 5, oThis:nWidth - 6 PIXEL ;
         NAME cResName
   endif

then, from the ACTIVATE DIALOG we set the position:
Code: Select all  Expand view
  ACTIVATE DIALOG oDlg NOWAIT ;
      ON INIT ( oDlg:Move( oThis:nFdHeight + 2, 3, oThis:nWidth - 6, oThis:nHeight - oThis:nFdHeight - 5 ) ) ;
      VALID .f.

So if you modify DATA nFdHeight you could change its position automatically
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42099
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: Folder:AddItem new ::Dialogs Position

Postby Jimmy » Tue Feb 14, 2023 4:24 am

hi Antonio,
Antonio Linares wrote:So if you modify DATA nFdHeight you could change its position automatically

ok, thx for Answer
greeting,
Jimmy
User avatar
Jimmy
 
Posts: 1732
Joined: Thu Sep 05, 2019 5:32 am
Location: Hamburg, Germany


Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: No registered users and 95 guests