diff options
author | François Revel <mmu_man@netsurf-browser.org> | 2008-10-10 21:43:25 +0000 |
---|---|---|
committer | François Revel <mmu_man@netsurf-browser.org> | 2008-10-10 21:43:25 +0000 |
commit | 4e79ee3d071df821f51f1a3f2d09bfedaa7af3b1 (patch) | |
tree | 75956bc92b844280da04395b9d80f2c4e6b324c7 /beos/beos_gui.cpp | |
parent | e4fba7f577d44f3235b2c430191d96ddfc084827 (diff) | |
download | netsurf-4e79ee3d071df821f51f1a3f2d09bfedaa7af3b1.tar.gz netsurf-4e79ee3d071df821f51f1a3f2d09bfedaa7af3b1.tar.bz2 |
- support BITMAP_CLEAR_MEMORY in create_bitmap()
- copying to clipboard now constructs a text_run_array for StyledEdit, that is added to the clipboard. In applications supporting it it pastes the text with the correct fonts and sizes, and the text colors.
- tried to find which line in source code the selection starts to open the editor there, but it's not finished so it's disabled.
svn path=/trunk/netsurf/; revision=5533
Diffstat (limited to 'beos/beos_gui.cpp')
-rw-r--r-- | beos/beos_gui.cpp | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/beos/beos_gui.cpp b/beos/beos_gui.cpp index f762afe82..94d1f1066 100644 --- a/beos/beos_gui.cpp +++ b/beos/beos_gui.cpp @@ -807,7 +807,7 @@ void gui_window_save_as_link(struct gui_window *g, struct content *c) * Send the source of a content to a text editor. */ -void nsbeos_gui_view_source(struct content *content) +void nsbeos_gui_view_source(struct content *content, struct selection *selection) { char *temp_name; bool done = false; @@ -867,6 +867,22 @@ void nsbeos_gui_view_source(struct content *content) BMessage m(B_REFS_RECEIVED); m.AddRef("refs", &ref); +#if 0 + if (selection && selection->defined) { + int32 line = -1; + if (content->type == CONTENT_HTML) { + // XXX: use selection, find line in source code + } + if (content->type == CONTENT_TEXTPLAIN) { + line = MAKELINE_FROM_IDX(start_idx); + } + // not CSS! + + if (line > -1) + message.AddInt32("be:line", line); + } +#endif + // apps to try const char *editorSigs[] = { "application/x-vnd.beunited.pe", |