JavaScript window for Sitemagic CMS

Windows - or pop up windows - are commonly used in web applications. Sitemagic CMS offers a more intiutive and Object Oriented way of working with windows in JavaScript using the SMWindow class. It also offers additional functionality.
The code below demonstrates how to open a window in the center of the screen and have it load a specific page.
var win = new SMWindow("UniqueId");
win.SetUrl("http://domain.com");
win.SetSize(640, 480);
win.SetCenterWindow(true);
win.Show();
Creating a new window with runtime rendered content is equally simple as the following example demonstrates:
var win = new SMWindow("UniqueId");
win.SetContent("Hello world, here goes my HTML code");
win.Show();