Closed lidaobing closed 5 months ago
This pull request addresses the issue where Ctrl-V would paste text twice. The main changes include the introduction of a new utility function igtk_text_buffer_get_text
for retrieving text from a GtkTextBuffer, refactoring paste handling to use GTK's 'paste-clipboard' signal, and updating tests to verify the correct behavior.
Files | Changes |
---|---|
src/iptux/UiHelper.cpp src/iptux/UiHelper.h |
Introduced a new utility function igtk_text_buffer_get_text to retrieve text from a GtkTextBuffer. |
src/iptux/DialogBase.cpp src/iptux/DialogPeer.cpp |
Refactored paste handling to use GTK's 'paste-clipboard' signal and removed direct text paste handling from OnPasteClipboard . |
All modified and coverable lines are covered by tests :white_check_mark:
Project coverage is 51.37%. Comparing base (
8653a31
) to head (467944a
).
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
Summary by Sourcery
This pull request addresses a bug where using Ctrl-V to paste text would result in the text being pasted twice. The text pasting logic was refactored to use the 'paste-clipboard' signal, and a new test was added to ensure correct functionality.