summaryrefslogtreecommitdiff
path: root/beos
diff options
context:
space:
mode:
authorFrançois Revel <mmu_man@netsurf-browser.org>2008-10-11 16:58:22 +0000
committerFrançois Revel <mmu_man@netsurf-browser.org>2008-10-11 16:58:22 +0000
commitf94f5cef35f7cd2322c2c45ba749658887b7bc67 (patch)
treea32f24c24bc8f7f4cafa5c69a964e6197f42bab4 /beos
parent4463070f1c8f0bb6337e97b39dfbb0a36a9f4676 (diff)
downloadnetsurf-f94f5cef35f7cd2322c2c45ba749658887b7bc67.tar.gz
netsurf-f94f5cef35f7cd2322c2c45ba749658887b7bc67.tar.bz2
Fix copying plain text selection.
svn path=/trunk/netsurf/; revision=5538
Diffstat (limited to 'beos')
-rw-r--r--beos/beos_window.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/beos/beos_window.cpp b/beos/beos_window.cpp
index 32398a6e9..6eadb7ffb 100644
--- a/beos/beos_window.cpp
+++ b/beos/beos_window.cpp
@@ -1834,6 +1834,7 @@ static bool copy_handler(const char *text, size_t length, struct box *box,
void *handle, const char *whitespace_text,
size_t whitespace_length)
{
+ bool space = false;
//XXX: handle box->style to StyledEdit / RTF ?
/* add any whitespace which precedes the text from this box */
if (whitespace_text) {
@@ -1852,10 +1853,11 @@ static bool copy_handler(const char *text, size_t length, struct box *box,
run->font = font;
run->color = nsbeos_rgb_colour(box->style->color);
current_selection_textruns.AddItem(run);
+ space = box->space;
}
/* add the text from this box */
- if (!gui_add_to_clipboard(text, length, box->space))
+ if (!gui_add_to_clipboard(text, length, space))
return false;
return true;