[epiphany] Make incognito page adaptive



commit 366275b6d72c7c109338506e9c15c156531971d8
Author: Jan-Michael Brummer <jan brummer tabos org>
Date:   Fri Apr 19 19:04:58 2019 +0200

    Make incognito page adaptive
    
    Fixes: https://gitlab.gnome.org/GNOME/epiphany/issues/653

 embed/ephy-about-handler.c | 12 +++++-------
 src/resources/about.css    | 31 ++++++++++++++-----------------
 2 files changed, 19 insertions(+), 24 deletions(-)
---
diff --git a/embed/ephy-about-handler.c b/embed/ephy-about-handler.c
index 787469be8..2bbf1c90e 100644
--- a/embed/ephy-about-handler.c
+++ b/embed/ephy-about-handler.c
@@ -446,13 +446,11 @@ ephy_about_handler_handle_incognito (EphyAboutHandler       *handler,
                           "<link href=\""EPHY_PAGE_TEMPLATE_ABOUT_CSS "\" rel=\"stylesheet\" 
type=\"text/css\">\n"
                           "</head>\n"
                           "<body class=\"incognito-body\">\n"
-                          "  <div id=\"mainblock\">\n"
-                          "    <div style=\"background: transparent 
url(ephy-resource:///org/gnome/epiphany/private-mode.svg) no-repeat 10px center;\">\n" \
-                          "      <h1>%s</h1>\n"
-                          "      <p>%s</p>\n"
-                          "      <p><strong>%s</strong> %s</p>\n"
-                          "    </div>\n"
-                          "  </div>\n"
+                          "  <img class=\"incognito-body-image\" 
src=\"ephy-resource:///org/gnome/epiphany/private-mode.svg\">\n" \
+                          "  <br/>\n"
+                          "  <h1>%s</h1>\n"
+                          "  <p>%s</p>\n"
+                          "  <p><strong>%s</strong> %s</p>\n"
                           "</body>\n"
                           "</div>\n"
                           "</html>\n",
diff --git a/src/resources/about.css b/src/resources/about.css
index e85a87c4d..ad2e198e3 100644
--- a/src/resources/about.css
+++ b/src/resources/about.css
@@ -178,27 +178,24 @@ html.epiphany-html {
 /* about:incognito */
 
 .incognito-body {
-    margin: 0;
-    padding: 0;
-}
-
-.incognito-body div#mainblock {
-    display: table;
-    max-width: 40em;
-    margin-left: auto;
-    margin-right: auto;
-    height: 75%;
-}
-
-.incognito-body div#mainblock>div {
-    margin: 0 10px;
-    display: table-cell;
-    vertical-align: middle;
-    padding: 0 20px 0 160px;
+    box-sizing:border-box;
+    display:flex;
+    flex-direction: column;
+    justify-content: center;
+    max-width:40em;
+    margin: 30px auto 60px;
+    text-align:block;
+    line-height: 1.5;
 }
 
 .incognito-body h1 {
     color: #888a85;
+    text-align:center;
+}
+
+.incognito-body-image {
+    margin:auto;
+    display:block;
 }
 
 /* about:overview */


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