forked from Botanical/BotanJS
minor bug fixes
This commit is contained in:
parent
8f05e37ee4
commit
2778e12f38
@ -23,7 +23,7 @@
|
||||
, "AS3" , "as3"
|
||||
, "bash" , "bash"
|
||||
, "C#" , "csharp"
|
||||
, "C/C++" , "c"
|
||||
, "C/C++" , "cpp"
|
||||
, "CSS" , "css"
|
||||
, "php" , "php"
|
||||
, "Python" , "python"
|
||||
|
@ -75,22 +75,22 @@
|
||||
var keys = [ new IKey( "type", "radio" ), new IKey( "name", "size_grp" + Perf.uuid ) ];
|
||||
var sid;
|
||||
var selectionChanged = function ()
|
||||
{
|
||||
_stage.setAttribute( new DataKey( "size", this.size ) );
|
||||
//// Handles the size selection
|
||||
switch(this.size)
|
||||
{
|
||||
_stage.setAttribute( new DataKey( "size", this.size ) );
|
||||
//// Handles the size selection
|
||||
switch(this.size)
|
||||
{
|
||||
case "small":
|
||||
_image.setAttribute( "src", config.path.image.small + _hash + ".jpg" );
|
||||
break;
|
||||
case "medium":
|
||||
_image.setAttribute( "src", config.path.image.medium + _hash + ".jpg" );
|
||||
break;
|
||||
case "large":
|
||||
_image.setAttribute( "src", config.path.image.large + _hash + ".jpg" );
|
||||
break;
|
||||
}
|
||||
};
|
||||
case "small":
|
||||
_image.setAttribute( "src", config.path.image.small + _hash + ".jpg" );
|
||||
break;
|
||||
case "medium":
|
||||
_image.setAttribute( "src", config.path.image.medium + _hash + ".jpg" );
|
||||
break;
|
||||
case "large":
|
||||
_image.setAttribute( "src", config.path.image.large + _hash + ".jpg" );
|
||||
break;
|
||||
}
|
||||
};
|
||||
|
||||
this.stage.insertBefore( _image, desc );
|
||||
|
||||
@ -111,6 +111,20 @@
|
||||
IDOMElement(s).addEventListener("Change", selectionChanged.bind({size: "small"}));
|
||||
IDOMElement(m).addEventListener("Change", selectionChanged.bind({size: "medium"}));
|
||||
IDOMElement(l).addEventListener("Change", selectionChanged.bind({size: "large"}));
|
||||
|
||||
var hasValue = _stage.getDAttribute( "size" );
|
||||
if( hasValue )
|
||||
{
|
||||
switch( hasValue )
|
||||
{
|
||||
case "small": s.checked = 1; break;
|
||||
case "medium": m.checked = 1; break;
|
||||
case "large": l.checked = 1; break;
|
||||
}
|
||||
|
||||
selectionChanged.bind({ size: hasValue })();
|
||||
}
|
||||
|
||||
break;
|
||||
case "audio":
|
||||
// TODO
|
||||
@ -143,7 +157,7 @@
|
||||
]
|
||||
, [
|
||||
new DataKey( "value", hash )
|
||||
, new DataKey( "size", "large" )
|
||||
, new DataKey( "size", override.size || "large" )
|
||||
, new IKey( "style", "max-height: 150px;" )
|
||||
]
|
||||
);
|
||||
|
@ -48,6 +48,11 @@
|
||||
margin-bottom: 0.5em;
|
||||
}
|
||||
|
||||
textarea.v_snippet_input {
|
||||
font-family: monospace;
|
||||
font-size: 1em;
|
||||
}
|
||||
|
||||
.v_instruction {
|
||||
padding: 0.2em 0;
|
||||
}
|
||||
|
@ -4,7 +4,7 @@
|
||||
width: 225px;
|
||||
height: 325px;
|
||||
|
||||
margin: 1em;
|
||||
margin: 0 2em 2em 0;
|
||||
|
||||
position: relative;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user