diff options
author | Michael Drake <tlsa@netsurf-browser.org> | 2011-07-02 12:18:04 +0000 |
---|---|---|
committer | Michael Drake <tlsa@netsurf-browser.org> | 2011-07-02 12:18:04 +0000 |
commit | dde300ea7d06a841be7653febedc1477fa758ead (patch) | |
tree | 2d3e73bda16bf69117112e5939e2e7b03a32836a | |
parent | 4147c185c8d547e041c1d0c81c283ef0c7942cc8 (diff) | |
download | netsurf-dde300ea7d06a841be7653febedc1477fa758ead.tar.gz netsurf-dde300ea7d06a841be7653febedc1477fa758ead.tar.bz2 |
Set selection browser window as before, for now.
svn path=/trunk/netsurf/; revision=12553
-rw-r--r-- | desktop/browser.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/desktop/browser.c b/desktop/browser.c index cc19ccdc0..827896835 100644 --- a/desktop/browser.c +++ b/desktop/browser.c @@ -292,6 +292,7 @@ struct browser_window *browser_window_create(const char *url, bw->focus = bw; bw->sel = selection_create(); + selection_set_browser_window(bw->sel, bw); /* gui window */ /* from the front end's pov, it clones the top level browser window, @@ -1682,6 +1683,10 @@ void browser_window_mouse_track(struct browser_window *bw, browser_window_mouse_drag_end(bw, mouse, x, y); } + if (bw->drag_type != DRAGGING_NONE) { + selection_set_browser_window(bw->sel, bw); + } + if (bw->drag_type == DRAGGING_FRAME) { browser_window_resize_frame(bw, bw->x0 + x, bw->y0 + y); } else if (bw->drag_type == DRAGGING_PAGE_SCROLL) { @@ -1736,6 +1741,8 @@ void browser_window_mouse_click(struct browser_window *bw, top = browser_window_get_root(bw); top->focus = bw; + selection_set_browser_window(bw->sel, bw); + switch (content_get_type(c)) { case CONTENT_HTML: case CONTENT_TEXTPLAIN: |