mirror of
https://github.com/TermoraDev/termora.git
synced 2026-01-15 18:02:58 +08:00
feat: SFTP command icon
This commit is contained in:
@@ -50,6 +50,7 @@ object Icons {
|
||||
val import by lazy { DynamicIcon("icons/import.svg", "icons/import_dark.svg") }
|
||||
val export by lazy { DynamicIcon("icons/export.svg", "icons/export_dark.svg") }
|
||||
val terminal by lazy { DynamicIcon("icons/terminal.svg", "icons/terminal_dark.svg") }
|
||||
val fileFormat by lazy { DynamicIcon("icons/fileFormat.svg", "icons/fileFormat_dark.svg") }
|
||||
val azure by lazy { DynamicIcon("icons/azure.svg", "icons/azure_dark.svg") }
|
||||
val revert by lazy { DynamicIcon("icons/revert.svg", "icons/revert_dark.svg") }
|
||||
val edit by lazy { DynamicIcon("icons/edit.svg", "icons/edit_dark.svg") }
|
||||
|
||||
@@ -18,6 +18,7 @@ import java.io.File
|
||||
import java.nio.charset.StandardCharsets
|
||||
import java.nio.file.Files
|
||||
import java.nio.file.Path
|
||||
import javax.swing.Icon
|
||||
import javax.swing.SwingUtilities
|
||||
|
||||
class SFTPPtyTerminalTab(windowScope: WindowScope, host: Host) : PtyHostTerminalTab(windowScope, host) {
|
||||
@@ -162,6 +163,10 @@ class SFTPPtyTerminalTab(windowScope: WindowScope, host: Host) : PtyHostTerminal
|
||||
super.stop()
|
||||
}
|
||||
|
||||
override fun getIcon(): Icon {
|
||||
return Icons.fileFormat
|
||||
}
|
||||
|
||||
private inner class PasswordReporterDataListener(private val host: Host) : DataListener {
|
||||
override fun onChanged(key: DataKey<*>, data: Any) {
|
||||
if (key == VisualTerminal.Written && data is String) {
|
||||
|
||||
5
src/main/resources/icons/fileFormat.svg
Normal file
5
src/main/resources/icons/fileFormat.svg
Normal file
@@ -0,0 +1,5 @@
|
||||
<!-- Copyright 2000-2024 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license. -->
|
||||
<svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||
<path d="M12.5 15.5V9.5M9.90193 14L15.0981 11M15.0981 14L9.90192 11" stroke="#6C707E" stroke-linecap="round"/>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M3 5.41421V13C3 14.1046 3.89543 15 5 15H8.75777C8.55127 14.6915 8.3819 14.356 8.25606 14H5C4.44772 14 4 13.5523 4 13L4 6H6C7.10457 6 8 5.10457 8 4V2L11 2C11.5523 2 12 2.44772 12 3V8.02746C12.1642 8.00932 12.331 8 12.5 8C12.669 8 12.8358 8.00932 13 8.02746V3C13 1.89543 12.1046 1 11 1H7.41421C7.149 1 6.89464 1.10536 6.70711 1.29289L3.29289 4.70711C3.10536 4.89464 3 5.149 3 5.41421ZM7 2.41421L4.41421 5H6C6.55228 5 7 4.55228 7 4V2.41421Z" fill="#6C707E"/>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 846 B |
5
src/main/resources/icons/fileFormat_dark.svg
Normal file
5
src/main/resources/icons/fileFormat_dark.svg
Normal file
@@ -0,0 +1,5 @@
|
||||
<!-- Copyright 2000-2024 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license. -->
|
||||
<svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||
<path d="M12.5 15.5V9.5M9.90193 14L15.0981 11M15.0981 14L9.90192 11" stroke="#CED0D6" stroke-linecap="round"/>
|
||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M3 5.41421V13C3 14.1046 3.89543 15 5 15H8.75777C8.55127 14.6915 8.3819 14.356 8.25606 14H5C4.44772 14 4 13.5523 4 13L4 6H6C7.10457 6 8 5.10457 8 4V2L11 2C11.5523 2 12 2.44772 12 3V8.02746C12.1642 8.00932 12.331 8 12.5 8C12.669 8 12.8358 8.00932 13 8.02746V3C13 1.89543 12.1046 1 11 1H7.41421C7.149 1 6.89464 1.10536 6.70711 1.29289L3.29289 4.70711C3.10536 4.89464 3 5.149 3 5.41421ZM7 2.41421L4.41421 5H6C6.55228 5 7 4.55228 7 4V2.41421Z" fill="#CED0D6"/>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 846 B |
Reference in New Issue
Block a user