code
stringlengths
1
2.08M
language
stringclasses
1 value
/* CodeMirror main module (http://codemirror.net/) * * Implements the CodeMirror constructor and prototype, which take care * of initializing the editor frame, and providing the outside interface. */ // The CodeMirrorConfig object is used to specify a default // configuration. If you specify such an object...
JavaScript
/* Parse function for JavaScript. Makes use of the tokenizer from * tokenizejavascript.js. Note that your parsers do not have to be * this complicated -- if you don't want to recognize local variables, * in many languages it is enough to just look for braces, semicolons, * parentheses, etc, and know when you a...
JavaScript
/** * Storage and control for undo information within a CodeMirror * editor. 'Why on earth is such a complicated mess required for * that?', I hear you ask. The goal, in implementing this, was to make * the complexity of storing and reverting undo information depend * only on the size of the edited or restor...
JavaScript
var DummyParser = Editor.Parser = (function() { function tokenizeDummy(source) { while (!source.endOfLine()) source.next(); return "text"; } function parseDummy(source) { function indentTo(n) {return function() {return n;}} source = tokenizer(source, tokenizeDummy); var space = 0; ...
JavaScript
/* A few useful utility functions. */ // Capture a method on an object. function method(obj, name) { return function() {obj[name].apply(obj, arguments);}; } // The value used to signal the end of a sequence in iterators. var StopIteration = {toString: function() {return "StopIteration"}}; // Apply a fun...
JavaScript
/* Functionality for finding, storing, and restoring selections * * This does not provide a generic API, just the minimal functionality * required by the CodeMirror system. */ // Namespace object. var select = {}; (function() { select.ie_selection = document.selection && document.selection.createRang...
JavaScript
/* Simple parser for CSS */ var CSSParser = Editor.Parser = (function() { var tokenizeCSS = (function() { function normal(source, setState) { var ch = source.next(); if (ch == "@") { source.nextWhileMatches(/\w/); return "css-at"; } else if (ch == "/" && source....
JavaScript
// A framework for simple tokenizers. Takes care of newlines and // white-space, and of getting the text from the source stream into // the token object. A state is a function of two arguments -- a // string stream and a setState function. The second can be used to // change the tokenizer's state, and can be ignor...
JavaScript
var HTMLMixedParser = Editor.Parser = (function() { // tags that trigger seperate parsers var triggers = { "script": "JSParser", "style": "CSSParser" }; function checkDependencies() { var parsers = ['XMLParser']; for (var p in triggers) parsers.push(triggers[p]); for (var i in...
JavaScript
/* Demonstration of embedding CodeMirror in a bigger application. The * interface defined here is a mess of prompts and confirms, and * should probably not be used in a real project. */ function MirrorFrame(place, options) { this.home = document.createElement("div"); if (place.appendChild) place.ap...
JavaScript
/* The Editor object manages the content of the editable frame. It * catches events, colours nodes, and indents lines. This file also * holds some functions for transforming arbitrary DOM structures into * plain sequences of <span> and <br> elements */ var internetExplorer = document.selection && window.Act...
JavaScript
/* Copyright (c) 2008-2009 Yahoo! Inc. All rights reserved. The copyrights embodied in the content of this file are licensed by Yahoo! Inc. under the BSD (revised) open source license @author Dan Vlad Dascalescu <dandv@yahoo-inc.com> Parse function for PHP. Makes use of the tokenizer from tokenizephp.js. B...
JavaScript
/* Copyright (c) 2008-2009 Yahoo! Inc. All rights reserved. The copyrights embodied in the content of this file are licensed by Yahoo! Inc. under the BSD (revised) open source license @author Vlad Dan Dascalescu <dandv@yahoo-inc.com> Tokenizer for PHP code References: + http://php.net/manual/en/reser...
JavaScript
/* Copyright (c) 2008-2009 Yahoo! Inc. All rights reserved. The copyrights embodied in the content of this file are licensed by Yahoo! Inc. under the BSD (revised) open source license @author Dan Vlad Dascalescu <dandv@yahoo-inc.com> Based on parsehtmlmixed.js by Marijn Haverbeke. */ var PHPHTMLMixedParse...
JavaScript
/* Parse function for JavaScript. Makes use of the tokenizer from * tokenizecsharp.js. Note that your parsers do not have to be * this complicated -- if you don't want to recognize local variables, * in many languages it is enough to just look for braces, semicolons, * parentheses, etc, and know when you are i...
JavaScript
/* Tokenizer for CSharp code */ var tokenizeCSharp = (function() { // Advance the stream until the given character (not preceded by a // backslash) is encountered, or the end of the line is reached. function nextUntilUnescaped(source, end) { var escaped = false; var next; while (!source.endO...
JavaScript
function waitForStyles() { for (var i = 0; i < document.styleSheets.length; i++) if (/googleapis/.test(document.styleSheets[i].href)) return document.body.className += " droid"; setTimeout(waitForStyles, 100); } setTimeout(function() { if (/AppleWebKit/.test(navigator.userAgent) && /iP[oa]d|iPho...
JavaScript
CKFinder.addPlugin( 'fileeditor', function( api ) { var regexExt = /^(.*)\.([^\.]+)$/, regexTextExt = /^(txt|css|html|htm|js|asp|cfm|cfc|ascx|php|inc|xml|xslt|xsl)$/i, regexCodeMirrorExt = /^(css|html|htm|js|xml|xsl|php)$/i, codemirror, file, fileLoaded = false, doc; var codemirrorPath = CKFi...
JavaScript
CKFinder.addPlugin( 'imageresize', { connectorInitialized : function( api, xml ) { var node = xml.selectSingleNode( 'Connector/PluginsInfo/imageresize/@smallThumb' ); if ( node ) CKFinder.config.imageresize_thumbSmall = node.value; node = xml.selectSingleNode( 'Connector/PluginsInfo/imageresize/@mediu...
JavaScript
/** * Copyright (c) 2003-2011, CKSource - Frederico Knabben. All rights reserved. * For licensing, see LICENSE.html or http://ckeditor.com/license * * CKFinder 2.x - sample "dummy" plugin. * * To enable it, add the following line to config.js: * config.extraPlugins = 'dummy'; */ /** * See http...
JavaScript
/* Copyright (c) 2003-2011, CKSource - Frederico Knabben. All rights reserved. For licensing, see LICENSE.html or http://ckeditor.com/license */ CKFinder.setPluginLang( 'dummy', 'pl', { dummy : { title : 'Testowe okienko', menuItem : 'Otwórz okienko dummy', typeText : 'Podaj jakiś tekst...
JavaScript
/* Copyright (c) 2003-2011, CKSource - Frederico Knabben. All rights reserved. For licensing, see LICENSE.html or http://ckeditor.com/license */ CKFinder.setPluginLang( 'dummy', 'en', { dummy : { title : 'Dummy dialog', menuItem : 'Open dummy dialog', typeText : 'Please type some text.' } });
JavaScript
/* Copyright (c) 2003-2011, CKSource - Frederico Knabben. All rights reserved. For licensing, see LICENSE.html or http://ckfinder.com/license */ CKFinder.customConfig = function( config ) { // Define changes to default configuration here. For example: // config.skin = 'v1'; // config.language = 'fr'; }; ...
JavaScript
window.onload = function() { var copyP = document.createElement( 'p' ) ; copyP.className = 'copyright' ; copyP.innerHTML = '&copy; 2007-2011 <a href="http://cksource.com" target="_blank">CKSource</a> - Frederico Knabben . All rights reserved.<br /><br />' ; document.body.appendChild( document.createElement( '...
JavaScript
window.onload = function() { var copyP = document.createElement( 'p' ) ; copyP.className = 'copyright' ; copyP.innerHTML = '&copy; 2007-2011 <a href="http://cksource.com" target="_blank">CKSource</a> - Frederico Knabben . Kaikki oikeudet pidätetään.<br /><br />' ; document.body.appendChild( document.createEle...
JavaScript
window.onload = function() { var copyP = document.createElement( 'p' ) ; copyP.className = 'copyright' ; copyP.innerHTML = '&copy; 2007-2011 <a href="http://cksource.com" target="_blank">CKSource</a> - Frederico Knabben . Todos los derechos reservados.<br /><br />' ; document.body.appendChild( document.create...
JavaScript
window.onload = function() { var copyP = document.createElement( 'p' ) ; copyP.className = 'copyright' ; copyP.innerHTML = '&copy; 2007-2011 <a href="http://cksource.com" target="_blank">CKSource</a> - Frederico Knabben . Todos los derechos reservados.<br /><br />' ; document.body.appendChild( document.create...
JavaScript
window.onload = function() { var copyP = document.createElement( 'p' ) ; copyP.className = 'copyright' ; copyP.innerHTML = '&copy; 2007-2011 <a href="http://cksource.com" target="_blank">CKSource</a> - Frederico Knabben . Wszystkie prawa zastrzeżone.<br /><br />' ; document.body.appendChild( document.createEl...
JavaScript
/* * CKFinder * ======== * http://ckfinder.com * Copyright (C) 2007-2011, CKSource - Frederico Knabben. All rights reserved. * * The software, this file and its contents are subject to the CKFinder * License. Please read the license.txt file before using, installing, copying, * modifying or distribute ...
JavaScript
/* * CKFinder * ======== * http://ckfinder.com * Copyright (C) 2007-2011, CKSource - Frederico Knabben. All rights reserved. * * The software, this file and its contents are subject to the CKFinder * License. Please read the license.txt file before using, installing, copying, * modifying or distribute ...
JavaScript
/* * CKFinder * ======== * http://ckfinder.com * Copyright (C) 2007-2011, CKSource - Frederico Knabben. All rights reserved. * * The software, this file and its contents are subject to the CKFinder * License. Please read the license.txt file before using, installing, copying, * modifying or distribute ...
JavaScript
/* * CKFinder * ======== * http://ckfinder.com * Copyright (C) 2007-2011, CKSource - Frederico Knabben. All rights reserved. * * The software, this file and its contents are subject to the CKFinder * License. Please read the license.txt file before using, installing, copying, * modifying or distribute ...
JavaScript
/* * CKFinder * ======== * http://ckfinder.com * Copyright (C) 2007-2011, CKSource - Frederico Knabben. All rights reserved. * * The software, this file and its contents are subject to the CKFinder * License. Please read the license.txt file before using, installing, copying, * modifying or distribute ...
JavaScript
/* * CKFinder * ======== * http://ckfinder.com * Copyright (C) 2007-2011, CKSource - Frederico Knabben. All rights reserved. * * The software, this file and its contents are subject to the CKFinder * License. Please read the license.txt file before using, installing, copying, * modifying or distribute ...
JavaScript
/* * CKFinder * ======== * http://ckfinder.com * Copyright (C) 2007-2011, CKSource - Frederico Knabben. All rights reserved. * * The software, this file and its contents are subject to the CKFinder * License. Please read the license.txt file before using, installing, copying, * modifying or distribute ...
JavaScript
/* * CKFinder * ======== * http://ckfinder.com * Copyright (C) 2007-2011, CKSource - Frederico Knabben. All rights reserved. * * The software, this file and its contents are subject to the CKFinder * License. Please read the license.txt file before using, installing, copying, * modifying or distribute ...
JavaScript
/* * CKFinder * ======== * http://ckfinder.com * Copyright (C) 2007-2011, CKSource - Frederico Knabben. All rights reserved. * * The software, this file and its contents are subject to the CKFinder * License. Please read the license.txt file before using, installing, copying, * modifying or distribute ...
JavaScript
/* * CKFinder * ======== * http://ckfinder.com * Copyright (C) 2007-2011, CKSource - Frederico Knabben. All rights reserved. * * The software, this file and its contents are subject to the CKFinder * License. Please read the license.txt file before using, installing, copying, * modifying or distribute ...
JavaScript
/* * CKFinder * ======== * http://ckfinder.com * Copyright (C) 2007-2011, CKSource - Frederico Knabben. All rights reserved. * * The software, this file and its contents are subject to the CKFinder * License. Please read the license.txt file before using, installing, copying, * modifying or distribute ...
JavaScript
/* * CKFinder * ======== * http://ckfinder.com * Copyright (C) 2007-2011, CKSource - Frederico Knabben. All rights reserved. * * The software, this file and its contents are subject to the CKFinder * License. Please read the license.txt file before using, installing, copying, * modifying or distribute ...
JavaScript
/* * CKFinder * ======== * http://ckfinder.com * Copyright (C) 2007-2011, CKSource - Frederico Knabben. All rights reserved. * * The software, this file and its contents are subject to the CKFinder * License. Please read the license.txt file before using, installing, copying, * modifying or distribute ...
JavaScript
/* * CKFinder * ======== * http://ckfinder.com * Copyright (C) 2007-2011, CKSource - Frederico Knabben. All rights reserved. * * The software, this file and its contents are subject to the CKFinder * License. Please read the license.txt file before using, installing, copying, * modifying or distribute ...
JavaScript
/* * CKFinder * ======== * http://ckfinder.com * Copyright (C) 2007-2011, CKSource - Frederico Knabben. All rights reserved. * * The software, this file and its contents are subject to the CKFinder * License. Please read the license.txt file before using, installing, copying, * modifying or distribute ...
JavaScript
/* * CKFinder * ======== * http://ckfinder.com * Copyright (C) 2007-2011, CKSource - Frederico Knabben. All rights reserved. * * The software, this file and its contents are subject to the CKFinder * License. Please read the license.txt file before using, installing, copying, * modifying or distribute ...
JavaScript
/* * CKFinder * ======== * http://ckfinder.com * Copyright (C) 2007-2011, CKSource - Frederico Knabben. All rights reserved. * * The software, this file and its contents are subject to the CKFinder * License. Please read the license.txt file before using, installing, copying, * modifying or distribute ...
JavaScript
/* * CKFinder * ======== * http://ckfinder.com * Copyright (C) 2007-2011, CKSource - Frederico Knabben. All rights reserved. * * The software, this file and its contents are subject to the CKFinder * License. Please read the license.txt file before using, installing, copying, * modifying or distribute ...
JavaScript
/* * CKFinder * ======== * http://ckfinder.com * Copyright (C) 2007-2011, CKSource - Frederico Knabben. All rights reserved. * * The software, this file and its contents are subject to the CKFinder * License. Please read the license.txt file before using, installing, copying, * modifying or distribute ...
JavaScript
/* * CKFinder * ======== * http://ckfinder.com * Copyright (C) 2007-2011, CKSource - Frederico Knabben. All rights reserved. * * The software, this file and its contents are subject to the CKFinder * License. Please read the license.txt file before using, installing, copying, * modifying or distribute ...
JavaScript
/* * CKFinder * ======== * http://ckfinder.com * Copyright (C) 2007-2011, CKSource - Frederico Knabben. All rights reserved. * * The software, this file and its contents are subject to the CKFinder * License. Please read the license.txt file before using, installing, copying, * modifying or distribute ...
JavaScript
/* * CKFinder * ======== * http://ckfinder.com * Copyright (C) 2007-2011, CKSource - Frederico Knabben. All rights reserved. * * The software, this file and its contents are subject to the CKFinder * License. Please read the license.txt file before using, installing, copying, * modifying or distribute ...
JavaScript
/* * CKFinder * ======== * http://ckfinder.com * Copyright (C) 2007-2011, CKSource - Frederico Knabben. All rights reserved. * * The software, this file and its contents are subject to the CKFinder * License. Please read the license.txt file before using, installing, copying, * modifying or distribute ...
JavaScript
/* * CKFinder * ======== * http://ckfinder.com * Copyright (C) 2007-2011, CKSource - Frederico Knabben. All rights reserved. * * The software, this file and its contents are subject to the CKFinder * License. Please read the license.txt file before using, installing, copying, * modifying or distribute ...
JavaScript
/* * CKFinder * ======== * http://ckfinder.com * Copyright (C) 2007-2011, CKSource - Frederico Knabben. All rights reserved. * * The software, this file and its contents are subject to the CKFinder * License. Please read the license.txt file before using, installing, copying, * modifying or distribute ...
JavaScript
/* * CKFinder * ======== * http://ckfinder.com * Copyright (C) 2007-2011, CKSource - Frederico Knabben. All rights reserved. * * The software, this file and its contents are subject to the CKFinder * License. Please read the license.txt file before using, installing, copying, * modifying or distribute ...
JavaScript
CKEDITOR.on( 'dialogDefinition', function( ev ) { var dialogName = ev.data.name; var dialogDefinition = ev.data.definition; if ( dialogName == 'uicolor' ) { // Get a reference to the configBox and hide it (cannot be removed). var configBox = dialogDefinition.getContents( 'tab1' ).get( 'configBox' ); ...
JavaScript
// $Id: ckeditor.utils.js,v 1.1.2.11 2010/03/06 11:04:38 mephir Exp $ Drupal.ckeditor = (typeof(CKEDITOR) != 'undefined'); // this object will store teaser information Drupal.ckeditorTeaser = { lookup: {}, lookupSetup: false, cache: {} }; Drupal.ckeditorToggle = function(textarea_id, TextTextarea, TextRTE, xss_...
JavaScript
// $Id: image_captcha.js,v 1.1 2009/06/21 16:01:53 soxofaan Exp $ $(document).ready(function(){ // Helper function to show/hide noise level widget. var noise_level_shower = function(speed) { speed = (typeof speed == 'undefined') ? 'slow' : speed; if ($("#edit-image-captcha-dot-noise").is(":checked") || $("#edit...
JavaScript
// $Id: captcha.js,v 1.2 2010/02/20 10:07:39 soxofaan Exp $ // TODO: change this to Drupal.behaviors.captchaadmin = function (context) {} $(document).ready(function(){ // Add onclick handler to checkbox for adding a CAPTCHA description // so that the textfields for the CAPTCHA description are hidden // when no des...
JavaScript
function alert1(var1) { alert("You clicked me!"); document.getElementById('edit-body').value = var1; document.getElementById('xEditingArea body').value = var1; document.body.innerHTML = 'block' ; oEditor.FCK.InsertHtml( $var1 ) ; }
JavaScript
// $Id: googleanalytics.js,v 1.9.2.8 2011/02/05 19:53:32 hass Exp $ $(document).ready(function() { // Attach onclick event to document only and catch clicks on all elements. $(document.body).click(function(event) { // Catch only the first parent link of a clicked element. $(event.target).parents("a:first,...
JavaScript
// $Id: better_formats_node_type_form.js,v 1.4.2.3 2009/05/31 17:53:41 dragonwize Exp $ /** * @file * Enhances the default format selection on content type edit forms. * * Fixes bug that shows weight field when drag and drop is enabled * because the field is hidden by default. * Also hides formats that are not a...
JavaScript
// $Id: hideForm.js,v 1.2.2.1.2.6.2.2 2009/07/29 08:30:54 mh86 Exp $ /** * @file shows / hides form elements */ Drupal.behaviors.TaxonomyManagerHideForm = function(context) { var settings = Drupal.settings.hideForm || []; if (settings['div']) { if (!$('#taxonomy-manager-toolbar' + '.tm-hideForm-processed')...
JavaScript
// $Id: tree.js,v 1.4.2.4.2.9.2.13 2009/08/10 13:47:45 mh86 Exp $ /** * @files js for collapsible tree view with some helper functions for updating tree structure */ Drupal.behaviors.TaxonomyManagerTree = function(context) { var settings = Drupal.settings.taxonomytree || []; var id, vid; if (settings['id']) {...
JavaScript
/** * Double Tree Object */ Drupal.DoubleTree = function(tree1, tree2) { this.leftTree = tree1; this.rightTree = tree2; this.selected_terms = new Array(); this.selected_parents = new Array(); this.direction = "left-to-right"; this.updateWholeTree = false; this.url = Drupal.settings.DoubleTree['url']; ...
JavaScript
// $Id: updateWeight.js,v 1.2.2.1.2.7.2.2 2009/07/30 13:30:27 mh86 Exp $ /** * @file js for changing weights of terms with Up and Down arrows */ //object to store weights (tid => weight) var weights = new Object(); Drupal.behaviors.TaxonomyManagerWeights = function(context) { var settings = Drupal.settings.updat...
JavaScript
// $Id: termData.js,v 1.1.2.3.2.8.2.13 2010/01/30 16:37:29 mh86 Exp $ /** * @file js support for term editing form for ajax saving and tree updating */ //global var that holds the current term link object var active_term = new Object(); //holds tree objects, useful in double tree interface, when both trees needs t...
JavaScript
/** * CSV Export * * adds click event to export button and makes AJAX call to get the CSV data */ Drupal.behaviors.TaxonomyManagerCSVExport = function(context) { if (!$('#taxonomy-manager-toolbar' + '.tm-csv-processed').size()) { $('#taxonomy-manager-toolbar').addClass('tm-csv-processed'); var url = ...
JavaScript
// $Id: pathauto.js,v 1.4.2.2 2010/02/10 21:50:30 greggles Exp $ 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","disab...
JavaScript
// $Id: dhtml_menu.js,v 1.18.2.10 2009/01/12 10:13:30 arancaytar Exp $ /** * @file dhtml_menu.js * The Javascript code for DHTML Menu */ Drupal.dhtmlMenu = {}; /** * Initialize the module's JS functions */ Drupal.behaviors.dhtmlMenu = function() { // Do not run this function more than once. if (Drupal.dhtm...
JavaScript
// $Id: date_popup.js,v 1.1.2.4 2010/11/20 12:03:36 karens Exp $ /** * 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)...
JavaScript
// $Id: date_timezone.js,v 1.1.4.2.2.1 2008/06/20 12:25:30 karens Exp $ /** * 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 in...
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
(function($) { //Make nodes selectable by expression $.extend($.expr[':'], { draggable: "(' '+a.className+' ').indexOf(' ui-draggable ')" }); //Macros for external methods that support chaining var methods = "destroy,enable,disable".split(","); for(var i=0;i<methods.length;i++) { var cur = methods[i]...
JavaScript
(function($) { //If the UI scope is not availalable, add it $.ui = $.ui || {}; //Add methods that are vital for all mouse interaction stuff (plugin registering) $.extend($.ui, { plugin: { add: function(w, c, o, p) { var a = $.ui[w].prototype; if(!a.plugins[c]) a.plugins[c] = []; a.plugins...
JavaScript
/** * JavaScript routines for Krumo * * @version $Id: krumo.js,v 1.1.2.2 2008/06/03 20:36:03 weitzman Exp $ * @link http://sourceforge.net/projects/krumo */ ///////////////////////////////////////////////////////////////////////////// /** * Krumo JS Class */ function krumo() { } // -- -- -- -- -- -- ...
JavaScript
/*----------------------------------------\ | Cross Browser Tree Widget 1.1 | |-----------------------------------------| | Created by Emil A. Eklund (eae@eae.net) | | For WebFX (http://webfx.eae.net/) | |-----------------------------------------| | This script is provided as is without | | any...
JavaScript
function pickstyle(whichstyle) { var expireDate = new Date() var expstring=expireDate.setDate(expireDate.getDate()+30) document.cookie = "litejazzstyle=" + whichstyle + "; expires="+expireDate.toGMTString() }
JavaScript
sfHover = function() { var sfEls = document.getElementById("suckerfishmenu").getElementsByTagName("LI"); for (var i=0; i<sfEls.length; i++) { sfEls[i].onmouseover=function() { this.className+=" sfhover"; } sfEls[i].onmouseout=function() { this.className=this.className.replace(new RegExp(" sfhover\\b"), ""...
JavaScript
/** * -------------------------------------------------------------------- * jQuery-Plugin "pngFix" * by Andreas Eberhard, andreas.eberhard@gmail.com * http://jquery.andreaseberhard.de/ * * Copyright (c) 2007 Andreas Eberhard * Licensed under GPL (http://www.opensource.org/licenses/gpl-licen...
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
(function($){ /* hoverIntent by Brian Cherne */ $.fn.hoverIntent = function(f,g) { // default configuration options var cfg = { sensitivity: 7, interval: 100, timeout: 0 }; // override configuration options with user supplied object cfg = $.extend(cfg, g ? { over: f, out: g } : f ); // instantia...
JavaScript
// $Id Drupal.behaviors.skyBehavior = function(context) { /** * Superfish Menus * http://users.tpg.com.au/j_birch/plugins/superfish/ * @see js/superfish.js */ jQuery('#navigation ul').superfish({ animation: { opacity: 'show', height:'show' }, easing: 'swing', speed: 250, autoArrows: fa...
JavaScript
// $Id: taxonomy.js,v 1.2 2007/12/16 10:36:53 goba Exp $ /** * Move a block in the blocks table from one region to another via select list. * * This behavior is dependent on the tableDrag behavior, since it uses the * objects initialized in that behavior to update the row. */ Drupal.behaviors.termDrag = function(...
JavaScript
// $Id: user.js,v 1.6 2007/09/12 18:29:32 goba Exp $ /** * Attach handlers to evaluate the strength of any password fields and to check * that its confirmation is correct. */ Drupal.behaviors.password = function(context) { var translate = Drupal.settings.password; $("input.password-field:not(.password-processed...
JavaScript
// $Id: comment.js,v 1.5 2007/09/12 18:29:32 goba Exp $ Drupal.behaviors.comment = function (context) { var parts = new Array("name", "homepage", "mail"); var cookie = ''; for (i=0;i<3;i++) { cookie = Drupal.comment.getCookie('comment_info_' + parts[i]); if (cookie != '') { $("#comment-form input[n...
JavaScript
// $Id: openid.js,v 1.6 2008/01/30 22:11:22 goba Exp $ Drupal.behaviors.openid = function (context) { var $loginElements = $("#edit-name-wrapper, #edit-pass-wrapper, li.openid-link"); var $openidElements = $("#edit-openid-identifier-wrapper, li.user-link"); // This behavior attaches by ID, so is only valid once...
JavaScript
// $Id: system.js,v 1.14.2.2 2009/07/21 08:59:12 goba Exp $ /** * Internal function to check using Ajax if clean URLs can be enabled on the * settings page. * * This function is not used to verify whether or not clean URLs * are currently enabled. */ Drupal.behaviors.cleanURLsSettingsCheck = function(context) { ...
JavaScript
// $Id: profile.js,v 1.2 2007/12/08 14:06:22 goba Exp $ /** * Add functionality to the profile drag and drop table. * * This behavior is dependent on the tableDrag behavior, since it uses the * objects initialized in that behavior to update the row. It shows and hides * a warning message when removing the last fi...
JavaScript
// $Id: color.js,v 1.6 2007/09/12 18:29:32 goba Exp $ Drupal.behaviors.color = function (context) { // This behavior attaches by ID, so is only valid once on a page. if ($('#color_scheme_form .color-form.color-processed').size()) { return; } var form = $('#color_scheme_form .color-form', context); var in...
JavaScript
// $Id: block.js,v 1.2 2007/12/16 10:36:53 goba Exp $ /** * Move a block in the blocks table from one region to another via select list. * * This behavior is dependent on the tableDrag behavior, since it uses the * objects initialized in that behavior to update the row. */ Drupal.behaviors.blockDrag = function(co...
JavaScript
// $Id: tableheader.js,v 1.16.2.2 2009/03/30 12:48:09 goba Exp $ Drupal.tableHeaderDoScroll = function() { if (typeof(Drupal.tableHeaderOnScroll)=='function') { Drupal.tableHeaderOnScroll(); } }; Drupal.behaviors.tableHeader = function (context) { // This breaks in anything less than IE 7. Prevent it from r...
JavaScript
// $Id: tabledrag.js,v 1.13.2.5 2009/06/18 12:24:24 goba Exp $ /** * Drag and drop table rows with field manipulation. * * Using the drupal_add_tabledrag() function, any table with weights or parent * relationships may be made into draggable tables. Columns containing a field * may optionally be hidden, providing...
JavaScript
// $Id: textarea.js,v 1.22 2008/01/17 19:31:56 goba Exp $ Drupal.behaviors.textarea = function(context) { $('textarea.resizable:not(.textarea-processed)', context).each(function() { // Avoid non-processed teasers. if ($(this).is(('textarea.teaser:not(.teaser-processed)'))) { return false; } v...
JavaScript
// $Id: collapse.js,v 1.17 2008/01/29 10:58:25 goba Exp $ /** * Toggle the visibility of a fieldset using smooth animations */ Drupal.toggleFieldset = function(fieldset) { if ($(fieldset).is('.collapsed')) { // Action div containers are processed separately because of a IE bug // that alters the default su...
JavaScript
// $Id: teaser.js,v 1.12.2.2 2010/03/01 10:13:18 goba Exp $ /** * Auto-attach for teaser behavior. * * Note: depends on resizable textareas. */ Drupal.behaviors.teaser = function(context) { // This breaks in Konqueror. Prevent it from running. if (/KDE/.test(navigator.vendor)) { return; } $('textarea....
JavaScript
// $Id: batch.js,v 1.4 2007/10/21 18:59:01 goba Exp $ /** * Attaches the batch behavior to progress bars. */ Drupal.behaviors.batch = function (context) { // This behavior attaches by ID, so is only valid once on a page. if ($('#progress.batch-processed').size()) { return; } $('#progress', context).addCl...
JavaScript
// $Id: farbtastic.js,v 1.4.2.1 2008/06/25 09:34:17 goba Exp $ // Farbtastic 1.2 jQuery.fn.farbtastic = function (callback) { $.farbtastic(this, callback); return this; }; jQuery.farbtastic = function (container, callback) { var container = $(container).get(0); return container.farbtastic || (container.farbta...
JavaScript
// $Id: ahah.js,v 1.7.2.1 2008/02/11 14:46:27 goba Exp $ /** * Provides AJAX-like page updating via AHAH (Asynchronous HTML and HTTP). * * AHAH is a method of making a request via Javascript while viewing an HTML * page. The request returns a small chunk of HTML, which is then directly * injected into the page. ...
JavaScript
// $Id: form.js,v 1.1 2007/09/12 18:29:32 goba Exp $ Drupal.behaviors.multiselectSelector = function() { // Automatically selects the right radio button in a multiselect control. $('.multiselect select:not(.multiselectSelector-processed)') .addClass('multiselectSelector-processed').change(function() { $(...
JavaScript
// $Id: drupal.js,v 1.41.2.4 2009/07/21 08:59:10 goba Exp $ var Drupal = Drupal || { 'settings': {}, 'behaviors': {}, 'themes': {}, 'locale': {} }; /** * Set the variable that indicates if JavaScript behaviors should be applied */ Drupal.jsEnabled = document.getElementsByTagName && document.createElement && documen...
JavaScript