[gtk+] Adwaita: style flowbox tiles



commit 6fe1d30e6291a1ce59dd0d1a600469c07e93c84c
Author: Jakub Steiner <jimmac gmail com>
Date:   Thu Feb 16 20:34:50 2017 +0100

    Adwaita: style flowbox tiles
    
    + fixups by Daniel Boles from gtk-3-22
    
    https://bugzilla.gnome.org/show_bug.cgi?id=779073

 gtk/theme/Adwaita/_common.scss           |   12 +++++++++++-
 gtk/theme/Adwaita/gtk-contained-dark.css |   15 +++++++++++++--
 gtk/theme/Adwaita/gtk-contained.css      |   15 +++++++++++++--
 3 files changed, 37 insertions(+), 5 deletions(-)
---
diff --git a/gtk/theme/Adwaita/_common.scss b/gtk/theme/Adwaita/_common.scss
index c168b66..eade9e2 100644
--- a/gtk/theme/Adwaita/_common.scss
+++ b/gtk/theme/Adwaita/_common.scss
@@ -139,7 +139,6 @@ flowbox {
 
   flowboxchild {
     padding: 3px;
-    border-radius: 3px;
 
     &:selected {
       @extend %selected_items;
@@ -149,6 +148,17 @@ flowbox {
   }
 }
 
+.content-view .tile {
+  margin: 2px;
+  background-color: if($variant=='light', transparent, black);
+  border-radius: 0;
+  padding: 0;
+
+  &:backdrop { background-color: if($variant=='light', transparent, darken($backdrop_base_color,5%)); }
+  &:active, &:selected { background-color: if($variant=='light', transparent, $selected_bg_color); }
+  &:disabled { background-color: if($variant=='light', transparent, $insensitive_bg_color); }
+}
+
 label {
   caret-color: currentColor; // this shouldn't be needed.
 
diff --git a/gtk/theme/Adwaita/gtk-contained-dark.css b/gtk/theme/Adwaita/gtk-contained-dark.css
index 270d140..71eb863 100644
--- a/gtk/theme/Adwaita/gtk-contained-dark.css
+++ b/gtk/theme/Adwaita/gtk-contained-dark.css
@@ -97,11 +97,22 @@ treeview.view rubberband,
   background-color: rgba(24, 68, 114, 0.2); }
 
 flowbox flowboxchild {
-  padding: 3px;
-  border-radius: 3px; }
+  padding: 3px; }
   flowbox flowboxchild:selected {
     outline-offset: -2px; }
 
+.content-view .tile {
+  margin: 2px;
+  background-color: black;
+  border-radius: 0;
+  padding: 0; }
+  .content-view .tile:backdrop {
+    background-color: #1a1d1e; }
+  .content-view .tile:active, .content-view .tile:selected {
+    background-color: #215d9c; }
+  .content-view .tile:disabled {
+    background-color: #2d3234; }
+
 label {
   caret-color: currentColor; }
   label.separator {
diff --git a/gtk/theme/Adwaita/gtk-contained.css b/gtk/theme/Adwaita/gtk-contained.css
index 07f8b2a..de9c23f 100644
--- a/gtk/theme/Adwaita/gtk-contained.css
+++ b/gtk/theme/Adwaita/gtk-contained.css
@@ -97,11 +97,22 @@ treeview.view rubberband,
   background-color: rgba(42, 118, 198, 0.2); }
 
 flowbox flowboxchild {
-  padding: 3px;
-  border-radius: 3px; }
+  padding: 3px; }
   flowbox flowboxchild:selected {
     outline-offset: -2px; }
 
+.content-view .tile {
+  margin: 2px;
+  background-color: transparent;
+  border-radius: 0;
+  padding: 0; }
+  .content-view .tile:backdrop {
+    background-color: transparent; }
+  .content-view .tile:active, .content-view .tile:selected {
+    background-color: transparent; }
+  .content-view .tile:disabled {
+    background-color: transparent; }
+
 label {
   caret-color: currentColor; }
   label.separator {


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]