Issue 73: Ensure first layer is always selected. Adjust layer buttons to fit Opera and Webkit.
git-svn-id: http://svg-edit.googlecode.com/svn/trunk@672 eee81c28-f429-11dd-99c0-75d572ba1ddd
This commit is contained in:
@@ -79,9 +79,6 @@ function svg_edit_setup() {
|
||||
// we tell it to skip focusing the text control if the
|
||||
// text element was previously in focus
|
||||
updateContextPanel();
|
||||
|
||||
// TODO: ensure that the current layer is selected
|
||||
console.log(svgCanvas.getCurrentLayer());
|
||||
};
|
||||
|
||||
var zoomChanged = function(window, bbox) {
|
||||
@@ -1133,6 +1130,11 @@ function svg_edit_setup() {
|
||||
var name = svgCanvas.getLayer(layer);
|
||||
$('#layerlist').append("<option value=\"" + name + "\">" + name + "</option>");
|
||||
}
|
||||
// if we only have one layer, then always make sure that layer is selected
|
||||
// (This is really only required upon first initialization)
|
||||
if ($('#layerlist').size() == 1) {
|
||||
$('#layerlist option:first').attr("selected", "selected");
|
||||
}
|
||||
$('#layerlist option').mouseup(function(evt){
|
||||
$('#layerlist option').removeAttr("selected");
|
||||
var option = $(this);
|
||||
|
||||
Reference in New Issue
Block a user