[GME-commit] GMESRC/GME/Gme GMEApp.cpp,1.129,1.130 GMEApp.h,1.27,1.28 GMEView.cpp,1.166,1.167

gme-commit at list.isis.vanderbilt.edu gme-commit at list.isis.vanderbilt.edu
Tue Jun 21 20:47:56 CDT 2005


Update of /project/gme-repository/GMESRC/GME/Gme
In directory escher:/tmp/cvs-serv9354

Modified Files:
	GMEApp.cpp GMEApp.h GMEView.cpp 
Log Message:
Default Zoom Value setting introduced.


CVS User: Zoltan Molnar, ISIS (zolmol)

Index: GMEApp.h
===================================================================
RCS file: /project/gme-repository/GMESRC/GME/Gme/GMEApp.h,v
retrieving revision 1.27
retrieving revision 1.28
diff -C2 -d -r1.27 -r1.28
*** GMEApp.h	15 Apr 2005 18:24:10 -0000	1.27
--- GMEApp.h	21 Jun 2005 19:47:54 -0000	1.28
***************
*** 76,79 ****
--- 76,80 ----
  	CString autosaveDir;
  	int  autosaveFreq;
+ 	CString defZoomLev;
  
  public:
***************
*** 91,94 ****
--- 92,96 ----
  
  	void Autosave();
+ 	CString getDefZoomLev() { return defZoomLev; }
  
  	// Both empty: reset on close, only one empty: no change to that name.

Index: GMEView.cpp
===================================================================
RCS file: /project/gme-repository/GMESRC/GME/Gme/GMEView.cpp,v
retrieving revision 1.166
retrieving revision 1.167
diff -C2 -d -r1.166 -r1.167
*** GMEView.cpp	17 Jun 2005 03:36:01 -0000	1.166
--- GMEView.cpp	21 Jun 2005 19:47:54 -0000	1.167
***************
*** 797,800 ****
--- 797,803 ----
  //	zoomIdx = GME_ZOOM_LEVEL_MED;
  	m_zoomVal = ZOOM_NO;
+ 	int l = _stscanf( (LPCTSTR) theApp.getDefZoomLev(), _T("%d"), &zv);
+ 	if( l == 1 && zv && zv >= ZOOM_MIN && zv <= ZOOM_MAX) // do not accept ZOOM_WIDTH,ZOOM_HEIGHT,ZOOM_ALL for now as ZoomValue
+ 		m_zoomVal = zv;
  	// sets the combo too 
  	frame->propBar.SetZoomVal(m_zoomVal);

Index: GMEApp.cpp
===================================================================
RCS file: /project/gme-repository/GMESRC/GME/Gme/GMEApp.cpp,v
retrieving revision 1.129
retrieving revision 1.130
diff -C2 -d -r1.129 -r1.130
*** GMEApp.cpp	6 May 2005 23:47:12 -0000	1.129
--- GMEApp.cpp	21 Jun 2005 19:47:54 -0000	1.130
***************
*** 115,118 ****
--- 115,119 ----
  	multipleView = false;
  	labelAvoidance = false;
+ 	defZoomLev = "100";
  	// TODO: add construction code here,
  	set_terminate(EmergencyTerminate);
***************
*** 1238,1241 ****
--- 1239,1248 ----
  		COMTHROW( registrar->get_LabelAvoidance(REGACCESS_USER, &labelavoidance) );
  		labelAvoidance = (labelavoidance != VARIANT_FALSE);
+ 
+ 		// Default Zoom Level
+ 		CComBSTR bstr_zl;
+ 		COMTHROW( registrar->GetDefZoomLevel( REGACCESS_USER, &bstr_zl));
+ 		if( bstr_zl)
+ 			CopyTo( bstr_zl, defZoomLev);
  	}
  	MSGCATCH("Error while trying to get program settings",;);



More information about the GME-commit mailing list