Skip to content

Commit

Permalink
deleted paste button, again, this time well tested
Browse files Browse the repository at this point in the history
  • Loading branch information
Uyanide committed Jul 21, 2024
1 parent 2b34e99 commit e2a46d3
Showing 1 changed file with 2 additions and 10 deletions.
12 changes: 2 additions & 10 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -85,10 +85,6 @@
margin-top: 10px;
}

.pasteInput label {
margin-right: 5px;
}

.dragInputHint {
margin-top: 10px;
}
Expand Down Expand Up @@ -178,13 +174,12 @@ <h1>光棱坦克显形</h1>
<input type="file" id="imageInput" accept="image/*" title="选择一个图像文件">
</div>
<div class="urlInput">
<label for="imageUrlInput">或从URL加载图片:</label>
<label for="imageUrlInput">或从URL:</label>
<input type="text" id="imageUrlInput" placeholder="输入图片URL">
<button id="loadImageButton">加载图片</button>
</div>
<div class="pasteInput">
<label for="imagePasteButton">或从剪贴板粘贴图片: </label>
<button id="imagePasteButton">确认粘贴</button>
<label for="imagePasteButton">或从剪贴板粘贴图片 (ctrl+v),</label>
</div>
<div class="dragInputHint">
或直接将图片拖进窗口。
Expand Down Expand Up @@ -417,9 +412,6 @@ <h1>光棱坦克显形</h1>
}
});

// 粘贴图片按钮事件监听
document.getElementById('imagePasteButton').addEventListener('click', updateImageFromClipboard);

// 滑动条事件监听,设置阈值
document.getElementById('thresholdRange').addEventListener('input', () => {
imageProcessor.threshold = parseInt(document.getElementById('thresholdRange').value, 10);
Expand Down

0 comments on commit e2a46d3

Please sign in to comment.