填充颜色更改
This commit is contained in:
@@ -327,11 +327,14 @@ function handleKeyDown(event) {
|
||||
}
|
||||
}
|
||||
|
||||
const fillInputTimeout = ref(null);
|
||||
// 填充颜色选择器
|
||||
function fillColorChange() {
|
||||
layerManager.fillLayerBackground(lastSelectLayerId.value, fillColor.value, true);
|
||||
clearTimeout(fillInputTimeout.value);
|
||||
fillInputTimeout.value = setTimeout(() => {
|
||||
layerManager.fillLayerBackground(lastSelectLayerId.value, fillColor.value, true);
|
||||
}, 100);
|
||||
}
|
||||
|
||||
onMounted(() => {
|
||||
// 添加键盘事件监听
|
||||
window.addEventListener("keydown", handleKeyDown);
|
||||
@@ -355,7 +358,7 @@ const handleToolClick = (tool) => {
|
||||
v-model="fillColor"
|
||||
ref="fillColorRef"
|
||||
type="color"
|
||||
@change="fillColorChange"
|
||||
@input="fillColorChange"
|
||||
style="width: 0; height: 0; opacity: 0"
|
||||
/>
|
||||
<div class="tools-list">
|
||||
|
||||
Reference in New Issue
Block a user