#include <vtkRenderer.h>
#include <vtkRenderWindow.h>
#include <vtkActorCollection.h>
+#include <vtkTimerLog.h>
// SALOME Includes
#include "SALOME_LifeCycleCORBA.hxx"
{
}
-
void
VisuGUI::
OnImportFromFile()
{
- VisuGUI_Timer aTimer;
- aTimer.Start();
-
if(MYDEBUG) MESSAGE("VisuGUI::OnImportFromFile()");
CheckLock(GetCStudy(GetAppStudy(this)));
SUIT_ResourceMgr* aResourceMgr = VISU::GetResourceMgr();
true);
if(aFileInfo.exists()) {
application()->putInfo( "Importing From File " + aFileInfo.filePath() + "...", -1 );
+ double initialTime = vtkTimerLog::GetCPUTime();
VISU::Result_var aResult;
bool anIsBuild = aResourceMgr->booleanValue("VISU", "full_med_loading", false);
tr("BUT_OK"));
}else{
UpdateObjBrowser(this);
- application()->putInfo(aFileInfo.filePath() + tr("INF_DONE") +
- " in " + aTimer.GetTime() + " seconds", -1 );
+ application()->putInfo(aFileInfo.filePath() + tr("INF_DONE") + " in " +
+ QString::number( vtkTimerLog::GetCPUTime() - initialTime ) +
+ " seconds", -1 );
}
}
}
int diffr_sys = RefToCurrentTMS->tms_stime - RefToInitialTMS->tms_stime;
gettimeofday(RefToCurrentTimeB,tz);
- Cumul_user += (double) diffr_user / CLK_TCK ;
- Cumul_sys += (double) diffr_sys / CLK_TCK ;
+ static long aCLK_TCK=sysconf(_SC_CLK_TCK);
+ Cumul_user += (double) diffr_user / aCLK_TCK ;
+ Cumul_sys += (double) diffr_sys / aCLK_TCK ;
#else
SYSTEMTIME st;
GetSystemTime(&st);