Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 353305 - [Browser][WebKit] Javadoc tooltip cannot be closed with Esc
Summary: [Browser][WebKit] Javadoc tooltip cannot be closed with Esc
Status: RESOLVED FIXED
Alias: None
Product: Platform
Classification: Eclipse Project
Component: SWT (show other bugs)
Version: 3.7   Edit
Hardware: PC Linux
: P3 normal (vote)
Target Milestone: 3.8 M7   Edit
Assignee: Grant Gayed CLA
QA Contact:
URL:
Whiteboard:
Keywords:
: 364908 (view as bug list)
Depends on:
Blocks:
 
Reported: 2011-07-28 07:21 EDT by Florian Wunderlich CLA
Modified: 2013-07-01 11:54 EDT (History)
6 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Florian Wunderlich CLA 2011-07-28 07:21:02 EDT
Build Identifier: 20110615-0604

Tooltips opened with F2 ("Show Tooltip Description") can be closed by pressing Esc, except Javadoc tooltips. This worked fine in Eclipse-3.4, it ceased to work in 3.7.

Reproducible: Always

Steps to Reproduce:
1. Enter the following into a new Java class with an arbitrary name:

  public static void test()
  {
    final String s = new String();
  }

2.

Place the cursor over String and press F2. A javadoc tooltip appears. Press Esc, nothing happens, the tooltip remains on the screen.

Place the cursor over s, which is underlined in yellow, and press F2. The warning appears in a tooltip. Press Esc, and the tooltip disappears.
Comment 1 Markus Keller CLA 2011-07-28 08:13:23 EDT
Sounds like a problem with the WebKit browser. The Javadoc hover uses an SWT Browser widget, and since 3.7, that defaults to WebKit.

I could not reproduce the problem on our Linux box, but I don't have WebKit installed.
Comment 2 Florian Wunderlich CLA 2011-07-28 10:34:20 EDT
(In reply to comment #1)
> Sounds like a problem with the WebKit browser. The Javadoc hover uses an SWT
> Browser widget, and since 3.7, that defaults to WebKit.
> 
> I could not reproduce the problem on our Linux box, but I don't have WebKit
> installed.

This is indeed correct, WebKit is most probably causing the problems. Thank you very much for the quick response.

As soon as I move /usr/lib/libwebkit-1.0.so.2* away and start Eclipse, the JavaDoc tooltip can be closed with Esc.

Thus, a simple workaround is:

  mkdir ~/eclipse-ld
  ln -s /dev/null libwebkit-1.0.so.2
  LD_LIBRARY_PATH=~/eclipse-ld /opt/eclipse/eclipse
Comment 3 Markus Keller CLA 2011-07-28 11:02:24 EDT
In 3.7.1 and 3.8, the flag from bug 349837 will offer a better workaround (choose mozilla without fiddling with the installed WebKit library).
Comment 4 Grant Gayed CLA 2011-08-11 11:21:43 EDT
This likely has the same cause as bug 350989, that events aren't delivered when JS is disabled.  Marking report as a duplicate.

*** This bug has been marked as a duplicate of bug 350098 ***
Comment 5 Grant Gayed CLA 2012-04-12 12:04:39 EDT
Reopening, the fix for bug 350098 is apparently not enough to fix this case as well.
Comment 6 Grant Gayed CLA 2012-04-12 12:05:33 EDT
*** Bug 364908 has been marked as a duplicate of this bug. ***
Comment 8 Michael Diamant CLA 2013-02-06 10:06:21 EST
Can this be backported into 3.7.2?
Comment 9 Grant Gayed CLA 2013-02-07 15:05:49 EST
3.7.2 has been finished for ~ a year, there aren't any more builds being made.
Comment 10 Piers Powlesland CLA 2013-06-28 12:44:56 EDT
Can anyone give me a clue as to how I can use this patch?
Comment 11 Piers Powlesland CLA 2013-07-01 11:54:34 EDT
I'm using Ubuntu 12.10 64 bit and the patch did not work for me!

I used a method similar to Missing Names's approach

Found all my libwebkit libs

$ ls -l /usr/lib/libwebkit*
lrwxrwxrwx 1 root root       26 Nov 27  2012 /usr/lib/libwebkitgtk-1.0.so.0 -> libwebkitgtk-1.0.so.0.17.3
-rw-r--r-- 1 root root 26539176 Nov 27  2012 /usr/lib/libwebkitgtk-1.0.so.0.17.3
lrwxrwxrwx 1 root root       26 Nov 27  2012 /usr/lib/libwebkitgtk-3.0.so.0 -> libwebkitgtk-3.0.so.0.17.3
-rw-r--r-- 1 root root 26534984 Nov 27  2012 /usr/lib/libwebkitgtk-3.0.so.0.17.3

Made a dir inside my eclipse folder and switch to it
$ mkdir ~/Programs/eclipse_indigo/libs
$ cd ~/Programs/eclipse_indigo/libs


Copied the libwebkit libs there
$ (cd /usr/lib/ ;for file in libwebkitgtk-*; do cp ${file} ~/Programs/eclipse_indigo/libs/${file}; done);

Then removed the libs but created same named softlinks to /dev/null in their place
$ for file in *; do rm ${file}; ln -s /dev/null ${file}; done;

Then made a script to run eclipse that exports LD_LIBRARY_PATH with the afformentioned folder on it and then launches eclipse!

#!/bin/bash

export LD_LIBRARY_PATH=~/Programs/eclipse_indigo/libs;
./eclipse_executable;