1
0
mirror of synced 2024-11-26 14:56:07 +03:00

Merge pull request #1789 from STAH/unused-vars

Remove unused var declarations
This commit is contained in:
Igor Vaynberg 2013-10-10 12:59:33 -07:00
commit f1807f2177

View File

@ -654,7 +654,7 @@ the specific language governing permissions and limitations under the Apache Lic
// abstract // abstract
init: function (opts) { init: function (opts) {
var results, search, resultsSelector = ".select2-results", disabled, readonly; var results, search, resultsSelector = ".select2-results";
// prepare options // prepare options
this.opts = opts = this.prepareOpts(opts); this.opts = opts = this.prepareOpts(opts);
@ -726,7 +726,7 @@ the specific language governing permissions and limitations under the Apache Lic
// if jquery.mousewheel plugin is installed we can prevent out-of-bounds scrolling of results via mousewheel // if jquery.mousewheel plugin is installed we can prevent out-of-bounds scrolling of results via mousewheel
if ($.fn.mousewheel) { if ($.fn.mousewheel) {
results.mousewheel(function (e, delta, deltaX, deltaY) { results.mousewheel(function (e, delta, deltaX, deltaY) {
var top = results.scrollTop(), height; var top = results.scrollTop();
if (deltaY > 0 && top - deltaY <= 0) { if (deltaY > 0 && top - deltaY <= 0) {
results.scrollTop(0); results.scrollTop(0);
killEvent(e); killEvent(e);
@ -852,7 +852,7 @@ the specific language governing permissions and limitations under the Apache Lic
opts = $.extend({}, { opts = $.extend({}, {
populateResults: function(container, results, query) { populateResults: function(container, results, query) {
var populate, data, result, children, id=this.opts.id; var populate, id=this.opts.id;
populate=function(results, container, depth) { populate=function(results, container, depth) {
@ -1009,8 +1009,6 @@ the specific language governing permissions and limitations under the Apache Lic
sync = this.bind(function () { sync = this.bind(function () {
var enabled, readonly, self = this;
// sync enabled state // sync enabled state
var disabled = el.prop("disabled"); var disabled = el.prop("disabled");
if (disabled === undefined) disabled = false; if (disabled === undefined) disabled = false;
@ -1278,7 +1276,7 @@ the specific language governing permissions and limitations under the Apache Lic
scroll = "scroll." + cid, scroll = "scroll." + cid,
resize = "resize."+cid, resize = "resize."+cid,
orient = "orientationchange."+cid, orient = "orientationchange."+cid,
mask, maskCss; mask;
this.container.addClass("select2-dropdown-open").addClass("select2-container-active"); this.container.addClass("select2-dropdown-open").addClass("select2-container-active");
@ -1501,7 +1499,6 @@ the specific language governing permissions and limitations under the Apache Lic
var results = this.results, var results = this.results,
more = results.find("li.select2-more-results"), more = results.find("li.select2-more-results"),
below, // pixels the element is below the scroll fold, below==0 is when the element is starting to be visible below, // pixels the element is below the scroll fold, below==0 is when the element is starting to be visible
offset = -1, // index of first element without data
page = this.resultsPage + 1, page = this.resultsPage + 1,
self=this, self=this,
term=this.search.val(), term=this.search.val(),
@ -3019,7 +3016,7 @@ the specific language governing permissions and limitations under the Apache Lic
// multi // multi
val: function (val, triggerChange) { val: function (val, triggerChange) {
var oldData, self=this, changeDetails; var oldData, self=this;
if (arguments.length === 0) { if (arguments.length === 0) {
return this.getVal(); return this.getVal();