public HtmlBlock()
{
// Setup initial conditions.
InitializeComponent();
HtmlElementId = string.Format("{0}_{1}", GetType().Name, Guid.NewGuid().ToString());
// Create update delay.
// NB: This is put on a delay (of zero, which causes it to be invoked asynchronously)
// because Google Chrome crashes otherwise. Too many calls, to quickly to the JavaScript engine.
updateDelay = new DelayedAction(0, UpdateDimensions);
// Wire up events.
Loaded += OnLoaded;
}
#endregion