fix qutes
This commit is contained in:
parent
994700568e
commit
0f2606f19f
@ -39,7 +39,7 @@ class command():
|
|||||||
self.env['runtime']['outputManager'].presentText(_('clipboard empty'), interrupt=True)
|
self.env['runtime']['outputManager'].presentText(_('clipboard empty'), interrupt=True)
|
||||||
return
|
return
|
||||||
for display in range(10):
|
for display in range(10):
|
||||||
p = Popen('su ' + self.env['general']['currUser'] + ' -c "echo -n \"' + self.env['commandBuffer']['clipboard'][currClipboard] +'\" | xclip -d :' + str(display) + ' -selection c"' , stdout=PIPE, stderr=PIPE, shell=True)
|
p = Popen('su ' + self.env['general']['currUser'] + ' -c "echo -n \\\"' + self.env['commandBuffer']['clipboard'][currClipboard] +'\\\" | xclip -d :' + str(display) + ' -selection c"' , stdout=PIPE, stderr=PIPE, shell=True)
|
||||||
stdout, stderr = p.communicate()
|
stdout, stderr = p.communicate()
|
||||||
self.env['runtime']['outputManager'].interruptOutput()
|
self.env['runtime']['outputManager'].interruptOutput()
|
||||||
#screenEncoding = self.env['runtime']['settingsManager'].getSetting('screen', 'encoding')
|
#screenEncoding = self.env['runtime']['settingsManager'].getSetting('screen', 'encoding')
|
||||||
@ -47,6 +47,8 @@ class command():
|
|||||||
stdout = stdout.decode('utf-8')
|
stdout = stdout.decode('utf-8')
|
||||||
if (stderr == ''):
|
if (stderr == ''):
|
||||||
break
|
break
|
||||||
|
else:
|
||||||
|
print(stderr)
|
||||||
#stderr = stderr.decode(screenEncoding, "replace").encode('utf-8').decode('utf-8')
|
#stderr = stderr.decode(screenEncoding, "replace").encode('utf-8').decode('utf-8')
|
||||||
#stdout = stdout.decode(screenEncoding, "replace").encode('utf-8').decode('utf-8')
|
#stdout = stdout.decode(screenEncoding, "replace").encode('utf-8').decode('utf-8')
|
||||||
if stderr != '':
|
if stderr != '':
|
||||||
@ -54,6 +56,7 @@ class command():
|
|||||||
else:
|
else:
|
||||||
self.env['runtime']['outputManager'].presentText('export clipboard', soundIcon='PasteClipboardOnScreen', interrupt=True)
|
self.env['runtime']['outputManager'].presentText('export clipboard', soundIcon='PasteClipboardOnScreen', interrupt=True)
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
|
print(e)
|
||||||
self.env['runtime']['outputManager'].presentText(e , soundIcon='', interrupt=False)
|
self.env['runtime']['outputManager'].presentText(e , soundIcon='', interrupt=False)
|
||||||
|
|
||||||
def setCallback(self, callback):
|
def setCallback(self, callback):
|
||||||
|
Loading…
Reference in New Issue
Block a user