code
stringlengths
1
2.08M
language
stringclasses
1 value
//Source: http://www.overset.com/2008/04/11/mark-gibsons-json-jquery-updated/ (function($) { m = { '\b': '\\b', '\t': '\\t', '\n': '\\n', '\f': '\\f', '\r': '\\r', '"': '\\"', '\\': '\\\\' }, $.toJSON = function(value, whitelist) { var a...
JavaScript
/* * jQuery Form Plugin * version: 2.36 (07-NOV-2009) * @requires jQuery v1.2.6 or later * * Examples and documentation at: http://malsup.com/jquery/form/ * Dual licensed under the MIT and GPL licenses: * http://www.opensource.org/licenses/mit-license.php * http://www.gnu.org/licenses/gpl.html */ ;(functio...
JavaScript
/** * Cookie plugin * * Copyright (c) 2006 Klaus Hartl (stilbuero.de) * Dual licensed under the MIT and GPL licenses: * http://www.opensource.org/licenses/mit-license.php * http://www.gnu.org/licenses/gpl.html * */ /** * Create a cookie with the given name and value and other optional parameters. ...
JavaScript
//Source: http://www.overset.com/2008/04/11/mark-gibsons-json-jquery-updated/ (function($) { m = { '\b': '\\b', '\t': '\\t', '\n': '\\n', '\f': '\\f', '\r': '\\r', '"': '\\"', '\\': '\\\\' }, $.toJSON = function(value, whitelist) { var a...
JavaScript
/* * jQuery Form Plugin * version: 2.36 (07-NOV-2009) * @requires jQuery v1.2.6 or later * * Examples and documentation at: http://malsup.com/jquery/form/ * Dual licensed under the MIT and GPL licenses: * http://www.opensource.org/licenses/mit-license.php * http://www.gnu.org/licenses/gpl.html */ ;(functio...
JavaScript
/** * Cookie plugin * * Copyright (c) 2006 Klaus Hartl (stilbuero.de) * Dual licensed under the MIT and GPL licenses: * http://www.opensource.org/licenses/mit-license.php * http://www.gnu.org/licenses/gpl.html * */ /** * Create a cookie with the given name and value and other optional parameters. ...
JavaScript
/** * Blogger Tabbed Style Table of Content Widget by Taufik Nurrohman * Free for change but keep the original attribution. * URL: https://plus.google.com/108949996304093815163/about * TEMPLATES: <div id="tabbed-toc"><span class="loading">Loading...</span></div><script type="text/java...
JavaScript
/** * Blogger Tabbed Style Table of Content Widget by Taufik Nurrohman * Free for change but keep the original attribution. * URL: https://plus.google.com/108949996304093815163/about * TEMPLATES: <div id="tabbed-toc"><span class="loading">Loading...</span></div><script type="text/java...
JavaScript
/*global jQuery, $ */ /* jQuery.PictureSlides is developed by Robert Nyman, http://www.robertnyman.com For more information, please see http://www.robertnyman.com/picture-slides Released under a MIT License */ jQuery.PictureSlides = function () { var useMSFilter = false, slideshows = [], set = function (setting...
JavaScript
 /** * @license Copyright (c) 2003-2013, CKSource - Frederico Knabben. All rights reserved. * For licensing, see LICENSE.html or http://ckeditor.com/license */ /** * This file was added automatically by CKEditor builder. * You may re-use it at any time at http://ckeditor.com/builder to build CKEditor aga...
JavaScript
/** * @license Copyright (c) 2003-2013, CKSource - Frederico Knabben. All rights reserved. * For licensing, see LICENSE.html or http://ckeditor.com/license */ CKEDITOR.editorConfig = function( config ) { // Define changes to default configuration here. For example: // config.language = 'fr'; // config.uiColor = ...
JavaScript
/* Copyright (c) 2003-2013, CKSource - Frederico Knabben. All rights reserved. For licensing, see LICENSE.md or http://ckeditor.com/license */
JavaScript
/** * Copyright (c) 2003-2013, CKSource - Frederico Knabben. All rights reserved. * For licensing, see LICENSE.md or http://ckeditor.com/license */ // This file contains style definitions that can be used by CKEditor plugins. // // The most common use for it is the "stylescombo" plugin, which shows a combo ...
JavaScript
/** * Copyright (c) 2003-2013, CKSource - Frederico Knabben. All rights reserved. * For licensing, see LICENSE.md or http://ckeditor.com/license */ CKEDITOR.dialog.add( 'myDialog', function( editor ) { return { title: 'My Dialog', minWidth: 400, minHeight: 200, contents: [ { id: 'tab1',...
JavaScript
/** * Copyright (c) 2003-2013, CKSource - Frederico Knabben. All rights reserved. * For licensing, see LICENSE.md or http://ckeditor.com/license */ // Tool scripts for the sample pages. // This file can be ignored and is not required to make use of CKEditor. (function() { CKEDITOR.on( 'instanceReady', f...
JavaScript
// JavaScript Document $(function () { var d = [[1201647600000, 1521], [1201734000000, 1477], [1201820400000, 1442], [1201906800000, 1252], [1201993200000, 1236], [1202079600000, 1525], [1202166000000, 1477], [1202252400000, 1386], [1202338800000, 1409], [1202425200000, 1408], [1202511600000, 1237], [120259800000...
JavaScript
/* * jQuery UI 1.7.2 * * Copyright (c) 2009 AUTHORS.txt (http://jqueryui.com/about) * Dual licensed under the MIT (MIT-LICENSE.txt) * and GPL (GPL-LICENSE.txt) licenses. * * http://docs.jquery.com/UI */ ;jQuery.ui || (function($) { var _remove = $.fn.remove, isFF2 = $.browser.mozilla && (parseFloa...
JavaScript
/* * jQuery UI Dialog 1.7.2 * * Copyright (c) 2009 AUTHORS.txt (http://jqueryui.com/about) * Dual licensed under the MIT (MIT-LICENSE.txt) * and GPL (GPL-LICENSE.txt) licenses. * * http://docs.jquery.com/UI/Dialog * * Depends: * ui.core.js * ui.draggable.js * ui.resizable.js */ (function($) {...
JavaScript
/* * jQuery UI Sortable 1.7.2 * * Copyright (c) 2009 AUTHORS.txt (http://jqueryui.com/about) * Dual licensed under the MIT (MIT-LICENSE.txt) * and GPL (GPL-LICENSE.txt) licenses. * * http://docs.jquery.com/UI/Sortables * * Depends: * ui.core.js */ (function($) { $.widget("ui.sortable", $.exten...
JavaScript
/* jQuery Blend v1.1 (c) 2009 Jack Moore - www.colorpowered.com - jack@colorpowered.com Licensed under the MIT license: http://www.opensource.org/licenses/mit-license.php */ (function($){ /* Blend creates a 2nd layer on top of the target element. This layer is faded in and out to create t...
JavaScript
/* * jQuery UI Datepicker 1.7.1 * * Copyright (c) 2009 AUTHORS.txt (http://jqueryui.com/about) * Dual licensed under the MIT (MIT-LICENSE.txt) * and GPL (GPL-LICENSE.txt) licenses. * * http://docs.jquery.com/UI/Datepicker * * Depends: * ui.core.js */ (function($) { // hide the namespace $.ex...
JavaScript
/** * WYSIWYG - jQuery plugin 0.5 * * Copyright (c) 2008-2009 Juan M Martinez * http://plugins.jquery.com/project/jWYSIWYG * * Dual licensed under the MIT and GPL licenses: * http://www.opensource.org/licenses/mit-license.php * http://www.gnu.org/licenses/gpl.html * * $Id: $ */ (function( $ )...
JavaScript
/* Javascript plotting library for jQuery, v. 0.5. * * Released under the MIT license by IOLA, December 2007. * */ (function($) { function Plot(target, data_, options_, plugins) { // data is on the form: // [ series1, series2 ... ] // where series is either just the data as ...
JavaScript
/*************************************************! * * project: liteAccordion - a horizontal accordion plugin for jQuery * author: Nicola Hibbert * url: http://nicolahibbert.com/liteaccordion-v2/ * demo: http://www.nicolahibbert.com/demo/liteAccordion/ * * Version: 2.2.0 * Copyright:...
JavaScript
/* * jQuery Easing v1.3 - http://gsgd.co.uk/sandbox/jquery/easing/ * * Uses the built in easing capabilities added In jQuery 1.1 * to offer multiple easing options * * TERMS OF USE - jQuery Easing * * Open source under the BSD License. * * Copyright © 2008 George McGinley Smith * All rights reserved. * ...
JavaScript
/*==================================== Free To Use For Personal And Commercial Usage Author: http://binarytheme.com Share Us if You Like our work Enjoy Our Codes For Free always. ======================================*/ $(function () { // tooltip demo $('.tooltip-demo').tooltip({ select...
JavaScript
/*global jQuery, $ */ /* jQuery.PictureSlides is developed by Robert Nyman, http://www.robertnyman.com For more information, please see http://www.robertnyman.com/picture-slides Released under a MIT License */ jQuery.PictureSlides = function () { var useMSFilter = false, slideshows = [], set = function (setting...
JavaScript
/* ========================================= URI: https://github.com/onokumus/metisMenu =======================================*/ ; (function ($, window, document, undefined) { var pluginName = "metisMenu", defaults = { toggle: true }; function Plugin(element, options) { ...
JavaScript
(function() { var AjaxMonitor, Bar, DocumentMonitor, ElementMonitor, ElementTracker, EventLagMonitor, Evented, Events, NoTargetError, RequestIntercept, SOURCE_KEYS, Scaler, SocketRequestTracker, XHRRequestTracker, animation, avgAmplitude, bar, cancelAnimation, cancelAnimationFrame, defaultOptions, extend, extendNativ...
JavaScript
/** * @license Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. * For licensing, see LICENSE.md or http://ckeditor.com/license */ /** * This file was added automatically by CKEditor builder. * You may re-use it at any time to build CKEditor again. * * If you would like to bu...
JavaScript
/* Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. For licensing, see LICENSE.md or http://ckeditor.com/license */
JavaScript
/** * @license Copyright (c) 2003-2013, CKSource - Frederico Knabben. All rights reserved. * For licensing, see LICENSE.html or http://ckeditor.com/license * http://docs.cksource.com/ckeditor_api/symbols/CKEDITOR.config.html#.autoParagraph * http://docs.ckeditor.com/#!/guide/dev_allowed_content_rules */ CKEDITOR.e...
JavaScript
/** * Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. * For licensing, see LICENSE.md or http://ckeditor.com/license */ CKEDITOR.dialog.add( 'myDialog', function( editor ) { return { title: 'My Dialog', minWidth: 400, minHeight: 200, contents: [ { id: 'tab1',...
JavaScript
/** * Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. * For licensing, see LICENSE.md or http://ckeditor.com/license */ // Tool scripts for the sample pages. // This file can be ignored and is not required to make use of CKEditor. ( function() { CKEDITOR.on( 'instanceReady', ...
JavaScript
/** * Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved. * For licensing, see LICENSE.md or http://ckeditor.com/license */ // This file contains style definitions that can be used by CKEditor plugins. // // The most common use for it is the "stylescombo" plugin, which shows a combo ...
JavaScript
/** * CHANGES MADE BY YII DEVELOPERS, READ CAREFULLY BEFORE UPGRADING THIS FILE: * 1. This commit has been used: * https://github.com/jquerytools/jquerytools/commit/4f3f3f14e83b0ff276a795e9f45400930904adff#src/tooltip/tooltip.js * 2. Original `$.fn.tooltip` has been changed to `$.fn.tooltip2` to prevent conflict be...
JavaScript
$(document).ready(function() { if($('div.form.login').length) { // in login page $('input#LoginForm_password').focus(); } $('table.preview input[name="checkAll"]').click(function() { $('table.preview .confirm input').prop('checked', this.checked); }); $('table.preview td.confirm input').click(function() { ...
JavaScript
jQuery(window).bind('scroll', function (){ if (jQuery(window).scrollTop() > 500){ jQuery('#main-menu').addClass('navbar-small').removeClass('topnavbar').slideDown(500); jQuery('#page-top').addClass('bodytopmargin').removeClass('bodynomargin'); } else { jQuery('#main-menu').removeClass('navbar-small...
JavaScript
(function(root, factory) { if(typeof exports === 'object') { module.exports = factory(); } else if(typeof define === 'function' && define.amd) { define('GMaps', [], factory); } root.GMaps = factory(); }(this, function() { /*! * GMaps.js v0.4.11 * http://hpneo.github.com/gmaps/ * ...
JavaScript
/*global jQuery */ /*jshint browser:true */ /*! * FitVids 1.1 * * Copyright 2013, Chris Coyier - http://css-tricks.com + Dave Rupert - http://daverupert.com * Credit to Thierry Koblentz - http://www.alistapart.com/articles/creating-intrinsic-ratios-for-video/ * Released under the WTFPL license - http://sam.zoy.org/wtfp...
JavaScript
/** * jQuery Yii ListView plugin file. * * @author Qiang Xue <qiang.xue@gmail.com> * @link http://www.yiiframework.com/ * @copyright 2008-2010 Yii Software LLC * @license http://www.yiiframework.com/license/ */ ;(function($) { var yiiXHR = {}; /** * yiiListView set function. * @param options map settings ...
JavaScript
/** * jQuery Yii GridView plugin file. * * @author Qiang Xue <qiang.xue@gmail.com> * @link http://www.yiiframework.com/ * @copyright 2008-2010 Yii Software LLC * @license http://www.yiiframework.com/license/ */ (function ($) { var selectCheckedRows, methods, yiiXHR={}, gridSettings = []; /** * 1. Sele...
JavaScript
(function() { $(document).ready = function() {}; $.extend(true, $.fn.dataTable.defaults, { sDom: "<'row-fluid'<'span6'l><'span6'f>r>t<'row-fluid'<'span6'i><'span6'p>>", sPaginationType: "bootstrap", oLanguage: { sLengthMenu: "_MENU_ records per page" } }); $...
JavaScript
/** * @license Copyright (c) 2003-2013, CKSource - Frederico Knabben. All rights reserved. * For licensing, see LICENSE.html or http://ckeditor.com/license */ CKEDITOR.editorConfig = function( config ) { // Define changes to default configuration here. For example: // config.language = 'fr'; // config.uiColor = ...
JavaScript
/** * Copyright (c) 2003-2013, CKSource - Frederico Knabben. All rights reserved. * For licensing, see LICENSE.html or http://ckeditor.com/license */ // This file contains style definitions that can be used by CKEditor plugins. // // The most common use for it is the "stylescombo" plugin, which shows a combo // in ...
JavaScript
/*! * jQuery Validation Plugin 1.12.0pre * * http://bassistance.de/jquery-plugins/jquery-plugin-validation/ * http://docs.jquery.com/Plugins/Validation * * Copyright 2013 Jörn Zaefferer * Released under the MIT license: * http://www.opensource.org/licenses/mit-license.php */ (function() { function str...
JavaScript
/* * File: jquery.dataTables.columnFilter.js * Version: 0.9.0 * Author: Jovan Popovic * * Copyright 2011 Jovan Popovic, all rights reserved. * * This source file is free software, under either the GPL v2 license or a * BSD style license, as supplied with this software. * * This source file is ...
JavaScript
/* * Fuel UX Wizard * https://github.com/ExactTarget/fuelux * * Copyright (c) 2012 ExactTarget * Licensed under the MIT license. */ (function($ , undefined) { // WIZARD CONSTRUCTOR AND PROTOTYPE var Wizard = function (element, options) { var kids; this.$element = $(element); th...
JavaScript
/** * Timeago is a jQuery plugin that makes it easy to support automatically * updating fuzzy timestamps (e.g. "4 minutes ago" or "about 1 day ago"). * * @name timeago * @version 1.2.0 * @requires jQuery v1.2.3+ * @author Ryan McGeary * @license MIT License - http://www.opensource.org/licenses/mit-license.php ...
JavaScript
/*! * Nestable jQuery Plugin - Copyright (c) 2012 David Bushell - http://dbushell.com/ * Dual-licensed under the BSD or MIT licenses */ ;(function($, window, document, undefined) { var hasTouch = 'ontouchstart' in window; /** * Detect CSS pointer-events property * events are normally disabled on t...
JavaScript
/* * Character Count Plugin - jQuery plugin * Dynamic character count for text areas and input fields * written by Alen Grakalic * http://cssglobe.com/post/7161/jquery-plugin-simplest-twitterlike-dynamic-character-count-for-textareas * * Copyright (c) 2009 Alen Grakalic (http://cssglobe.com) * Dual licensed un...
JavaScript
(function ($) { "use strict"; var Wysihtml5 = function (options) { this.init('wysihtml5', options, Wysihtml5.defaults); //extend wysihtml5 manually as $.extend not recursive this.options.wysihtml5 = $.extend({}, Wysihtml5.defaults.wysihtml5, options.wysihtml5); }; $.fn.editabl...
JavaScript
/* Flot plugin for rendering pie charts. The plugin assumes the data is coming is as a single data value for each series, and each of those values is a positive value or zero (negative numbers don't make any sense and will cause strange effects). The data values do NOT need to be passed in as percentage values beca...
JavaScript
/* Flot plugin for automatically redrawing plots when the placeholder size changes, e.g. on window resizes. It works by listening for changes on the placeholder div (through the jQuery resize event plugin) - if the size changes, it will redraw the plot. There are no options. If you need to disable the plugin for some...
JavaScript
(function() { $(document).ready(function() { setScrollable(); setTimeAgo(); setAutoSize(); setCharCounter(); setMaxLength(); setValidateForm(); setSortable($(".sortable")); setSelect2(); $(".datetimepicker").datetimepicker(); $(".datepi...
JavaScript
$(function(){ $.mockjaxSettings.responseTime = 500; $.mockjax({ url: '/post', response: function(settings) { log(settings, this); } }); $.mockjax({ url: '/error', status: 400, statusText: 'Bad Request', response: function(settings) { ...
JavaScript
/*! * MockJax - jQuery Plugin to Mock Ajax requests * * Version: 1.5.0pre * Released: * Home: http://github.com/appendto/jquery-mockjax * Author: Jonathan Sharp (http://jdsharp.com) * License: MIT,GPL * * Copyright (c) 2011 appendTo LLC. * Dual licensed under the MIT or GPL licenses. * http://appendto....
JavaScript
(function() { var data, dataset, gd, options, previousLabel, previousPoint, showTooltip, ticks; $(document).ready(function() { var blue, data, datareal, getRandomData, green, i, newOrders, options, orange, orders, placeholder, plot, purple, randNumber, randSmallerNumber, red, series, totalPoints, updat...
JavaScript
(function() { $(document).ready(function() { var calendarDate, d, m, select2icon, y; setTimeAgoExample(); $('#slider').sliderNav(); $("#new-event").live('submit', function(e) { var value; e.preventDefault(); value = $("#new-event-input").val(); ...
JavaScript
(function() { $(document).ready(function() { var body, content, nav, nav_closed_width, nav_open, nav_toggler; nav_toggler = $("header .toggle-nav"); nav = $("#main-nav"); content = $("#content"); body = $("body"); nav_closed_width = 50; nav_open = body.hasCla...
JavaScript
/** * jQuery Yii plugin file. * * @author Qiang Xue <qiang.xue@gmail.com> * @link http://www.yiiframework.com/ * @copyright 2008-2010 Yii Software LLC * @license http://www.yiiframework.com/license/ */ ;(function($) { $.yii = { version : '1.0', submitForm : function (element, url, params) { var f = $(elem...
JavaScript
/* ### jQuery Star Rating Plugin v4.11 - 2013-03-14 ### * Home: http://www.fyneworks.com/jquery/star-rating/ * Code: http://code.google.com/p/jquery-star-rating-plugin/ * * Licensed under http://en.wikipedia.org/wiki/MIT_License ### */ /*# AVOID COLLISIONS #*/ ;if(window.jQuery) (function($){ /*# AVOI...
JavaScript
/** * Ajax Queue Plugin * * Homepage: http://jquery.com/plugins/project/ajaxqueue * Documentation: http://docs.jquery.com/AjaxQueue */ /** <script> $(function(){ jQuery.ajaxQueue({ url: "test.php", success: function(html){ jQuery("ul").append(html); } }); jQuery.ajaxQueue({ url: "test.p...
JavaScript
/* * jQuery Autocomplete plugin 1.1 * * Modified for Yii Framework: * - Renamed "autocomplete" to "legacyautocomplete". * - Fixed IE8 problems (mario.ffranco). * * Copyright (c) 2009 Jörn Zaefferer * * Dual licensed under the MIT and GPL licenses: * http://www.opensource.org/licenses/mit-license.php * ht...
JavaScript
/*! * jQuery BBQ: Back Button & Query Library - v1.4pre - 1/15/2013 * http://benalman.com/projects/jquery-bbq-plugin/ * * Copyright (c) 2010-2013 "Cowboy" Ben Alman * Dual licensed under the MIT and GPL licenses. * http://benalman.com/about/license/ */ // Script: jQuery BBQ: Back Button & Query Library // // *...
JavaScript
/* * Metadata - jQuery plugin for parsing metadata from elements * * Copyright (c) 2006 John Resig, Yehuda Katz, J�örn Zaefferer, Paul McLanahan * * Dual licensed under the MIT and GPL licenses: * http://www.opensource.org/licenses/mit-license.php * http://www.gnu.org/licenses/gpl.html * * Revision: $Id: j...
JavaScript
/** * jQuery yiiactiveform plugin file. * * @author Qiang Xue <qiang.xue@gmail.com> * @link http://www.yiiframework.com/ * @copyright 2008-2010 Yii Software LLC * @license http://www.yiiframework.com/license/ * @since 1.1.1 */ (function ($) { /* * returns the value of the CActiveForm input field * perform...
JavaScript
/* * Treeview 1.5pre - jQuery plugin to hide and show branches of a tree * * http://bassistance.de/jquery-plugins/jquery-plugin-treeview/ * http://docs.jquery.com/Plugins/Treeview * * Copyright (c) 2007 Jörn Zaefferer * * Dual licensed under the MIT and GPL licenses: * http://www.opensource.org/licenses/mit-...
JavaScript
(function($) { var CLASSES = $.treeview.classes; var proxied = $.fn.treeview; $.fn.treeview = function(settings) { settings = $.extend({}, settings); if (settings.add) { return this.trigger("add", [settings.add]); } if (settings.remove) { return this.trigger("remove", [settings.remove]); } return p...
JavaScript
/*! Copyright (c) 2010 Brandon Aaron (http://brandonaaron.net) * Licensed under the MIT License (LICENSE.txt). * * Version 2.1.2 */ (function($){ $.fn.bgiframe = ($.browser.msie && /msie 6\.0/i.test(navigator.userAgent) ? function(s) { s = $.extend({ top : 'auto', // auto == .currentStyle.borderTo...
JavaScript
/* * Async Treeview 0.1 - Lazy-loading extension for Treeview * * http://bassistance.de/jquery-plugins/jquery-plugin-treeview/ * * Copyright (c) 2007 Jörn Zaefferer * * Dual licensed under the MIT and GPL licenses: * http://www.opensource.org/licenses/mit-license.php * http://www.gnu.org/licenses/...
JavaScript
/** * jQuery Yii plugin file. * * @author Qiang Xue <qiang.xue@gmail.com> * @link http://www.yiiframework.com/ * @copyright 2008-2010 Yii Software LLC * @license http://www.yiiframework.com/license/ */ ;(function($) { $.extend($.fn, { yiitab: function() { function activate(id) { var pos = id.indexOf...
JavaScript
/** * Cookie plugin * * Copyright (c) 2006 Klaus Hartl (stilbuero.de) * Dual licensed under the MIT and GPL licenses: * http://www.opensource.org/licenses/mit-license.php * http://www.gnu.org/licenses/gpl.html * */ /** * Create a cookie with the given name and value and other optional parameters. * * @examp...
JavaScript
/* Masked Input plugin for jQuery Copyright (c) 2007-2013 Josh Bush (digitalbush.com) Licensed under the MIT license (http://digitalbush.com/projects/masked-input-plugin/#license) Version: 1.3.1 */ (function($) { function getPasteEvent() { var el = document.createElement('input'), name = 'onpaste'; ...
JavaScript
/*! http://mths.be/punycode v1.2.0 by @mathias */ ;(function(root) { /** * The `punycode` object. * @name punycode * @type Object */ var punycode, /** Detect free variables `define`, `exports`, `module` and `require` */ freeDefine = typeof define == 'function' && typeof define.amd == 'object' && define....
JavaScript
if (!Array.prototype.find) { Array.prototype.find = function (pFun) { for (var _i = 0; _i < this.length; _i++) { if (pFun(this[_i])) { return this[_i]; } } return null; }; } (function (window) { window.$A = {}; var A = wind...
JavaScript
(function (window) { var form = $A.Form.extend(0); form.imgs = { pig: "imgs/pig.png" }; var walls = [], pig; form.prototype.init = function () { var bodySize = this.body.size; var div = new $A.Div(null, 0, 0, bodySize[0], bodySize[1]); div.style.back...
JavaScript
(function (window) { var form = $A.Form.extend(0); form.prototype.init = function () { var _suf = new $A.Surface([500, 350]); $A.draw.line(_suf, "red", [0, 10], [300, 10], 1); $A.draw.lines(_suf, "blue", true, [[350, 10], [400, 10], [450, 60], [340, 80]], 2); $A.draw.c...
JavaScript
(function (window) { var form = $A.Form.extend(0); form.prototype.init = function () { var _label = new $A.Label(null, "Hello World, Amanda", 200, 150); this.body.append(_label); }; })(window);
JavaScript
(function (window) { var form = $A.Form.extend(0); form.prototype.init = function () { var _label = new $A.Label(null, "", 200, 150); this.body.append(_label); var _btn = new $A.Button(null, 220, 250); _btn.text = "Click"; _btn.addEvent("click", function (sr...
JavaScript
(function (window) { var form = $A.Form.extend(0); form.prototype.init = function () { var div_mouse_over_out = new $A.Div(null, 0, 0, 200, 100); div_mouse_over_out.style.backgroundColor = "black"; this.body.append(div_mouse_over_out); var lbl_mouse_over_out = new $A.L...
JavaScript
(function (window) { var form = $A.Form.extend(0); form.audios = { bk: "res/bk.ogg" }; var mixbk; form.prototype.init = function () { var btn = new $A.Button(null, 300, 300); btn.text = "Play"; btn.addEvent("click", function (srcEle) { v...
JavaScript
(function (window) { var form = $A.Form.extend(0); form.imgs = { square: "imgs/square.jpg", cartoon: "imgs/cartoon.png" }; var eleSquare; form.prototype.init = function () { var bodySize = this.body.size; var div = new $A.Div(null, 0, 0, bodySize[0], b...
JavaScript
(function (window) { var form = $A.Form.extend(0); form.imgs = { btn0: "imgs/btn0.png" }; form.prototype.init = function () { var bodySize = this.body.size; var div = new $A.Div(null, 0, 0, bodySize[0], bodySize[1]); div.style.backgroundColor = "#C0C0C0"; ...
JavaScript
(function (window) { var form = $A.Form.extend(1); form.imgs = { btn1: "imgs/btn1.png" }; form.prototype.init = function () { var bodySize = this.body.size; var div = new $A.Div(null, 0, 0, bodySize[0], bodySize[1]); div.style.backgroundColor = "#C0C0C0"; ...
JavaScript
/* Copyright (C) 2011 Google Inc. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, softwa...
JavaScript
(function(window) { var ORIGIN_ = location.protocol + '//' + location.host; function SlideController() { this.popup = null; this.isPopup = window.opener; if (this.setupDone()) { window.addEventListener('message', this.onMessage_.bind(this), false); // Close popups if we reload the main window. win...
JavaScript
/* * Hammer.JS * version 0.4 * author: Eight Media * https://github.com/EightMedia/hammer.js */ function Hammer(element, options, undefined) { var self = this; var defaults = { // prevent the default event or not... might be buggy when false prevent_default : false, css_hacks ...
JavaScript
/** * @authors TODO * @fileoverview TODO */ document.cancelFullScreen = document.webkitCancelFullScreen || document.mozCancelFullScreen; /** * @constructor */ function SlideDeck(el) { this.curSlide_ = 0; this.prevSlide_ = 0; this.config_ = null; this.container = el || document....
JavaScript
require(['order!../slide_config', 'order!modernizr.custom.45394', 'order!prettify/prettify', 'order!hammer', 'order!slide-controller', 'order!slide-deck'], function(someModule) { });
JavaScript
var SLIDE_CONFIG = { // Slide settings settings: { title: 'Building Web Applications that use Google APIs and the JavaScript Client for Google APIs', subtitle: '', useBuilds: true, // Default: true. False will turn off slide animation builds. usePrettify: true, // Default: true enableSlideAreas:...
JavaScript
/* * Copyright 2011 Google Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to ...
JavaScript
/* * jsTree 1.0-rc3 * http://jstree.com/ * * Copyright (c) 2010 Ivan Bozhanov (vakata.com) * * Licensed same as jquery - under the terms of either the MIT License or the GPL Version 2 License * http://www.opensource.org/licenses/mit-license.php * http://www.gnu.org/licenses/gpl.html * * $Date: 2...
JavaScript
/* * Copyright 2011 Google Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to ...
JavaScript
/* * Copyright 2011 Google Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to ...
JavaScript
/* * Copyright 2011 Google Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to ...
JavaScript
// Copyright 2012 Google Inc. All Rights Reserved. /* Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law o...
JavaScript
// Copyright 2012 Google Inc. All Rights Reserved. /* Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law o...
JavaScript
// Copyright 2012 Google Inc. All Rights Reserved. /* Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law o...
JavaScript
// Copyright 2012 Google Inc. All Rights Reserved. /* Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law o...
JavaScript