Show
Ignore:
Timestamp:
27.03.2015 17:16:40 (5 years ago)
Author:
davidb
Message:

Fixed missing param on .replace() call

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • other-projects/nz-flag-design/trunk/main-form/choose-palette.html

    r29811 r29813  
    9494       
    9595            if (typeof flagCanvasSettings !== 'undefined') { 
    96                 var colour_pos_pos = selectedColourPotID.replace("colour-pot"); 
     96                console.log("**** cp changed, !! selectedColourPotID = " + selectedColourPotID + " typeof = " + typeof(selectedColourPotID)); 
     97                //var colour_pot_pos = selectedColourPotID.substring(10); // strip off 'colour-pos' 
     98                var colour_pot_pos = selectedColourPotID.replace("colour-pot",""); 
     99                //colour_pot_pos = 0; 
     100                console.log("**** done replace");                    
    97101                flagCanvasSettings.colourPots[colour_pot_pos] = colour.toHexString(); 
    98102        } 
     
    193197              ], 
    194198          change: colourPotChanged, 
    195               show: function() { $('#'+selectedColourPickerDivID).css("visibility","hidden")} 
     199              show: function() { console.log("Away to show") ; $('#'+selectedColourPickerDivID).css("visibility","hidden") ; console.log("done show")} 
    196200            });           
    197201 
     
    236240      selectedColourPot = colourPotElem; 
    237241      selectedColourPotID = colourPotElem.id; 
     242      console.log("**** cp clicked, selectedColourPotID = " + selectedColourPotID);                  
    238243      selectedColourPickerID = selectedColourPotID.replace("colour-pot","colour-picker"); 
    239244      selectedColourPickerDivID = selectedColourPotID.replace("colour-pot","colour-picker-div");