Properties that can be set before loading (defaults in asterisks):
- Desk.installDir (*'/tux-desk'*, anything): Should point to the installation directory of Tux Desk relative to the root of the site. For example, for 'http://www.mysite.com/myblog/tux-desk', this should be set to '/myblog/tux-desk'.
- Desk.debugMode = (true | *false*): If set to true, alerts will be shown when errors occur.
- Desk.widgetDisplay = (*''* | 'none'): The display property of new widgets; if set to 'none', new widgets will not be displayed.
- Desk.showLoadingMessage = (*true* | false): If set to true, a loading message will be displayed when new widgets are loading.
- Desk.preloadImages = (*true* | false): If set to true, all of the images upon which Tux Desk relies will be pre-loaded into the browser's memory. This ensures that the interface will be drawn more responsively, and the user will not have to wait for images to appear in visual elements.
- Desk.fadedBackground = (true | *false*): If set to true, widgets will be displayed on a faded/dimmed background (like Dashboard on Mac OS X).
Methods that can be used:
- Desk.makeControlPanel(-array:QuickWidgets-): Creates a button in the top-left of the website to open a small control panel. This is highly recommended. QuickWidgets is an array containing a list of widgets (created by you) that users can add with one click. View source for this page to see an example of the QuickWidgets option.
- Desk.setSitePref(-string:widgetURL-, -string:prefName-, -string:prefValue-): Allows you to set different default preferences for widgets on your site. Note that, while this setting overrides the widgets' default preferences, user-saved preferences come first.
Adding new widgets:
new Desk.Widget(-string:widgetURL-);