[sword-svn] r196 - trunk/src/SwordReader_GUI
dtrotzjr at crosswire.org
dtrotzjr at crosswire.org
Tue Jan 6 06:21:28 MST 2009
Author: dtrotzjr
Date: 2009-01-06 06:21:28 -0700 (Tue, 06 Jan 2009)
New Revision: 196
Modified:
trunk/src/SwordReader_GUI/SRSubWindow.cpp
trunk/src/SwordReader_GUI/SRSubWindow.h
Log:
Fixed last night's commit that did not run.
Modified: trunk/src/SwordReader_GUI/SRSubWindow.cpp
===================================================================
--- trunk/src/SwordReader_GUI/SRSubWindow.cpp 2009-01-06 04:34:01 UTC (rev 195)
+++ trunk/src/SwordReader_GUI/SRSubWindow.cpp 2009-01-06 13:21:28 UTC (rev 196)
@@ -86,14 +86,17 @@
return TRUE;
}
-void SRSubWindow::MoveWindow(int x, int y, int nWidth, int nHeight, BOOL bRepaint)
-{
- MoveWindow(x,y,nWidth, nHeight, bRepaint);
- m_wndSub->MoveWindow(2,2,nWidth - 4, nHeight - 4,bRepaint);
-}
-
void SRSubWindow::MoveWindow(LPCRECT lpRect,BOOL bRepaint)
{
- INT x = lpRect->left, y = lpRect->top, nWidth = lpRect->right - lpRect->left, nHeight = lpRect->bottom - lpRect->top;
- MoveWindow(x,y,nWidth, nHeight, bRepaint);
+ RECT rectSub;
+ rectSub.top = 20;
+ rectSub.left = 2;
+ rectSub.bottom = lpRect->bottom - lpRect->top - 2;
+ if(rectSub.bottom < 0)
+ rectSub.bottom = 0;
+ rectSub.right = lpRect->right - lpRect->left - 4;
+ if(rectSub.right < 0)
+ rectSub.right = 0;
+ SRWnd::MoveWindow(lpRect,bRepaint);
+ m_wndSub->MoveWindow(&rectSub,bRepaint);
}
\ No newline at end of file
Modified: trunk/src/SwordReader_GUI/SRSubWindow.h
===================================================================
--- trunk/src/SwordReader_GUI/SRSubWindow.h 2009-01-06 04:34:01 UTC (rev 195)
+++ trunk/src/SwordReader_GUI/SRSubWindow.h 2009-01-06 13:21:28 UTC (rev 196)
@@ -12,7 +12,6 @@
BOOL Create(SRFramework::SRWnd *pParentWnd, RECT bounds);
BOOL OnPaint();
- void MoveWindow(int x, int y, int nWidth, int nHeight, BOOL bRepaint = TRUE);
void MoveWindow(LPCRECT lpRect,BOOL bRepaint = TRUE);
SRFramework::SRWnd *GetSubWnd() { return m_wndSub; }
More information about the sword-cvs
mailing list