Print Page | Close Window

(11.2)Bug in "Codejock Command Bar Dialog Sample"

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Toolkit Pro
Forum Description: Topics Related to Codejock Toolkit Pro
URL: http://forum.codejock.com/forum_posts.asp?TID=8040
Printed Date: 21 December 2024 at 8:09pm
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: (11.2)Bug in "Codejock Command Bar Dialog Sample"
Posted By: tNgLoo
Subject: (11.2)Bug in "Codejock Command Bar Dialog Sample"
Date Posted: 17 September 2007 at 8:08am
Open this "Codejock Command Bar Dialog Sample", modify the dialog(IDD_DIALOGSAMPLE_DIALOG) resource, set "Minimize Box" property to "True", and compile and run.
When this dialog restored after minimized, the size of it (right side) changed!????
 



Replies:
Posted By: tNgLoo
Date Posted: 17 September 2007 at 8:57am
this bug is Based from CXTResizeDialog. Any dialog whose base class is CXTResizeDialog has same problem


Posted By: tNgLoo
Date Posted: 17 September 2007 at 9:37am
// my solution,  verified.
 
void CXTResize::GetMinMaxInfo(MINMAXINFO* pMMI)
{
 CXTPClientRect rcClient(m_pWnd);
 CXTPWindowRect rcWindow(m_pWnd);
// Add 1 line
 if(rcClient. ms-help://MS.VSCC.2003/MS.MSDNQTR.2003FEB.2052/vclib/html/_mfc_crect.3a3a.isrectempty.htm - IsRectEmpty ()) return;

 CSize szBorder(rcWindow.Width() - rcClient.Width(), rcWindow.Height() - rcClient.Height());

 if (m_szWindow != CSize(0, 0))
 {
  if (HasFlag(xtResizeNoHorizontal))
  {
   pMMI->ptMaxTrackSize.x = pMMI->ptMaxSize.x = m_szWindow.cx + szBorder.cx;
  }
  if (HasFlag(xtResizeNoVertical))
  {
   pMMI->ptMaxTrackSize.y = pMMI->ptMaxSize.y = m_szWindow.cy + szBorder.cy;
  }
 }
 if (m_szMin.cx != 0) pMMI->ptMinTrackSize.x = m_szMin.cx + szBorder.cx;
 if (m_szMin.cy != 0) pMMI->ptMinTrackSize.y = m_szMin.cy + szBorder.cy;
 if (m_szMax.cx != 0) pMMI->ptMaxTrackSize.x = m_szMax.cx + szBorder.cx;
 if (m_szMax.cy != 0) pMMI->ptMaxTrackSize.y = m_szMax.cy + szBorder.cy;
}



Posted By: terrym
Date Posted: 17 September 2007 at 12:29pm
Was this solution agreed by XTP that is what they are adding ? please


-------------
Thank you,
Terry Mancey

email terry@tmancey.ltd.uk | linkedin www.tmancey.ltd.uk | twitter @tmancey


Posted By: Oleg
Date Posted: 18 September 2007 at 1:53am

Yes, its good solution.

Thanks


-------------
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net