<?xml version="1.0" encoding="utf-8" ?>
<?xml-stylesheet type="text/xsl" href="RSS_xslt_style.asp" version="1.0" ?>
<rss version="2.0" xmlns:WebWizForums="https://syndication.webwiz.net/rss_namespace/">
 <channel>
  <title>Codejock Developer Community : Adding a Toolbar to  a Dialog</title>
  <link>http://forum.codejock.com/</link>
  <description><![CDATA[This is an XML content feed of; Codejock Developer Community : Command Bars : Adding a Toolbar to  a Dialog]]></description>
  <copyright>Copyright (c) 2006-2013 Web Wiz Forums - All Rights Reserved.</copyright>
  <pubDate>Wed, 13 May 2026 17:32:06 +0000</pubDate>
  <lastBuildDate>Thu, 16 Sep 2004 09:00:16 +0000</lastBuildDate>
  <docs>http://blogs.law.harvard.edu/tech/rss</docs>
  <generator>Web Wiz Forums 12.04</generator>
  <ttl>360</ttl>
  <WebWizForums:feedURL>forum.codejock.com/RSS_post_feed.asp?TID=1179</WebWizForums:feedURL>
  <image>
   <title><![CDATA[Codejock Developer Community]]></title>
   <url>http://forum.codejock.com/forum_images/codejock-logo.gif</url>
   <link>http://forum.codejock.com/</link>
  </image>
  <item>
   <title><![CDATA[Adding a Toolbar to  a Dialog : class CRightToolBar : public CXTPToolBar{LRESULT...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=1179&amp;PID=3146&amp;title=adding-a-toolbar-to-a-dialog#3146</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=6851">Oleg</a><br /><strong>Subject:</strong> 1179<br /><strong>Posted:</strong> 16 September 2004 at 9:00am<br /><br /><P>class CRightToolBar : public CXTPToolBar<BR>{<BR>&nbsp;LRESULT OnSizeParent(WPARAM, LPARAM lParam);<BR>&nbsp;DECLARE_MESSAGE_MAP();<BR>};</P><P>BEGIN_MESSAGE_MAP(CRightToolBar, CXTPToolBar)<BR>&nbsp;ON_MESSAGE(WM_SIZEPARENT, OnSizeParent)<BR>END_MESSAGE_MAP()</P><P>LRESULT CRightToolBar::OnSizeParent(WPARAM, LPARAM lParam)<BR>{<BR>&nbsp;AFX_SIZEPARENTPARAMS* lpLayout = (AFX_SIZEPARENTPARAMS*)lParam;</P><P>&nbsp;if (GetStyle() &amp; WS_VISIBLE)<BR>&nbsp;{<BR>&nbsp;&nbsp;m_barPosition = xtpBarRight;<BR>&nbsp;&nbsp;<BR>&nbsp;&nbsp;// align the control bar<BR>&nbsp;&nbsp;CRect rect;<BR>&nbsp;&nbsp;rect.CopyRect(&amp;lpLayout-&gt;rect);</P><P>&nbsp;&nbsp;CSize sizeAvail = rect.Size();&nbsp;</P><P>&nbsp;&nbsp;// get maximum requested size<BR>&nbsp;&nbsp;DWORD dwMode = LM_VERTDOCK|LM_COMMIT;<BR>&nbsp;&nbsp;if (GetFlags() &amp; xtpFlagStretched) dwMode |= LM_STRETCH; <BR>&nbsp;&nbsp;if (GetFlags() &amp; xtpFlagHideWrap) dwMode |= LM_HIDEWRAP;</P><P>&nbsp;&nbsp;if (lpLayout-&gt;hDWP == NULL) dwMode &amp;= ~LM_COMMIT;</P><P>&nbsp;&nbsp;CSize size = CalcDockingLayout(32000, dwMode);</P><P>&nbsp;&nbsp;size.cx = min(size.cx, sizeAvail.cx);<BR>&nbsp;&nbsp;size.cy = min(size.cy, sizeAvail.cy);</P><P>&nbsp;&nbsp;lpLayout-&gt;sizeTotal.cy += size.cy;<BR>&nbsp;&nbsp;lpLayout-&gt;sizeTotal.cx = max(lpLayout-&gt;sizeTotal.cx, size.cx);<BR>&nbsp;&nbsp;lpLayout-&gt;rect.right -= size.cx;</P><P>&nbsp;&nbsp;rect.left = rect.right - size.cx;<BR>&nbsp;&nbsp;rect.bottom = rect.top + size.cy;</P><P>&nbsp;&nbsp;// only resize the window if doing layout and not just rect query<BR>&nbsp;&nbsp;if (lpLayout-&gt;hDWP != NULL)<BR>&nbsp;&nbsp;&nbsp;AfxRepositionWindow(lpLayout, m_hWnd, &amp;rect);<BR>&nbsp;&nbsp;<BR>&nbsp;}<BR>&nbsp;return 0;<BR>}</P>]]>
   </description>
   <pubDate>Thu, 16 Sep 2004 09:00:16 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=1179&amp;PID=3146&amp;title=adding-a-toolbar-to-a-dialog#3146</guid>
  </item> 
  <item>
   <title><![CDATA[Adding a Toolbar to  a Dialog : Hi! This time a simple question,...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=1179&amp;PID=3137&amp;title=adding-a-toolbar-to-a-dialog#3137</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=244">Wolfgang</a><br /><strong>Subject:</strong> 1179<br /><strong>Posted:</strong> 16 September 2004 at 3:32am<br /><br /><P>Hi!</P><P>This time a simple question, i want to add an CXTPToolbar to an Dialog, which is quite easy, but I need it on the right side of the dialog. How must&nbsp;I insert and initialize the CXTPDialog therefore?</P><P>Thanx in advance</P><P>Wolfgang</P>]]>
   </description>
   <pubDate>Thu, 16 Sep 2004 03:32:18 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=1179&amp;PID=3137&amp;title=adding-a-toolbar-to-a-dialog#3137</guid>
  </item> 
 </channel>
</rss>