[GME-commit]
GMESRC/GME/Gme PannWinDlg.h,1.2,1.3 PannWinDlg.cpp,1.2,1.3
PanningWindow.h,1.1,1.2 PanningWindow.cpp,1.1,1.2
PannButton.h,1.2,1.3 PannButton.cpp,1.3,1.4
gme-commit at list.isis.vanderbilt.edu
gme-commit at list.isis.vanderbilt.edu
Thu May 6 13:49:50 CDT 2004
Update of /var/lib/gme/GMESRC/GME/Gme
In directory braindrain:/tmp/cvs-serv6309
Modified Files:
PannWinDlg.h PannWinDlg.cpp PanningWindow.h PanningWindow.cpp
PannButton.h PannButton.cpp
Log Message:
Panning window background color
CVS User: bogyom
Index: PannWinDlg.h
===================================================================
RCS file: /var/lib/gme/GMESRC/GME/Gme/PannWinDlg.h,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** PannWinDlg.h 5 May 2004 18:33:42 -0000 1.2
--- PannWinDlg.h 6 May 2004 17:49:48 -0000 1.3
***************
*** 18,22 ****
public:
CPannWinDlg(CWnd* pParent = NULL); // standard constructor
! void SetBitmapDC(CDC *bdc, CRect &ori, CRect &rect);
void SetViewRect(CRect &vrect);
BOOL OnInitDialog();
--- 18,22 ----
public:
CPannWinDlg(CWnd* pParent = NULL); // standard constructor
! void SetBitmapDC(CDC *bdc, CRect &ori, CRect &rect, COLORREF &bkgrnd);
void SetViewRect(CRect &vrect);
BOOL OnInitDialog();
Index: PannWinDlg.cpp
===================================================================
RCS file: /var/lib/gme/GMESRC/GME/Gme/PannWinDlg.cpp,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** PannWinDlg.cpp 5 May 2004 18:33:42 -0000 1.2
--- PannWinDlg.cpp 6 May 2004 17:49:48 -0000 1.3
***************
*** 39,45 ****
}
! void CPannWinDlg::SetBitmapDC(CDC *bdc, CRect &ori, CRect &rect)
{
! m_pvbutton.SetBitmapDC(bdc, ori, rect);
}
--- 39,45 ----
}
! void CPannWinDlg::SetBitmapDC(CDC *bdc, CRect &ori, CRect &rect, COLORREF &bkgrnd)
{
! m_pvbutton.SetBitmapDC(bdc, ori, rect, bkgrnd);
}
Index: PanningWindow.h
===================================================================
RCS file: /var/lib/gme/GMESRC/GME/Gme/PanningWindow.h,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** PanningWindow.h 25 Mar 2004 20:06:44 -0000 1.1
--- PanningWindow.h 6 May 2004 17:49:48 -0000 1.2
***************
*** 20,24 ****
void OnUpdateCmdUI(CFrameWnd* pTarget, BOOL bDisableIfNoHndler);
! void SetBitmapDC(CDC *bdc, CRect &ori, CRect &rect);
void SetViewRect(CRect vrect);
--- 20,24 ----
void OnUpdateCmdUI(CFrameWnd* pTarget, BOOL bDisableIfNoHndler);
! void SetBitmapDC(CDC *bdc, CRect &ori, CRect &rect, COLORREF &bkgrnd);
void SetViewRect(CRect vrect);
Index: PanningWindow.cpp
===================================================================
RCS file: /var/lib/gme/GMESRC/GME/Gme/PanningWindow.cpp,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** PanningWindow.cpp 25 Mar 2004 20:06:44 -0000 1.1
--- PanningWindow.cpp 6 May 2004 17:49:48 -0000 1.2
***************
*** 80,86 ****
! void CPanningWindow::SetBitmapDC(CDC *bdc, CRect &ori, CRect &rect)
{
! m_pannWinDlg.SetBitmapDC(bdc, ori, rect);
}
--- 80,86 ----
! void CPanningWindow::SetBitmapDC(CDC *bdc, CRect &ori, CRect &rect, COLORREF &bkgrnd)
{
! m_pannWinDlg.SetBitmapDC(bdc, ori, rect, bkgrnd);
}
Index: PannButton.h
===================================================================
RCS file: /var/lib/gme/GMESRC/GME/Gme/PannButton.h,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** PannButton.h 5 May 2004 18:33:34 -0000 1.2
--- PannButton.h 6 May 2004 17:49:48 -0000 1.3
***************
*** 17,26 ****
CPannButton();
bool Create(CWnd *parent);
! void SetBitmapDC(CDC *bdc, CRect &ori, CRect &rect);
void SetViewRect(CRect vrect);
private:
! HCURSOR m_arrowh;
! HCURSOR m_sizeallh;
bool m_inMove;
--- 17,27 ----
CPannButton();
bool Create(CWnd *parent);
! void SetBitmapDC(CDC *bdc, CRect &ori, CRect &rect, COLORREF &bkgrnd);
void SetViewRect(CRect vrect);
private:
! HCURSOR m_arrowh;
! HCURSOR m_sizeallh;
! COLORREF m_backgorund;
bool m_inMove;
Index: PannButton.cpp
===================================================================
RCS file: /var/lib/gme/GMESRC/GME/Gme/PannButton.cpp,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
*** PannButton.cpp 5 May 2004 18:33:34 -0000 1.3
--- PannButton.cpp 6 May 2004 17:49:48 -0000 1.4
***************
*** 60,65 ****
}
! void CPannButton::SetBitmapDC(CDC *bdc, CRect &orisize, CRect &actsize) // may be empty
{
if (m_bitmapDC)
delete m_bitmapDC;
--- 60,66 ----
}
! void CPannButton::SetBitmapDC(CDC *bdc, CRect &orisize, CRect &actsize, COLORREF &bkgrnd) // may be empty
{
+ TRACE("SetBitmapDC\n");
if (m_bitmapDC)
delete m_bitmapDC;
***************
*** 67,70 ****
--- 68,72 ----
m_bitmapSizeOri = orisize;
m_bitmapSizeStored = actsize;
+ m_backgorund = bkgrnd;
Invalidate();
UpdateWindow();
***************
*** 73,76 ****
--- 75,79 ----
void CPannButton::SetViewRect(CRect irect)
{
+ TRACE("SetViewRect\n");
// the method can be called even if the panning window is not visible
if (m_bitmapSizeOri.IsRectEmpty() || m_bitmapSizeStored.IsRectEmpty())
***************
*** 158,170 ****
BYTE b1 = GetBValue(dw1);
brush1.CreateSolidBrush(RGB(r1,g1,b1));
! if (!m_viewRectOnStored.IsRectEmpty() && !m_inMove)
{
! CRect vRect(0,0,0,0);
! viewRectToScreen(vRect);
! m_viewRectOnScreen = vRect;
! dc.FrameRect(&m_viewRectOnScreen, &brush1);
}
- else if (m_inMove)
- dc.FrameRect(&m_viewRectInMove, &brush1);
}
--- 161,178 ----
BYTE b1 = GetBValue(dw1);
brush1.CreateSolidBrush(RGB(r1,g1,b1));
! if (!m_viewRectOnStored.IsRectEmpty() && m_viewRectOnScreen != m_bitmapOnScreen &&
! !m_viewRectOnScreen.IsRectEmpty())
{
! TRACE("m_viewRectOnScreen: w:%d, h:%d, m_bitmapOnScreen: w:%d, h:%d\n", m_viewRectOnScreen.Width(), m_viewRectOnScreen.Height(), m_bitmapOnScreen.Width(), m_bitmapOnScreen.Height());
! if (!m_inMove)
! {
! CRect vRect(0,0,0,0);
! viewRectToScreen(vRect);
! m_viewRectOnScreen = vRect;
! dc.FrameRect(&m_viewRectOnScreen, &brush1);
! }
! else
! dc.FrameRect(&m_viewRectInMove, &brush1);
}
}
More information about the GME-commit
mailing list