예제 #1
0
void CMainDlg::StatusAppendLine( char *lpszStatusString )
{
	WTL::CEdit status ;
	status.Attach( GetDlgItem( IDC_EDIT_STATUS ) ) ;
	status.AppendText( "\r\n" ) ;
	status.AppendText( lpszStatusString ) ;
	status.Detach( ) ;
}
예제 #2
0
void CMainDlg::StatusResult( unsigned __int64 u64Accum , DWORD dwCycles )
{
	WTL::CEdit res ;
	res.Attach( GetDlgItem( IDC_EDIT_RESULT ) ) ;
	res.SetReadOnly( FALSE ) ;
	res.SetSelAll( ) ;
	res.Clear( ) ;
	res.SetReadOnly( ) ;
	if ( dwCycles == 0 ){
		res.AppendText( "##.##" ) ;
	}else{
		float fRes = ( float )u64Accum / ( float )dwCycles ;
		char szRes[ 256 ] ;
		*szRes = NULL ;
		sprintf( szRes , "%.6f" , fRes / ( float )( ( 1 << 24 ) - 1 ) ) ;
		res.AppendText( szRes ) ;
	}
	res.Detach( ) ;
}
예제 #3
0
void CMainDlg::Status( char *lpszStatusString ) 
{
	WTL::CEdit status ;
	status.Attach( GetDlgItem( IDC_EDIT_STATUS ) ) ;
	status.SetReadOnly( FALSE ) ;
	status.SetSelAll( ) ;
	status.Clear( ) ;
	status.SetReadOnly( ) ;
	status.AppendText( lpszStatusString ) ;
	status.Detach( ) ;
}