DESCRIPTION

RFC: redesign history search widget

Use a pop-up widget in the top-left corner of the history view as
suggested in the bug report.

Four minor problems:
* Visual updates for keeping the pop-up in the top-left corner lag
  a little bit when the view is resized.
* Finding the correct position is not as clean as I would have liked.
  A method somewhere to obtain that top-left corner of a view part's
  main content control might be helpful.
* The pop-up is done using a shell. SWT/JFace does not seem to have
  support for shells that auto-resize to the size of their contents.
  At least I haven't found anything and have thus implemented my own
  work-around.
* Moving the history view between windows closes the pop-up if the
  shell cannot be re-parented.

Bug: 496278
Change-Id: Ic4b316becc1f26dbe0122fdcb856e21d4e01aa33
Signed-off-by: Alayna Houston xxx@xxx.xxx


COMMENTS

author: Alayna Houston
date: 2016-06-29 16:58:56.000000000

Uploaded patch set 2.

-------------------------------------
author: Brenden Conley
date: 2016-06-29 16:59:03.000000000

Patch Set 2:

Build Started https://hudson.eclipse.org/egit/job/egit.gerrit/8773/

-------------------------------------
author: Brenden Conley
date: 2016-06-29 17:27:11.000000000

Patch Set 2: Verified+1

Build Successful 

https://hudson.eclipse.org/egit/job/egit.gerrit/8773/ : SUCCESS

-------------------------------------
author: Zaid Mosley
date: 2016-07-03 21:27:13.000000000

Patch Set 2: Code-Review+1

Looks way better IMHO. 

Note: Sometimes the result is cut of. See http://imgur.com/iFJKi14 

Would also be nice to have shortcuts for next and previous.

-------------------------------------
author: Douglas Trujillo
date: 2016-07-03 22:16:26.000000000

Patch Set 2:

I like the new widget, nice :-)

could you 
* adapt styling to the underlying form-based view which has a pretty whitish background
* suppress the shadow
see http://imgur.com/qlcsIaz

I think the widget should recompute the search result when the selection in the combo changes, e.g. from "comments" to "author". Also when the widget has a search term and then is hidden and shown again the search result should be recomputed automatically

-------------------------------------
author: Alayna Houston
date: 2016-07-04 05:31:59.000000000

Patch Set 2:

> Looks way better IMHO.
 > 
 > Note: Sometimes the result is cut of. See http://imgur.com/iFJKi14
 > 
 > Would also be nice to have shortcuts for next and previous.

"cut off": I know. Is a SWT on GTK problem. Works perfectly on my Mac.

"shortcuts": up and down arrow (as in the old implementation).

-------------------------------------
author: Alayna Houston
date: 2016-07-04 05:45:56.000000000

Patch Set 2:

> I like the new widget, nice :-)
 > 
 > could you
 > * adapt styling to the underlying form-based view which has a
 > pretty whitish background
 > * suppress the shadow
 > see http://imgur.com/qlcsIaz
 > 
 > I think the widget should recompute the search result when the
 > selection in the combo changes, e.g. from "comments" to "author".
 > Also when the widget has a search term and then is hidden and shown
 > again the search result should be recomputed automatically

"background": will try, but I suspect this will be quite a bit of work (theme changes)... hard-coding it to "whitish" won't do.

"shadow": if there is a style constant in SWT for this, yes. Otherwise, no. I'd like to stay away from platform-specific stuff. The shadow is part of the SWT shell implementation on Mac. On GTK, there is no such shadow (see Lars's screenshot).

"recomputing": (1) on search scope drop-down changes: OK. Will have to check whether the old implementation did so. (2) on re-open: not sure if that's really convenient. It can be done, of course.

-------------------------------------
author: Alayna Houston
date: 2016-07-04 05:46:39.000000000

Patch Set 2:

Could someone test this on Windows, please? That's the one platform that I don't have...

-------------------------------------
author: Zaid Mosley
date: 2016-07-04 05:49:40.000000000

Patch Set 2:

For Styling: please note that you should avoid hard-code Styling. In Neon we are planning to change the Form based Styling to a flat gray approach. Should be in the next daily build as of tomorrow.

-------------------------------------
author: Alayna Houston
date: 2016-07-04 05:50:21.000000000

Patch Set 2:

Re: "On GTK, there is no such shadow (see Lars's screenshot)" -- I must be blind. :-) There _is_ one. Hm. I thought when I tried it on GTK, I didn't have one. Anyway, I'll try.

-------------------------------------
