From: boca4711 <boc...@us...> - 2004-10-11 20:27:22
|
Update of /cvsroot/anyedit/AnyEditToolkit/GuiLib In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv22520/GuiLib Modified Files: GuiTabWnd.cpp GuiTabWnd.h Log Message: - Bugfix in GetActiveWnd. - Added GetTabRect. Gives rect of tab. Index: GuiTabWnd.h =================================================================== RCS file: /cvsroot/anyedit/AnyEditToolkit/GuiLib/GuiTabWnd.h,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** GuiTabWnd.h 11 Oct 2004 18:01:23 -0000 1.2 --- GuiTabWnd.h 11 Oct 2004 20:27:10 -0000 1.3 *************** *** 123,126 **** --- 123,127 ---- public: + CRect GetTabRect(int iTabNr); afx_msg void OnDestroy(); }; Index: GuiTabWnd.cpp =================================================================== RCS file: /cvsroot/anyedit/AnyEditToolkit/GuiLib/GuiTabWnd.cpp,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** GuiTabWnd.cpp 11 Oct 2004 18:01:23 -0000 1.3 --- GuiTabWnd.cpp 11 Oct 2004 20:27:10 -0000 1.4 *************** *** 525,532 **** } CWnd* CGuiTabWnd::GetActiveWnd () const { return m_Numtabs == -1 ? NULL : ! ((CGuiTab*) m_pArray [m_Numtabs])->pParent; } --- 525,533 ---- } + /// Get pointer of active window. CWnd* CGuiTabWnd::GetActiveWnd () const { return m_Numtabs == -1 ? NULL : ! ((CGuiTab*) m_pArray [m_iSelectTab])->pParent; } *************** *** 791,792 **** --- 792,806 ---- return TRUE; } + + /// Get rect of given tab number iTabNr. + CRect CGuiTabWnd::GetTabRect(int iTabNr) + { + CRect rect; + rect.SetRectEmpty(); + CGuiTab* ct=(CGuiTab*) m_pArray[iTabNr]; + if (ct!=NULL) + { + rect = ct->rect; + } + return rect; + } |