code stringlengths 1 2.08M | language stringclasses 1
value |
|---|---|
/*this function change selected location button*/
var liContextMenuIdOpened=null;//id del contextMenu aperto
var firstClick=true;
function changeSelectedLocation(id){
var i=0;
while(true){
li=document.getElementById("location"+i)
if(li==null)
break;
if("location"+i==i... | JavaScript |
var loadingtext;
function openPopup(){
loadingtext=$("#popupcontent").html();
var popup=$("#popupwrapper");
popup.css("width",$(window).width());
var offset=$(window).scrollTop()+100;
popup.css("top",offset);
popup.css("display","block");
$(window).bind('resize', function() {
... | JavaScript |
dojo.require("dojo.io.IframeIO");
// formId -> Id del form da sottomettere
// indicatorId -> Id dell'indicator
// viewId -> Id della vista da aggiornare
function sendToServer(formId, indicatorId, viewId) {
// mostra l'indicator
document.getElementById(indicatorId).style.display = '';
var b... | JavaScript |
Drupal.backup_migrate = {
callbackURL : "",
autoAttach : function() {
if (Drupal.settings.backup_migrate !== undefined) {
if ($("#edit-save-settings").length && !$("#edit-save-settings").attr("checked")) {
// Disable input and hide its description.
// Set display none instead of using ... | JavaScript |
/**
* @file
* This will use jQuery AJAX to replace a thumbnail with its video version.
*/
Drupal.behaviors.emvideoThumbnailReplacement = function(context) {
// On load, add a span for the play button to any required thumbnails.
$('a.emvideo-thumbnail-replacement:not(.emvideo-thumbnail-replacement-processed)',... | JavaScript |
/**
* This function looks for swfobject class items and loads them
* as swfobjects.
*/
Drupal.behaviors.swfobjectInit = function (context) {
$('.swfobject:not(.swfobjectInit-processed)', context).addClass('swfobjectInit-processed').each(function () {
var config = Drupal.settings.swfobject_api['files'][$(this... | JavaScript |
/**
* Auto-attach standard client side file input validation.
*/
Drupal.behaviors.filefieldValidateAutoAttach = function(context) {
$("input[type=file]", context).bind('change', Drupal.filefield.validateExtensions);
};
/**
* Prevent FileField uploads when using buttons not intended to upload.
*/
Drupal.behavio... | JavaScript |
<!--
var timerId;
var delay=1000;
var out_dst_str;
//--------------------------------------------------------------------
function ChangeFormat(myobj)
{
target = document.getElementById('worldclock_timestr_div');
sel = myobj.selectedIndex;
if(myobj[sel].value == 'custom') {
// Custom format is selected - show t... | JavaScript |
//** Featured Content Slider script- (c) Dynamic Drive DHTML code library: http://www.dynamicdrive.com.
//** May 2nd, 08'- Script rewritten and updated to 2.0.
//** June 12th, 08'- Script updated to v 2.3, which adds the following features:
//1) Changed behavior of script to actually collapse the previous content... | JavaScript |
//** Featured Content Slider script- (c) Dynamic Drive DHTML code library: http://www.dynamicdrive.com.
//** May 2nd, 08'- Script rewritten and updated to 2.0.
//** June 12th, 08'- Script updated to v 2.3, which adds the following features:
//1) Changed behavior of script to actually collapse the previous content wh... | JavaScript |
/**
* @file tabs.js
* jQuery UI Tabs (Tabs 3)
*
* This is nothing more than the pure jquery UI tabs implementation.
* It has been implemented under the Drupal.Views.Tabs namespace to
* avoid conflicts with alternatve versions of jquery, jquery UI.
*/
Drupal.Views = Drupal.Views || {};
Drupal.Views.Tabs = func... | JavaScript |
/**
* @file dependent.js
*
* Written by dmitrig01 (Dmitri Gaskin) for Views; this provides dependent
* visibility for form items in Views' ajax forms.
*
* To your $form item definition add:
* - '#process' => array('views_process_dependency'),
* - Add '#dependency' => array('id-of-form-item' => array(list, of, v... | JavaScript |
/**
* @file ajaxView.js
*
* Handles AJAX fetching of views, including filter submission and response.
*/
Drupal.Views.Ajax = Drupal.Views.Ajax || {};
/**
* An ajax responder that accepts a packet of JSON data and acts appropriately.
*
* The following fields control behavior.
* - 'display': Display the associ... | JavaScript |
/**
* @file view-list.js
*
* Handles JS things for view listing.
*/
Drupal.behaviors.ViewsList = function() {
var timeoutID = 0;
$('form#views-ui-list-views-form select:not(.views-processed)')
.addClass('views-processed')
.change(function() {
$('#edit-views-apply').click();
});
};
| JavaScript |
/**
* @file base.js
*
* Some basic behaviors and utility functions for Views.
*/
Drupal.Views = {};
/**
* jQuery UI tabs, Views integration component
*/
Drupal.behaviors.viewsTabs = function (context) {
$('#views-tabset:not(.views-processed)').addClass('views-processed').each(function() {
new Drupal.Views... | JavaScript |
/**
* @file ajax_admin.js
*
* Handles AJAX submission and response in Views UI.
*/
Drupal.Views.Ajax = Drupal.Views.Ajax || {};
/**
* Handles the simple process of setting the ajax form area with new data.
*/
Drupal.Views.Ajax.setForm = function(title, output) {
$(Drupal.settings.views.ajax.title).html(title)... | JavaScript |
$(document).ready(function() {
$('.agenda-block .calendar_title').click(function () {
$(this).next('ul').toggle('show');
});
});
| JavaScript |
/**
* Provide the HTML to create the modal dialog.
*/
Drupal.theme.prototype.CToolsSampleModal = function () {
var html = ''
html += '<div id="ctools-modal" class="popups-box">';
html += ' <div class="ctools-modal-content ctools-sample-modal-content">';
html += ' <table cellpadding="0" cellspacing="0" id="... | JavaScript |
// $Id: modal.js,v 1.17.2.20 2010/10/20 19:22:08 merlinofchaos Exp $
/**
* @file
*
* Implement a modal form.
*
* @see modal.inc for documentation.
*
* This javascript relies on the CTools ajax responder.
*/
(function ($) {
// Make sure our objects are defined.
Drupal.CTools = Drupal.CTools || {};
Drupal.... | JavaScript |
// $Id: ajax-responder.js,v 1.18.2.24 2010/08/27 22:09:48 merlinofchaos Exp $
/**
* @file
*
* CTools flexible AJAX responder object.
*/
(function ($) {
Drupal.CTools = Drupal.CTools || {};
Drupal.CTools.AJAX = Drupal.CTools.AJAX || {};
Drupal.CTools.AJAX.commands = Drupal.CTools.AJAX.commands || {};
Drupal... | JavaScript |
// $Id: dropdown.js,v 1.3.2.1 2009/10/05 23:38:33 merlinofchaos Exp $
/**
* @file
* Implement a simple, clickable dropdown menu.
*
* See dropdown.theme.inc for primary documentation.
*
* The javascript relies on four classes:
* - The dropdown must be fully contained in a div with the class
* ctools-dropdown. ... | JavaScript |
// $Id: dependent.js,v 1.4.2.2 2009/10/05 23:38:33 merlinofchaos Exp $
/**
* @file
*
* Written by dmitrig01 (Dmitri Gaskin) for CTools; this provides dependent
* visibility for form items in CTools' ajax forms.
*
* To your $form item definition add:
* - '#process' => array('CTools_process_dependency'),
* - Add ... | JavaScript |
// $Id: jump-menu.js,v 1.1.2.2 2009/10/28 01:53:15 merlinofchaos Exp $
(function($) {
Drupal.behaviors.CToolsJumpMenu = function(context) {
$('.ctools-jump-menu-hide:not(.ctools-jump-menu-processed)')
.addClass('ctools-jump-menu-processed')
.hide();
$('.ctools-jump-menu-change:not(.ctools-jump-m... | JavaScript |
// $Id: stylizer.js,v 1.1.2.1 2010/02/17 01:04:50 merlinofchaos Exp $
(function ($) {
Drupal.CTools = Drupal.CTools || {};
Drupal.CTools.Stylizer = {};
Drupal.CTools.Stylizer.addFarbtastic = function(context) {
// This behavior attaches by ID, so is only valid once on a page.
if ($('ctools_stylizer_colo... | JavaScript |
// $Id: auto-submit.js,v 1.1.2.2 2010/06/16 16:15:00 merlinofchaos Exp $
/**
* To make a form auto submit, all you have to do is 3 things:
*
* ctools_add_js('auto-submit');
*
* On gadgets you want to auto-submit when changed, add the ctools-auto-submit
* class. With FAPI, add:
* @code
* '#attributes' => array... | JavaScript |
// $Id: collapsible-div.js,v 1.6.2.2 2009/10/09 17:10:00 merlinofchaos Exp $
/**
* @file
* Javascript required for a simple collapsible div.
*
* Creating a collapsible div with this doesn't take too much. There are
* three classes necessary:
*
* - ctools-collapsible-container: This is the overall container that ... | JavaScript |
// $Id: page-list.js,v 1.3 2009/07/12 18:32:04 merlinofchaos Exp $
/**
* Provide some extra responses for the page list so we can have automatic
* on change.
*/
Drupal.behaviors.PageManagerList = function() {
var timeoutID = 0;
$('form#page-manager-list-pages-form select:not(.pm-processed)')
.addClass('pm-... | JavaScript |
if (Drupal.jsEnabled) {
$(document).ready(function() {
if ($("#edit-pathauto-perform-alias").size() && $("#edit-pathauto-perform-alias").attr("checked")) {
// Disable input and hide its description.
$("#edit-path").attr("disabled","disabled");
$("#edit-path-wrapper > div.description").hide(0);
... | JavaScript |
if (Drupal.jsEnabled) {
$(document).ready(function() {
// I am assuming that all of the links are refering to an internal node
// add the attribute rel=facebox to all of the links I want to have a popup
$('div.view-field > a').attr('class', 'popup');
// on click of a link
$('a.popup').cli... | JavaScript |
// $Id: calendar_overlap.js,v 1.1.2.1 2010/11/28 23:31:28 karens Exp $
/*
* Create the splitter, set the viewport size, and set the position of the scrollbar to the first item.
*/
Drupal.behaviors.calendarSetScroll = function (context) {
// Make multi-day resizable - stolen/borrowed from textarea.js
$('.header-... | JavaScript |
// $Id: calendar_colorpicker.js,v 1.1.4.3 2008/11/21 22:04:56 karens Exp $
/**
* Implementation of hook_elements.
*
* Much of the colorpicker code was adapted from the Colorpicker module.
* That module has no stable release yet nor any D6 branch.
*/
/*
* Bind the colorpicker event to the form element
*/
Drupal... | JavaScript |
// $Id: nice_menus.js,v 1.21 2010/06/18 06:14:12 vordude Exp $
// This uses Superfish 1.4.8
// (http://users.tpg.com.au/j_birch/plugins/superfish)
// Add Superfish to all Nice menus with some basic options.
(function ($) {
$(document).ready(function() {
$('ul.nice-menu').superfish({
// Apply a generic hov... | JavaScript |
/*
* Superfish v1.4.8 - jQuery menu widget
* Copyright (c) 2008 Joel Birch
*
* Dual licensed under the MIT and GPL licenses:
* http://www.opensource.org/licenses/mit-license.php
* http://www.gnu.org/licenses/gpl.html
*
* CHANGELOG: http://users.tpg.com.au/j_birch/plugins/superfish/changelog.txt
*/
;(functi... | JavaScript |
/**
* Easy Social - Add external facebook js
*/
$(document).ready(function() {
$.getScript('http://static.ak.fbcdn.net/connect.php/js/FB.Share');
}); | JavaScript |
/**
* Easy Social - Add external twitter js
*/
$(document).ready(function() {
$.getScript('http://platform.twitter.com/widgets.js');
}); | JavaScript |
/**
* Easy Social - Add external googleplus js
*/
$(document).ready(function() {
$.getScript('https://apis.google.com/js/plusone.js');
}); | JavaScript |
/**
* Easy Social - Add external linkedin js
*/
$(document).ready(function() {
$.getScript('http://platform.linkedin.com/in.js');
}); | JavaScript |
$(document).ready(function() {
if (!$('#admin-menu').length) {
return;
}
// Apply margin-top if enabled; directly applying marginTop doesn't work in IE.
if (Drupal && Drupal.settings && Drupal.settings.admin_menu) {
if (Drupal.settings.admin_menu.margin_top) {
$('body').addClass('admin-menu');
... | JavaScript |
/*global Drupal,jQuery */
(function($) {
"use strict";
Drupal.imagecache = {
/**
* Remove the files directory prefix from a path.
*/
stripFileDirectory: function(path) {
var filePath = Drupal.settings.imagecache.filesDirectory;
if (path.substr(0, filePath.length + 1) === filePath + '... | JavaScript |
/**
* Attach handlers to toggle the twitter message field and inform the number
* of characters remaining to achieve the max length
*/
Drupal.behaviors.twitter_post = function (context) {
$("#twitter-textfield", context).keyup(function() {
var charsLeft = (140 - $(this).val().length);
var descDiv = $(this)... | JavaScript |
/**
* Attaches the calendar behavior to all required fields
*/
Drupal.behaviors.date_popup = function (context) {
for (var id in Drupal.settings.datePopup) {
$('#'+ id).bind('focus', Drupal.settings.datePopup[id], function(e) {
if (!$(this).hasClass('date-popup-init')) {
var datePopup = e.data;
... | JavaScript |
/**
* Set the client's system time zone as default values of form fields.
*/
Drupal.setDefaultTimezone = function() {
var dateString = Date();
// In some client environments, date strings include a time zone
// abbreviation which can be interpreted by PHP.
var matches = Date().match(/\(([A-Z]{3,5})\)/);
var... | JavaScript |
/**
* Show/hide custom format sections on the date-time settings page.
*/
Drupal.behaviors.dateDateTime = function(context) {
// Show/hide custom format depending on the select's value.
$('select.date-format:not(.date-time-processed)', context).change(function() {
$(this).addClass('date-time-processed').paren... | JavaScript |
// $Id: slider.js,v 1.1.2.2 2009/02/25 11:52:11 marktheunissen Exp $
Drupal.behaviors.initSlider = function(context) {
var panels = $('#slider .scrollContainer > div');
var container = $('#slider .scrollContainer');
// if false, we'll float all the panels left and fix the width
// of the container
var horiz... | JavaScript |
(function ($) {
Drupal.behaviors.tokenTree = function() {
$('table.token-tree').each(function() {
$(this).treeTable();
});
};
Drupal.behaviors.tokenInsert = function() {
// Keep track of which textfield was last selected/focused.
$('textarea, input[type="text"]').focus(function() {
Drupal.settings.to... | JavaScript |
/*
* jQuery treeTable Plugin 2.3.0
* http://ludo.cubicphuse.nl/jquery-plugins/treeTable/
*
* Copyright 2010, Ludo van den Boom
* Dual licensed under the MIT or GPL Version 2 licenses.
*/
(function($) {
// Helps to make options available to all functions
// TODO: This gives problems when there are both expand... | JavaScript |
Drupal.flexible = Drupal.flexible || {};
Drupal.flexible.splitters = [];
/**
* Fix the height of all splitters to be the same as the items they are
* splitting.
*/
Drupal.flexible.fixHeight = function() {
for (i in Drupal.flexible.splitters) {
Drupal.flexible.splitters[i].fixHeight();
}
}
Drupal.behavior... | JavaScript |
// Ensure the $ alias is owned by jQuery.
(function($) {
Drupal.PanelsIPE = {
editors: {},
bindClickDelete: function(context) {
$('a.pane-delete:not(.pane-delete-processed)', context)
.addClass('pane-delete-processed')
.click(function() {
if (confirm('Remove this pane?')) {
$(thi... | JavaScript |
/**
* @file
* Implement basic methods required by all of panels.
*/
(function ($) {
Drupal.Panels = {}
Drupal.Panels.changed = function(item) {
if (!item.is('.changed')) {
item.addClass('changed');
item.find('div.grabber span.text').append(' <span class="star">*</span> ');
}
};
Drupal.... | JavaScript |
(function ($) {
Drupal.Panels = {};
Drupal.Panels.autoAttach = function() {
if ($.browser.msie) {
// If IE, attach a hover event so we can see our admin links.
$("div.panel-pane").hover(
function() {
$('div.panel-hide', this).addClass("panel-hide-hover"); return true;
},
... | JavaScript |
/**
* @file display_editor.js
*
* Contains the javascript for the Panels display editor.
*/
(function ($) {
/** Delete pane button **/
Drupal.Panels.bindClickDelete = function(context) {
$('a.pane-delete:not(.pane-delete-processed)', context)
.addClass('pane-delete-processed')
.click(function()... | JavaScript |
/**
* @file layout.js
*
* Contains javascript to make layout modification a little nicer.
*/
(function ($) {
Drupal.Panels.Layout = {};
Drupal.Panels.Layout.autoAttach = function() {
$('div.form-item div.layout-icon').click(function() {
$widget = $('input', $(this).parent());
// Toggle if a che... | JavaScript |
// $Id: flowplayer.admin.js,v 1.1.2.2 2009/02/24 18:00:56 robloach Exp $
/**
* @file
* Provides the Drupal behavior for the Flowplayer administration page.
*/
/**
* The Flowplayer Drupal administration behavior.
*/
Drupal.behaviors.flowplayeradmin = function() {
// Update both the Flowplayer preview and the te... | JavaScript |
// $Id: flowplayer.js,v 1.1.2.6 2009/11/19 21:33:48 robloach Exp $
/**
* @file
* Provides the FlowPlayer Drupal behavior.
*/
/**
* The FlowPlayer Drupal behavior that creates the set of FlowPlayer elements from Drupal.settings.flowplayer.
*/
Drupal.behaviors.flowplayer = function() {
jQuery.each(Drupal.setting... | JavaScript |
// $Id: content.js,v 1.1.2.3 2008/10/06 14:30:01 karens Exp $
Drupal.behaviors.cckManageFields = function(context) {
attachUpdateSelects(context);
};
function attachUpdateSelects(context) {
var widgetTypes = Drupal.settings.contentWidgetTypes;
var fields = Drupal.settings.contentFields;
// Store the default ... | JavaScript |
Drupal.behaviors.i18ntaxonomy = function (context) {
if (Drupal.settings && Drupal.settings.i18ntaxonomy_vocabulary_form) {
$('form#taxonomy-form-vocabulary input.form-radio', context).filter('[name=i18nmode]').click(function () {
var languageSelect = $('form#taxonomy-form-vocabulary select#edit-language', ... | JavaScript |
/**
* Rewrite autocomplete inputs to pass the language of the node currently being
* edited in the path.
*
* This functionality ensures node autocompletes get suggestions for the node's
* language rather than the current interface language.
*/
Drupal.behaviors.i18n = function (context) {
if (Drupal.settings &&... | JavaScript |
/*
* datepicker_methods.js
*/
(function($) {
module("datepicker: methods");
test('destroy', function() {
var inp = init('#inp');
ok(inp.is('.hasDatepicker'), 'Default - marker class set');
ok($.data(inp[0], PROP_NAME), 'Default - instance present');
ok(inp.next().is('#alt'), 'Default - button absent'... | JavaScript |
/*
* datepicker_events.js
*/
(function($) {
module("datepicker: events");
var selectedThis = null;
var selectedDate = null;
var selectedInst = null;
function callback(date, inst) {
selectedThis = this;
selectedDate = date;
selectedInst = inst;
}
function callback2(year, month, inst) {
select... | JavaScript |
/*
* datepicker_defaults.js
*/
var datepicker_defaults = {
disabled: false
};
//commonWidgetTests('datepicker', { defaults: datepicker_defaults });
| JavaScript |
/*
* datepicker_tickets.js
*/
(function($) {
module("datepicker: tickets");
test('#4055: onclick events contain references to "jQuery"', function() {
// no assertions, if the test fails, there will be an error
var _jQuery = jQuery;
jQuery = null;
$('<div/>').appendTo('body').datepicker()
// t... | JavaScript |
/*
* datepicker_core.js
*/
function equalsDate(d1, d2, message) {
if (!d1 || !d2) {
ok(false, message + ' - missing date');
return;
}
d1 = new Date(d1.getFullYear(), d1.getMonth(), d1.getDate());
d2 = new Date(d2.getFullYear(), d2.getMonth(), d2.getDate());
equals(d1.toString(), d2.toString(), me... | JavaScript |
/*
* droppable_events.js
*/
(function($) {
module("droppable: events");
test("activate", function() {
ok(false, 'missing test - untested code is broken code');
});
test("deactivate", function() {
ok(false, 'missing test - untested code is broken code');
});
test("over", function() {
ok(false, '... | JavaScript |
/*
* droppable_tickets.js
*/
(function($) {
module("droppable: tickets");
})(jQuery);
| JavaScript |
/*
* droppable_methods.js
*/
(function($) {
module("droppable: methods");
test("init", function() {
expect(6);
$("<div></div>").appendTo('body').droppable().remove();
ok(true, '.droppable() called on element');
$([]).droppable();
ok(true, '.droppable() called on empty collection');
$("<div>... | JavaScript |
/*
* droppable_options.js
*/
(function($) {
module("droppable: options");
test("{ accept '*' }, default ", function() {
equals(droppable_defaults.accept, '*');
ok(false, 'missing test - untested code is broken code');
});
test("{ accept: Selector }", function() {
ok(false, 'missing test - unteste... | JavaScript |
/*
* droppable_defaults.js
*/
var droppable_defaults = {
accept: '*',
activeClass: false,
addClasses: true,
disabled: false,
greedy: false,
hoverClass: false,
scope: "default",
tolerance: "intersect"
};
commonWidgetTests('droppable', { defaults: droppable_defaults });
| JavaScript |
/*
* droppable_core.js
*/
var el, drg;
function shouldBeDroppable() {
ok(false, 'missing test - untested code is broken code');
}
function shouldNotBeDroppable() {
ok(false, 'missing test - untested code is broken code');
}
(function($) {
module("droppable: core");
test("element types", func... | JavaScript |
/*
* progressbar_core.js
*/
var el;
(function($) {
module("progressbar: core");
test("accessibility", function() {
expect(7);
el = $("#progressbar").progressbar();
equals(el.attr("role"), "progressbar", "aria role");
equals(el.attr("aria-valuemin"), 0, "aria-valuemin");
equals(el.attr("aria-... | JavaScript |
/*
* progressbar_tickets.js
*/
(function($) {
module("progressbar: tickets");
})(jQuery);
| JavaScript |
/*
* progressbar_options.js
*/
(function($) {
module("progressbar: options");
test("{ value : 0 }, default", function() {
ok(false, "missing test - untested code is broken code.");
});
})(jQuery);
| JavaScript |
/*
* progressbar_defaults.js
*/
var progressbar_defaults = {
disabled: false,
value: 0
};
commonWidgetTests('progressbar', { defaults: progressbar_defaults });
| JavaScript |
/*
* progressbar_events.js
*/
(function($) {
module("progressbar: events");
test("change", function() {
ok(false, "missing test - untested code is broken code.");
});
})(jQuery);
| JavaScript |
/*
* progressbar_methods.js
*/
(function($) {
module("progressbar: methods");
test("init", function() {
expect(1);
$("<div></div>").appendTo('body').progressbar().remove();
ok(true, '.progressbar() called on element');
});
test("destroy", function() {
expect(1);
$("<div></div>").appendTo(... | JavaScript |
/*
* sortable_events.js
*/
(function($) {
module("sortable: events");
test("start", function() {
var hash;
$("#sortable")
.sortable({ start: function(e, ui) { hash = ui; } })
.find('li:eq(0)').simulate("drag", { dx: 0, dy: 10 });
ok(hash, 'start event triggered');
ok(hash.helper, 'UI has... | JavaScript |
/*
* sortable_defaults.js
*/
var sortable_defaults = {
appendTo: "parent",
axis: false,
cancel: ":input,option",
connectWith: false,
containment: false,
cursor: 'auto',
cursorAt: false,
delay: 0,
disabled: false,
distance: 1,
dropOnEmpty: true,
forcePlaceholderSize: false,
forceHelperSi... | JavaScript |
/*
* sortable_methods.js
*/
(function($) {
var el, offsetBefore, offsetAfter, dragged;
var drag = function(handle, dx, dy) {
offsetBefore = $(handle).offset();
$(handle).simulate("drag", {
dx: dx || 0,
dy: dy || 0
});
dragged = { dx: dx, dy: dy };
offsetAfter = $(handle).offset();
}
var s... | JavaScript |
/*
* sortable_core.js
*/
(function($) {
module("sortable: core");
})(jQuery);
| JavaScript |
/*
* sortable_tickets.js
*/
(function($) {
var el, offsetBefore, offsetAfter, dragged;
var drag = function(handle, dx, dy) {
offsetBefore = $(handle).offset();
$(handle).simulate("drag", {
dx: dx || 0,
dy: dy || 0
});
dragged = { dx: dx, dy: dy };
offsetAfter = $(handle).offset();
}
var s... | JavaScript |
/*
* sortable_options.js
*/
(function($) {
module("sortable: options");
test("{ appendTo: 'parent' }, default", function() {
ok(false, "missing test - untested code is broken code.");
});
test("{ appendTo: Selector }", function() {
ok(false, "missing test - untested code is broken code.");
});
te... | JavaScript |
/*
* tabs_events.js
*/
(function($) {
module("tabs: events");
test('select', function() {
ok(false, "missing test - untested code is broken code.");
});
test('load', function() {
ok(false, "missing test - untested code is broken code.");
});
test('show', function() {
expect(4);
var uiObj;
... | JavaScript |
/*
* tabs_options.js
*/
(function($) {
module("tabs: options");
test('ajaxOptions', function() {
ok(false, "missing test - untested code is broken code.");
});
test('cache', function() {
ok(false, "missing test - untested code is broken code.");
});
test('collapsible', function() {
expect(4);
... | JavaScript |
/*
* tabs_tickets.js
*/
(function($) {
module("tabs: tickets");
test('#2715 - id containing colon', function() {
// http://dev.jqueryui.com/ticket/2715
expect(4);
el = $('#tabs2').tabs();
ok( $('div.ui-tabs-panel:eq(0)', '#tabs2').is(':visible'), 'first panel should be visible' );
ok( $('div.ui-t... | JavaScript |
/*
* tabs_core.js
*/
var el;
(function($) {
module("tabs: core");
test('ajax', function() {
expect(4);
stop();
el = $('#tabs2');
el.tabs({
selected: 2,
load: function() {
// spinner: default spinner
equals($('li:eq(2) > a > span', el).length, 1, "should restore tab markup after... | JavaScript |
/*
* tabs_defaults.js
*/
var tabs_defaults = {
ajaxOptions: null,
cache: false,
collapsible: false,
cookie: null,
disabled: [],
event: 'click',
fx: null,
idPrefix: 'ui-tabs-',
panelTemplate: '<div></div>',
spinner: '<em>Loading…</em>',
tabTemplate: '<li><a href="#{href}"><span>#{label... | JavaScript |
/*
* tabs_methods.js
*/
(function($) {
module("tabs: methods");
test('init', function() {
expect(9);
el = $('#tabs1').tabs();
ok(true, '.tabs() called on element');
ok( el.is('.ui-tabs.ui-widget.ui-widget-content.ui-corner-all'), 'attach classes to container');
ok( $('ul', el).is('.ui-tabs-nav... | JavaScript |
$(function() {
$('body').prepend(
'<h1 id="header">' + document.title + '</h1>' +
'<h2 id="banner"></h2>' +
'<h2 id="userAgent"></h2>' +
'<ol id="tests"></ol>'
);
});
function testWidgetDefaults(widget, defaults) {
var pluginDefaults = $.extend({},
$.widget.defaults,
$.ui[widg... | JavaScript |
/*
* draggable_tickets.js
*/
(function($) {
module("draggable: tickets");
})(jQuery);
| JavaScript |
/*
* draggable_methods.js
*/
(function($) {
function shouldmove(why) {
drag(el, 50, 50);
moved(50, 50, why);
}
function shouldnotmove(why) {
drag(el, 50, 50);
moved(0, 0, why);
}
module("draggable: methods");
test("init", function() {
expect(6);
$("<div></div>").appendTo('body').draggab... | JavaScript |
/*
* draggable_defaults.js
*/
var draggable_defaults = {
addClasses: true,
appendTo: "parent",
axis: false,
cancel: ":input,option",
connectToSortable: false,
containment: false,
cursor: "auto",
cursorAt: false,
delay: 0,
disabled: false,
distance: 1,
grid: false,
handle: false,
helpe... | JavaScript |
/*
* draggable_core.js
*/
var el, offsetBefore, offsetAfter, dragged;
var drag = function(handle, dx, dy) {
var element = el.data("draggable").element;
offsetBefore = el.offset();
$(handle).simulate("drag", {
dx: dx || 0,
dy: dy || 0
});
dragged = { dx: dx, dy: dy };
offsetAfter = el.offset(... | JavaScript |
/*
* draggable_events.js
*/
(function($) {
module("draggable: events");
test("callbacks occurance count", function() {
expect(3);
var start = 0, stop = 0, dragc = 0;
el = $("#draggable2").draggable({
start: function() { start++; },
drag: function() { dragc++; },
stop: function() { stop++; ... | JavaScript |
/*
* draggable_options.js
*/
(function($) {
function testScroll(position) {
$("#main").css('position', position);
drag(el, 50, 50);
moved(50, 50, position+' parent');
}
function setScroll(what) {
if(what) {
$(document).scrollTop(100); $(document).scrollLeft(100);
} else {
$("#main")[0].scrol... | JavaScript |
/*
* resizable_defaults.js
*/
var resizable_defaults = {
alsoResize: false,
animate: false,
animateDuration: 'slow',
animateEasing: 'swing',
aspectRatio: false,
autoHide: false,
cancel: ':input,option',
containment: false,
delay: 0,
disabled: false,
distance: 1,
ghost: false,
grid: fals... | JavaScript |
/*
* resizable_core.js
*/
var el;
var drag = function(el, dx, dy, complete) {
// speed = sync -> Drag syncrhonously.
// speed = fast|slow -> Drag asyncrhonously - animated.
//this mouseover is to work around a limitation in resizable
//TODO: fix resizable so handle doesn't require mouseover in ord... | JavaScript |
/*
* resizable_tickets.js
*/
(function($) {
module("resizable: tickets");
})(jQuery);
| JavaScript |
/*
* resizable_methods.js
*/
(function($) {
module("resizable: methods");
test("init", function() {
expect(6);
$("<div></div>").appendTo('body').resizable().remove();
ok(true, '.resizable() called on element');
$([]).resizable().remove();
ok(true, '.resizable() called on empty collection');
... | JavaScript |
/*
* resizable_options.js
*/
(function($) {
module("resizable: options");
test("aspectRatio: 'preserve' (e)", function() {
expect(4);
var handle = '.ui-resizable-e', target = $('#resizable1').resizable({ aspectRatio: 'preserve', handles: 'all', minWidth: 70, minHeight: 50, maxWidth: 150, maxHeight: 130... | JavaScript |
/*
* resizable_events.js
*/
(function($) {
module("resizable: events");
test("start", function() {
ok(false, "missing test - untested code is broken code.");
});
test("resize", function() {
ok(false, "missing test - untested code is broken code.");
});
test("stop", function() {
ok(false, "missi... | JavaScript |
/*
* dialog_defaults.js
*/
var dialog_defaults = {
autoOpen: true,
bgiframe: false,
buttons: {},
closeOnEscape: true,
closeText: 'close',
disabled: false,
dialogClass: '',
draggable: true,
height: 'auto',
hide: null,
maxHeight: false,
maxWidth: false,
minHeight: 150,
minWidth: 150,
... | JavaScript |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.