View Revisions: Issue #1106
[ All Revisions ] [ Back to Issue ]
Summary | 0001106: Shift+Adjust on links behaves as plain Adjust | ||
---|---|---|---|
Revision | 2015-10-31 22:06 by Vincent Sanders | ||
Description | From: Christopher Martin <belles@internode.on.net> I am using version 2.0 (Dev) (20 Aug 2007 02:45) r3529. But as I recall, this has been a long-standing bug. According to the User Guide, a Shift+Adjust click on a link should allow saving the target address as a URL. However, the behaviour is the same as that produced by plain Adjust, as if the Shift key status is being ignored. Tonight, I downloaded the latest sources via SVN. I think I may have identified the cause of the problem. There is a block of code in function browser_window_mouse_action_html(...), in file <netsurf.desktop.c.browser>, in which three if-else tests are performed. The order of the tests is significant. The present order is as follows: if (mouse & BROWSER_MOUSE_CLICK_1 && mouse & BROWSER_MOUSE_MOD_1) { ... } else if (mouse & (BROWSER_MOUSE_CLICK_1 | BROWSER_MOUSE_CLICK_2)) { ... } else if (mouse & BROWSER_MOUSE_CLICK_2 && mouse & BROWSER_MOUSE_MOD_1) { ... } Might I suggest you consider swapping the 2nd and 3rd tests so that the structure becomes: if (mouse & BROWSER_MOUSE_CLICK_1 && mouse & BROWSER_MOUSE_MOD_1) { ... } else if (mouse & BROWSER_MOUSE_CLICK_2 && mouse & BROWSER_MOUSE_MOD_1) { ... } else if (mouse & (BROWSER_MOUSE_CLICK_1 | BROWSER_MOUSE_CLICK_2)) { ... } I have attached a modified version of <netsurf.desktop.c.browser> for your consideration. (I should mention that I do not yet have all the tools needed to build Netsurf for myself and test my changes.) |
||
Revision | 2007-08-22 16:28 by Sourceforge Import placeholder | ||
Description | From: Christopher Martin <belles@internode.on.net> I am using version 2.0 (Dev) (20 Aug 2007 02:45) r3529. But as I recall, this has been a long-standing bug. According to the User Guide, a Shift+Adjust click on a link should allow saving the target address as a URL. However, the behaviour is the same as that produced by plain Adjust, as if the Shift key status is being ignored. Tonight, I downloaded the latest sources via SVN. I think I may have identified the cause of the problem. There is a block of code in function browser_window_mouse_action_html(...), in file <netsurf.desktop.c.browser>, in which three if-else tests are performed. The order of the tests is significant. The present order is as follows: if (mouse & BROWSER_MOUSE_CLICK_1 && mouse & BROWSER_MOUSE_MOD_1) { ... } else if (mouse & (BROWSER_MOUSE_CLICK_1 | BROWSER_MOUSE_CLICK_2)) { ... } else if (mouse & BROWSER_MOUSE_CLICK_2 && mouse & BROWSER_MOUSE_MOD_1) { ... } Might I suggest you consider swapping the 2nd and 3rd tests so that the structure becomes: if (mouse & BROWSER_MOUSE_CLICK_1 && mouse & BROWSER_MOUSE_MOD_1) { ... } else if (mouse & BROWSER_MOUSE_CLICK_2 && mouse & BROWSER_MOUSE_MOD_1) { ... } else if (mouse & (BROWSER_MOUSE_CLICK_1 | BROWSER_MOUSE_CLICK_2)) { ... } I have attached a modified version of <netsurf.desktop.c.browser> for your consideration. (I should mention that I do not yet have all the tools needed to build Netsurf for myself and test my changes.) |