Constant Viewport refresh?

 From:  Michael Gibson
9039.4 In reply to 9039.3 
Hi Fubax, well I really don't recommend it but you could try inserting a some script like this inside of CommandBar.htm :

code:
		<script>
			var g_intervalID = null;

			function constantRedrawTimerFunc()
			{
				moi.ui.redrawViewports();
			}

			function startConstantRedraw()
			{
				if ( !g_intervalID )
					g_intervalID = window.setInterval( constantRedrawTimerFunc, 300 ); // call timerfunc every 300 ms.
			}

			function stopConstantRedraw()
			{
				if ( g_intervalID )
				{
					window.clearInterval( g_intervalID );
					g_intervalID = null;
				}
			}
		</script>


Then set up 2 shortcut keys with:

script: moi.ui.commandBar.startConstantRedraw();

script: moi.ui.commandBar.stopConstantRedraw();


The call to moi.ui.redrawViewports(); will not immediately draw the viewports, it will mark them as needing an update and they'll get redrawn when the message queue is next emptied.

- Michael