diff options
author | Tor Norbye <tnorbye@google.com> | 2011-04-01 21:00:24 -0700 |
---|---|---|
committer | Tor Norbye <tnorbye@google.com> | 2011-04-01 21:00:24 -0700 |
commit | 50c6e4e3a17a7a562f45c71f826abca2a4b8740f (patch) | |
tree | 52cb49305166bec3c61ac1857215cebea8935858 /eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/editors/layout/gle2/LayoutCanvas.java | |
parent | ece8cb547d7d041e8525f033f8d83d6af3a4c954 (diff) | |
download | sdk-50c6e4e3a17a7a562f45c71f826abca2a4b8740f.tar.gz |
Improve painting of combined selection and hover
When the mouse is over a rectangle, we highlight this "hover"
rectangle by painting a semitranslucent white rectangle on top of it.
When a view is selected, we highlight it by painting a semitranslucent
blue rectangle over it.
This means that if you move the mouse over the selection, you get both
of these effects added together, which dilutes the underlying selected
widget too much.
This changeset tries to improve this situation by defining a different
visual style to be used for the combination of hover and selection,
where the opacity is much lower for the hover in this case.
This changeset also reduces the existing hover by about 30% opacity.
Change-Id: I63ffe8a9d756dcae29b2009a1a1cd6b9ffb6fbe7
Diffstat (limited to 'eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/editors/layout/gle2/LayoutCanvas.java')
-rwxr-xr-x | eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/editors/layout/gle2/LayoutCanvas.java | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/editors/layout/gle2/LayoutCanvas.java b/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/editors/layout/gle2/LayoutCanvas.java index b54e3d13a..719fdbfe7 100755 --- a/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/editors/layout/gle2/LayoutCanvas.java +++ b/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/editors/layout/gle2/LayoutCanvas.java @@ -261,7 +261,7 @@ public class LayoutCanvas extends Canvas { // --- Set up graphic overlays // mOutlineOverlay and mEmptyOverlay are initialized lazily - mHoverOverlay = new HoverOverlay(mHScale, mVScale); + mHoverOverlay = new HoverOverlay(this, mHScale, mVScale); mHoverOverlay.create(display); mSelectionOverlay = new SelectionOverlay(this); mSelectionOverlay.create(display); |