st-clipboard: Add the ability to choose the clipboard type
https://bugzilla.gnome.org/show_bug.cgi?id=645019
This commit is contained in:
@ -90,7 +90,7 @@ const EntryMenu = new Lang.Class({
|
||||
},
|
||||
|
||||
_updatePasteItem: function() {
|
||||
this._clipboard.get_text(Lang.bind(this,
|
||||
this._clipboard.get_text(St.ClipboardType.CLIPBOARD, Lang.bind(this,
|
||||
function(clipboard, text) {
|
||||
this._pasteItem.setSensitive(text && text != '');
|
||||
}));
|
||||
@ -106,11 +106,11 @@ const EntryMenu = new Lang.Class({
|
||||
|
||||
_onCopyActivated: function() {
|
||||
let selection = this._entry.clutter_text.get_selection();
|
||||
this._clipboard.set_text(selection);
|
||||
this._clipboard.set_text(St.ClipboardType.CLIPBOARD, selection);
|
||||
},
|
||||
|
||||
_onPasteActivated: function() {
|
||||
this._clipboard.get_text(Lang.bind(this,
|
||||
this._clipboard.get_text(St.ClipboardType.CLIPBOARD, Lang.bind(this,
|
||||
function(clipboard, text) {
|
||||
if (!text)
|
||||
return;
|
||||
|
Reference in New Issue
Block a user