var initDropdown = function () {
    var me = $(this);
    var dropdownList = me.find(".dropdownList");
    if (dropdownList.children().length === 0) {
        me.find("option").each(function (i, e) {
            $(e).addClass("opt-" + i);
            dropdownList.append($('<li class="item-' + i + '">' + $(e).text() + '</li>'));
        });
    }
    var select = me.find("select").val();
    me.find(".dropdownValue").text(me.find('option[value="'+select+'"]').text())

    if (me.css("minWidth").replace("px", "") == "0") {
        me.width(dropdownList.width() + 60);
    }
};
$(function () {
    // init dropdown list --------------------------------------------------------------------

    var toggleList = function () {
        var me = $(this);
        var list = me.find(".dropdownList");
        var opts = me.find(".hiddenDropdown");
        if (list.css("display") == "block") {
            list.hide();
        } else {
            $(".dropdownList").hide();
            list.show();
            list.find("li").one("click", function (event) {
                event.stopPropagation();
                list.hide().find("li").off("click");
                var me2 = $(this);
                var opt = me2.attr("class").replace("item", "opt");
                me.find(".dropdownValue").text(me2.text());
                opts.find("[selected=selected]").removeAttr("selected");
                var val = opts.find("." + opt).attr("selected", "selected").val();
                opts.val(val).trigger('change');
            })
        }

        $(document).one("click", function () {
            list.hide().find("li").off("mouseout").off("click");
        });
        return false;
    }
    $('.dropdown').each(function () {
        initDropdown.call(this);
    });
    $(document).on("click", ".dropdown", toggleList);
});

@@ -1,31 +1,52 @@
-var initDropdown = 
+$(function() %7B%0A%0A    $('.dropdown').each(
 function
  () 
@@ -33,33 +33,32 @@
 ').each(function
- 
 () %7B%0A    var me 
@@ -46,30 +46,39 @@
 ion() %7B%0A    
+   
+ 
 var 
-m
 e
+lement
  = $(this);%0A
@@ -73,24 +73,28 @@
  = $(this);%0A
+    
     var drop
@@ -100,26 +100,31 @@
 pdownList = 
-m
 e
+lement
 .find(%22.drop
@@ -139,19 +139,22 @@
 %22);%0A    
+  
+  
 if
- 
 (dropdow
@@ -190,26 +190,35 @@
 ) %7B%0A        
+  
-me
+  element
 .find(%22optio
@@ -234,17 +234,16 @@
 function
- 
 (i, e) %7B
@@ -255,16 +255,20 @@
         
+   
+ 
 $(e).add
@@ -286,16 +286,20 @@
 %22 + i);%0A
+    
         
@@ -389,24 +389,28 @@
         
+    
 %7D);%0A    
 %7D%0A    va
@@ -397,26 +397,34 @@
     %7D);%0A    
+  
-%7D%0A
+  %7D%0A    
     var sele
@@ -424,26 +424,31 @@
 ar select = 
-m
 e
+lement
 .find(%22selec
@@ -458,26 +458,35 @@
 .val();%0A    
-me
+    element
 .find(%22.drop
@@ -502,18 +502,23 @@
 %22).text(
-m
 e
+lement
 .find('o
@@ -535,16 +535,20 @@
 e=%22'
-+
+ + 
 select
-+
+ + 
 '%22%5D'
@@ -566,245 +566,22 @@
     
-if (me.css(%22minWidth%22).replace(%22px%22, %22%22) == %220%22) %7B%0A        me.width(dropdownList.width() + 60);%0A    %7D%0A%7D;%0A$(function () %7B%0A    // init dropdown list --------------------------------------------------------------------%0A%0A    var toggleList =
+%7D).on('click',
  fun
@@ -577,33 +577,32 @@
 click', function
- 
 () %7B%0A        var
@@ -718,17 +718,16 @@
       if
- 
 (list.cs
@@ -908,17 +908,16 @@
 function
- 
 (event) 
@@ -1439,33 +1439,32 @@
 click%22, function
- 
 () %7B%0A           
@@ -1560,141 +1560,9 @@
    %7D
-%0A    $('.dropdown').each(function () %7B%0A        initDropdown.call(this);%0A    %7D);%0A    $(document).on(%22click%22, %22.dropdown%22, toggleList);
+)
 %0A%7D);

Improve scale and srs selector styles