$( document ).ready( function () {
"use strict";
// set some options as taskbar's defaults
$.simone.taskbarSetup({
languageSelect: true,
languages: [ "en", "pl" ],
orientation: "vertical",
verticalStick: "bottom right",
verticalHeight: "80%",
beforeDroppableOver: function ( event, ui ) {
// we have top bar on page, so let's dissalow dropping
// taskbars on top edge
if ( ui.edge === "top" ) {
event.preventDefault();
}
}
});
// initialize taskbars after calling $.simone.taskbarSetup()
$( ".taskbar" ).taskbar();
$( ".taskbar2" ).taskbar({
verticalStick: "bottom left"
});
// set some more options as default, with true as first parameter
// which is a way to propagate passed options to existing instances
$.simone.taskbarSetup( true, {
clock: true,
networkMonitor: true,
toggleFullscreen: true
});
// initialize another taskbar after second taskbarSetup() call
// - it will have both modifications to prototype made so far
$( ".taskbar-horizontal" ).taskbar({
orientation: "horizontal"
});
// set some options as window's defaults
$.simone.windowSetup({
closable: false,
group: "shared",
width: 400
})
// initialize window after calling $.simone.windowSetup()
$( ".window" ).window({
title: "Initialized after first windowSetup() call"
});
// set some more options as default, with true as first parameter
// which is a way to propagate passed options to existing instances
$.simone.windowSetup( true, {
minimizable: false
});
// initialize another taskbar after second taskbarSetup() call
// - it will have both modifications to prototype made so far
$( ".window2" ).window({
title: "Initialized after second windowSetup() call"
});
});
<div class="taskbar"></div>
<div class="taskbar2"></div>
<div class="taskbar-horizontal"></div>
<div class="window"></div>
<div class="window2"></div>
<div class="demo">
<div class="description">...</div>
</div>