[GME-commit]
GMESRC/GME/Gme GMESearch.cpp,1.6,1.7 GMESearch.h,1.4,1.5
GME.rc,1.149,1.150
gme-commit at list.isis.vanderbilt.edu
gme-commit at list.isis.vanderbilt.edu
Fri Mar 17 15:55:24 CST 2006
Update of /project/gme-repository/GMESRC/GME/Gme
In directory escher:/tmp/cvs-serv25945
Modified Files:
GMESearch.cpp GMESearch.h GME.rc
Log Message:
Trying to pinpoint the misterious Search Box crash.
OnSizing prevents search box getting to small.
Window enabled to resize, thus search results can be reviewed easier.
CVS User: Zoltan Molnar, ISIS (zolmol)
Index: GMESearch.h
===================================================================
RCS file: /project/gme-repository/GMESRC/GME/Gme/GMESearch.h,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -d -r1.4 -r1.5
*** GMESearch.h 7 Dec 2002 02:25:00 -0000 1.4
--- GMESearch.h 17 Mar 2006 15:55:22 -0000 1.5
***************
*** 47,50 ****
--- 47,51 ----
afx_msg void OnWantToBeClosedSearchctrl();
afx_msg int OnCreate(LPCREATESTRUCT lpCreateStruct);
+ afx_msg void OnSizing(UINT fwSide, LPRECT pRect);
afx_msg void OnSize(UINT nType, int cx, int cy);
DECLARE_EVENTSINK_MAP()
Index: GMESearch.cpp
===================================================================
RCS file: /project/gme-repository/GMESRC/GME/Gme/GMESearch.cpp,v
retrieving revision 1.6
retrieving revision 1.7
diff -C2 -d -r1.6 -r1.7
*** GMESearch.cpp 17 Dec 2003 13:45:02 -0000 1.6
--- GMESearch.cpp 17 Mar 2006 15:55:22 -0000 1.7
***************
*** 47,50 ****
--- 47,51 ----
ON_WM_CREATE()
ON_WM_SIZE()
+ ON_WM_SIZING()
//}}AFX_MSG_MAP
END_MESSAGE_MAP()
***************
*** 111,115 ****
}
! void CGMESearch::OnSize(UINT nType, int cx, int cy)
{
CDialog::OnSize(nType, cx, cy);
--- 112,117 ----
}
! // OnSizing implemented as well (see below)
! void CGMESearch::OnSize(UINT nType, int cx, int cy)
{
CDialog::OnSize(nType, cx, cy);
***************
*** 118,122 ****
CRect rc;
GetClientRect(rc);
! m_search.MoveWindow(rc);
}
}
--- 120,124 ----
CRect rc;
GetClientRect(rc);
! m_search.MoveWindow(rc);
}
}
***************
*** 138,142 ****
void CGMESearch::ShowObject(LPUNKNOWN mgaObject)
{
! if (CGMEDoc::theInstance) {
CGMEDoc::theInstance->ShowObject(mgaObject);
}
--- 140,144 ----
void CGMESearch::ShowObject(LPUNKNOWN mgaObject)
{
! if (CGMEDoc::theInstance && mgaObject) {
CGMEDoc::theInstance->ShowObject(mgaObject);
}
***************
*** 152,154 ****
--- 154,167 ----
CGMEObjectInspector::theInstance->SetObjects(ccpSelectedObjects);
}
+ }
+
+ // OnSize implemented as well (see above)
+ void CGMESearch::OnSizing(UINT fwSide, LPRECT pRect)
+ {
+ static const int desiredX = 370, desiredY = 400;
+ // let's prevent window shrink by imposing some limits
+ if( pRect->bottom - pRect->top < desiredY) pRect->bottom = pRect->top + desiredY;
+ if( pRect->right - pRect->left < desiredX) pRect->right = pRect->left + desiredX;
+
+ CDialog::OnSizing(fwSide, pRect);
}
Index: GME.rc
===================================================================
RCS file: /project/gme-repository/GMESRC/GME/Gme/GME.rc,v
retrieving revision 1.149
retrieving revision 1.150
diff -C2 -d -r1.149 -r1.150
*** GME.rc 16 Feb 2006 22:14:17 -0000 1.149
--- GME.rc 17 Mar 2006 15:55:22 -0000 1.150
***************
*** 579,583 ****
"6", ID_MODE_VISUALIZE, VIRTKEY, CONTROL, NOINVERT
"7", ID_MODE_SHORTCONNECT, VIRTKEY, CONTROL, NOINVERT
! "8", ID_MODE_SHORTDISCONNECT,VIRTKEY, CONTROL, NOINVERT
"F", ID_EDIT_SEARCH, VIRTKEY, CONTROL, NOINVERT
"L", ID_FILE_CLEARLOCKS, VIRTKEY, CONTROL, ALT, NOINVERT
--- 579,583 ----
"6", ID_MODE_VISUALIZE, VIRTKEY, CONTROL, NOINVERT
"7", ID_MODE_SHORTCONNECT, VIRTKEY, CONTROL, NOINVERT
! "8", ID_MODE_SHORTDISCONNECT, VIRTKEY, CONTROL, NOINVERT
"F", ID_EDIT_SEARCH, VIRTKEY, CONTROL, NOINVERT
"L", ID_FILE_CLEARLOCKS, VIRTKEY, CONTROL, ALT, NOINVERT
***************
*** 784,788 ****
END
! IDD_OBJECT_INSPECTOR_DIALOG DIALOG 0, 0, 157, 212
STYLE DS_SETFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
CAPTION "Dialog"
--- 784,788 ----
END
! IDD_OBJECT_INSPECTOR_DIALOG DIALOG 0, 0, 157, 212
STYLE DS_SETFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
CAPTION "Dialog"
***************
*** 794,804 ****
END
! IDD_SEARCH_DIALOG DIALOG 200, 100, 258, 235
! STYLE DS_SETFONT | DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
CAPTION "Search"
! FONT 8, "MS Sans Serif"
BEGIN
CONTROL "",IDC_SEARCHCTRL,"{E5FE98F1-B7AD-4ABE-89DB-87DDD9DB753E}",
! WS_TABSTOP,7,7,244,221
END
--- 794,804 ----
END
! IDD_SEARCH_DIALOG DIALOGEX 200, 100, 243, 236
! STYLE DS_SETFONT | WS_POPUP | WS_CAPTION | WS_SYSMENU | WS_THICKFRAME
CAPTION "Search"
! FONT 8, "MS Sans Serif", 0, 0, 0x0
BEGIN
CONTROL "",IDC_SEARCHCTRL,"{E5FE98F1-B7AD-4ABE-89DB-87DDD9DB753E}",
! WS_TABSTOP,0,0,242,236
END
***************
*** 1156,1162 ****
BEGIN
LEFTMARGIN, 7
! RIGHTMARGIN, 251
TOPMARGIN, 7
! BOTTOMMARGIN, 228
END
--- 1156,1162 ----
BEGIN
LEFTMARGIN, 7
! RIGHTMARGIN, 239
TOPMARGIN, 7
! BOTTOMMARGIN, 229
END
***************
*** 1254,1258 ****
BEGIN
IDC_SEARCHCTRL, 0x376, 20, 0
! 0x0000, 0x0000, 0x0000, 0x0001, 0x25d4, 0x0000, 0x251b, 0x0000, 0x0000,
0x0000,
0
--- 1254,1258 ----
BEGIN
IDC_SEARCHCTRL, 0x376, 20, 0
! 0x0000, 0x0000, 0x0000, 0x0001, 0x2584, 0x0000, 0x27b0, 0x0000, 0x0000,
0x0000,
0
More information about the GME-commit
mailing list