Skip to content

Instantly share code, notes, and snippets.

@kiko
Created May 3, 2011 13:17
Show Gist options
  • Save kiko/953309 to your computer and use it in GitHub Desktop.
Save kiko/953309 to your computer and use it in GitHub Desktop.
diff --git a/lib/ver/methods/clipboard.rb b/lib/ver/methods/clipboard.rb
index e29267f..bbde245 100644
--- a/lib/ver/methods/clipboard.rb
+++ b/lib/ver/methods/clipboard.rb
@@ -71,7 +71,7 @@ module VER
record.insert(:insert, string)
buffer.insert = buffer.at_insert.linestart
else
- pastie_string_after!(record, count, string)
+ pastie_string_after!(buffer, record, count, string)
end
end
end
@@ -83,15 +83,15 @@ module VER
buffer.insert = buffer.at_insert.lineend
record.insert(:insert, string)
else
- pastie_string_after!(record, count, string)
+ pastie_string_after!(buffer, record, count, string)
end
end
end
- def pastie_string_after!(buffer, count, string)
+ def pastie_string_after!(buffer, record, count, string)
add = buffer.at_eol? ? '0' : '1'
buffer.insert = buffer.at_insert + (add + ' displaychars')
- buffer.insert(:insert, string * count)
+ record.insert(:insert, string * count)
end
# the vim and the ver, the vim and the ver,
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment