aboutsummaryrefslogtreecommitdiff
path: root/dw/layout.hh
diff options
context:
space:
mode:
authorRodrigo Arias Mallo <rodarima@gmail.com>2025-05-07 23:54:32 +0200
committerRodrigo Arias Mallo <rodarima@gmail.com>2025-05-08 00:00:32 +0200
commitd901d8b641c88f9f22b0479d4b3326b2ed06e958 (patch)
tree5e43ce0b923368457215651b2a1eb68921e275a2 /dw/layout.hh
parent1e5da933a4ef2c5de8ca711215918e9f3ff9df3e (diff)
Make Ctrl+C copy selection into clipboard
Follows the behavior of so many other programs by copying the current text selection into the clipboard with Ctrl+C. Selecting text continues to copy it into the primary selection. Fixes: https://github.com/dillo-browser/dillo/issues/228
Diffstat (limited to 'dw/layout.hh')
-rw-r--r--dw/layout.hh5
1 files changed, 5 insertions, 0 deletions
diff --git a/dw/layout.hh b/dw/layout.hh
index 36f433b5..1794179c 100644
--- a/dw/layout.hh
+++ b/dw/layout.hh
@@ -438,6 +438,11 @@ public:
platform->copySelection(text, destination);
}
+ inline void copyCurrentSelection(int destination)
+ {
+ selectionState.copy(destination);
+ }
+
inline ui::ResourceFactory *getResourceFactory ()
{
return platform->getResourceFactory ();