#584 the select button changes when working on a path
This commit is contained in:
@@ -346,13 +346,8 @@ class Editor extends EditorStartup {
|
|||||||
$id('path_node_panel').style.display = (editmode) ? 'block' : 'none';
|
$id('path_node_panel').style.display = (editmode) ? 'block' : 'none';
|
||||||
if (editmode) {
|
if (editmode) {
|
||||||
// Change select icon
|
// Change select icon
|
||||||
const elements = document.getElementsByClassName("tool_button_current");
|
$id('tool_path').pressed = false;
|
||||||
Array.from(elements).forEach(function (element) {
|
$id('tool_select').pressed = true;
|
||||||
element.classList.add('tool_button_current');
|
|
||||||
element.classList.remove('tool_button');
|
|
||||||
});
|
|
||||||
$id('tool_select').classList.add('tool_button_current');
|
|
||||||
$id('tool_select').classList.remove('tool_button');
|
|
||||||
this.multiselected = false;
|
this.multiselected = false;
|
||||||
if (elems.length) {
|
if (elems.length) {
|
||||||
this.selectedElement = elems[0];
|
this.selectedElement = elems[0];
|
||||||
|
|||||||
@@ -634,8 +634,8 @@ class TopPanel {
|
|||||||
* @returns {void}
|
* @returns {void}
|
||||||
*/
|
*/
|
||||||
linkControlPoints() {
|
linkControlPoints() {
|
||||||
const linked = $id("tool_node_link").pressed;
|
$id("tool_node_link").pressed = ($id("tool_node_link").pressed) ? false : true;
|
||||||
$id("tool_node_link").pressed = !linked;
|
const linked = ($id("tool_node_link").pressed) ? true : false;
|
||||||
this.path.linkControlPoints(linked);
|
this.path.linkControlPoints(linked);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -968,7 +968,7 @@ class TopPanel {
|
|||||||
</div> <!-- a_panel -->
|
</div> <!-- a_panel -->
|
||||||
<div id="path_node_panel">
|
<div id="path_node_panel">
|
||||||
<div class="tool_sep"></div>
|
<div class="tool_sep"></div>
|
||||||
<se-button id="tool_node_link" title="${i18next.t('tools.node_link')}" src="./images/tool_node_link.svg" pressed>
|
<se-button id="tool_node_link" title="${i18next.t('tools.node_link')}" src="./images/tool_node_link.svg" pressed={${true}}>
|
||||||
</se-button>
|
</se-button>
|
||||||
<div class="tool_sep"></div>
|
<div class="tool_sep"></div>
|
||||||
<se-spin-input id="path_node_x" data-attr="x" size="4" title="${i18next.t('properties.node_x')}" label="x:">
|
<se-spin-input id="path_node_x" data-attr="x" size="4" title="${i18next.t('properties.node_x')}" label="x:">
|
||||||
|
|||||||
Reference in New Issue
Block a user