[gtk+] Adwaita: generalize .has-open-popup
- From: Lapo Calamandrei <lapo src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+] Adwaita: generalize .has-open-popup
- Date: Fri, 23 Oct 2015 14:59:13 +0000 (UTC)
commit 4959fe326759b56140679bb688b3e9d05d24c74c
Author: Lapo Calamandrei <calamandrei gmail com>
Date: Fri Oct 23 16:58:17 2015 +0200
Adwaita: generalize .has-open-popup
so it works for any list-row istead of just the ones in a sidebar.
gtk/theme/Adwaita/_common.scss | 24 ++++++++++--------------
gtk/theme/Adwaita/gtk-contained-dark.css | 8 ++++----
gtk/theme/Adwaita/gtk-contained.css | 8 ++++----
3 files changed, 18 insertions(+), 22 deletions(-)
---
diff --git a/gtk/theme/Adwaita/_common.scss b/gtk/theme/Adwaita/_common.scss
index ee61b63..d5ba620 100644
--- a/gtk/theme/Adwaita/_common.scss
+++ b/gtk/theme/Adwaita/_common.scss
@@ -2542,20 +2542,19 @@ GtkScrolledWindow {
}
.list-row.activatable {
- // let's take care of background colors
- &:hover {
- //background-color: mix($fg_color, $base_color, 5%);
- background-color: if(variant == light, transparentize($fg_color, 0.9), transparentize($fg_color, 0.95));
- }
- &:active {
- box-shadow: inset 0 2px 2px -2px transparentize(black, 0.8);
- }
+ &.has-open-popup, // this is for indicathing which row generated a popover see
https://bugzilla.gnome.org/show_bug.cgi?id=754411
+ &:hover { background-color: if(variant == light, transparentize($fg_color, 0.9), transparentize($fg_color,
0.95)); }
+
+ &:active { box-shadow: inset 0 2px 2px -2px transparentize(black, 0.8); }
+
&:backdrop:hover { background-color: transparent; }
+
&:selected {
&:active { box-shadow: inset 0 2px 3px -1px transparentize(black, 0.5); }
- &:hover {
- background-color: mix($fg_color, $selected_bg_color, 10%);
- }
+
+ &.has-open-popup,
+ &:hover { background-color: mix($fg_color, $selected_bg_color, 10%); }
+
&:backdrop { background-color: $selected_bg_color; }
}
}
@@ -2895,9 +2894,6 @@ GtkPlacesSidebar.sidebar {
&:not(:hover):not(:active) > image,
&:backdrop > image { opacity: $_placesidebar_icons_opacity };
}
- // this is for indicating which sidebar row generated a popover
- // see https://bugzilla.gnome.org/show_bug.cgi?id=754411
- .has-open-popup { @extend .list-row.activatable:hover; }
}
.sidebar-item {
diff --git a/gtk/theme/Adwaita/gtk-contained-dark.css b/gtk/theme/Adwaita/gtk-contained-dark.css
index c4b1391..e550622 100644
--- a/gtk/theme/Adwaita/gtk-contained-dark.css
+++ b/gtk/theme/Adwaita/gtk-contained-dark.css
@@ -3471,15 +3471,15 @@ GtkScrolledWindow GtkViewport.frame {
.grid-child {
padding: 2px; }
-.list-row.activatable:hover, GtkPlacesSidebar.sidebar .has-open-popup {
+.list-row.activatable.has-open-popup, .list-row.activatable:hover {
background-color: rgba(238, 238, 236, 0.05); }
.list-row.activatable:active {
box-shadow: inset 0 2px 2px -2px rgba(0, 0, 0, 0.2); }
-.list-row.activatable:backdrop:hover, GtkPlacesSidebar.sidebar .has-open-popup:backdrop {
+.list-row.activatable:backdrop:hover {
background-color: transparent; }
.list-row.activatable:selected:active {
box-shadow: inset 0 2px 3px -1px rgba(0, 0, 0, 0.5); }
-.list-row.activatable:selected:hover, GtkPlacesSidebar.sidebar .has-open-popup:selected {
+.list-row.activatable:selected.has-open-popup, .list-row.activatable:selected:hover {
background-color: #366ca4; }
.list-row.activatable:selected:backdrop {
background-color: #215d9c; }
@@ -3977,7 +3977,7 @@ GtkPlacesView .server-list-button > image {
GtkPlacesView .server-list-button:checked > image {
transition: 200ms cubic-bezier(0.25, 0.46, 0.45, 0.94);
-gtk-icon-transform: rotate(-0.5turn); }
-GtkPlacesView .list-row.activatable:hover, GtkPlacesView GtkPlacesSidebar.sidebar .has-open-popup,
GtkPlacesSidebar.sidebar GtkPlacesView .has-open-popup {
+GtkPlacesView .list-row.activatable:hover {
background-color: transparent; }
/*********
diff --git a/gtk/theme/Adwaita/gtk-contained.css b/gtk/theme/Adwaita/gtk-contained.css
index a2baf59..edd406d 100644
--- a/gtk/theme/Adwaita/gtk-contained.css
+++ b/gtk/theme/Adwaita/gtk-contained.css
@@ -3633,15 +3633,15 @@ GtkScrolledWindow GtkViewport.frame {
.grid-child {
padding: 2px; }
-.list-row.activatable:hover, GtkPlacesSidebar.sidebar .has-open-popup {
+.list-row.activatable.has-open-popup, .list-row.activatable:hover {
background-color: rgba(46, 52, 54, 0.05); }
.list-row.activatable:active {
box-shadow: inset 0 2px 2px -2px rgba(0, 0, 0, 0.2); }
-.list-row.activatable:backdrop:hover, GtkPlacesSidebar.sidebar .has-open-popup:backdrop {
+.list-row.activatable:backdrop:hover {
background-color: transparent; }
.list-row.activatable:selected:active {
box-shadow: inset 0 2px 3px -1px rgba(0, 0, 0, 0.5); }
-.list-row.activatable:selected:hover, GtkPlacesSidebar.sidebar .has-open-popup:selected {
+.list-row.activatable:selected.has-open-popup, .list-row.activatable:selected:hover {
background-color: #4787c9; }
.list-row.activatable:selected:backdrop {
background-color: #4a90d9; }
@@ -4149,7 +4149,7 @@ GtkPlacesView .server-list-button > image {
GtkPlacesView .server-list-button:checked > image {
transition: 200ms cubic-bezier(0.25, 0.46, 0.45, 0.94);
-gtk-icon-transform: rotate(-0.5turn); }
-GtkPlacesView .list-row.activatable:hover, GtkPlacesView GtkPlacesSidebar.sidebar .has-open-popup,
GtkPlacesSidebar.sidebar GtkPlacesView .has-open-popup {
+GtkPlacesView .list-row.activatable:hover {
background-color: transparent; }
/*********
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]