mirror of
https://github.com/rwinkhart/libmutton.git
synced 2026-09-03 23:57:27 -04:00
Remove mobile clipboard management (this should be the responsibility of the GUI toolkit)
This commit is contained in:
+2
-2
@@ -10,14 +10,14 @@ import (
|
||||
)
|
||||
|
||||
// CopyString copies a string to the clipboard.
|
||||
func CopyString(continuous bool, copySubject string) error {
|
||||
func CopyString(clearClipboardAutomatically bool, copySubject string) error {
|
||||
cmd := exec.Command("termux-clipboard-set")
|
||||
_ = back.WriteToStdin(cmd, copySubject)
|
||||
err := cmd.Run()
|
||||
if err != nil {
|
||||
return errors.New("unable to copy to clipboard: " + err.Error())
|
||||
}
|
||||
if !continuous {
|
||||
if clearClipboardAutomatically {
|
||||
LaunchClipClearProcess(copySubject)
|
||||
}
|
||||
return nil
|
||||
|
||||
Reference in New Issue
Block a user