loleaflet/css/loleaflet.css      |  172 ++++++++++++++++++++-------------------
 loleaflet/html/loleaflet.html.m4 |    8 -
 loleaflet/src/map/Map.js         |    5 +
 3 files changed, 100 insertions(+), 85 deletions(-)

New commits:
commit 59e728da9452cff6de6ea69af822919cff51816e
Author:     Szymon Kłos <szymon.k...@collabora.com>
AuthorDate: Tue Jan 29 20:51:16 2019 +0100
Commit:     Szymon Kłos <szymon.k...@collabora.com>
CommitDate: Tue Jan 29 21:19:46 2019 +0100

    Unify whitespaces in loleaflet.css
    
    Change-Id: I6d916acac8f6b7d4c71eab4fd63b5e13d61be4a1

diff --git a/loleaflet/css/loleaflet.css b/loleaflet/css/loleaflet.css
index d42c7c4e4..798612ca7 100644
--- a/loleaflet/css/loleaflet.css
+++ b/loleaflet/css/loleaflet.css
@@ -13,11 +13,11 @@
 }
 
 #document-container.readonly {
-    top: 36px;
+       top: 36px;
 }
 
 #toolbar-wrapper.readonly {
-    display: none;
+       display: none;
 }
 
 #map {
@@ -36,111 +36,112 @@
 }
 
 .loleaflet-scrollbar-show {
-    opacity: 1 !important;
-    filter: "alpha(opacity=100)" !important;
-    -ms-filter: "alpha(opacity=100)" !important;
+       opacity: 1 !important;
+       filter: "alpha(opacity=100)" !important;
+       -ms-filter: "alpha(opacity=100)" !important;
 }
 
 body {
-    margin: 0;
-    overflow: hidden;
-    overscroll-behavior-y: none; /* disable the pull to reload gesture */
-    background: #ffffff;
-    touch-action: none;
+       margin: 0;
+       overflow: hidden;
+       overscroll-behavior-y: none; /* disable the pull to reload gesture */
+       background: #ffffff;
+       touch-action: none;
 }
 
 #presentation-controls-wrapper {
-    background: #dfdfdf;
-    position: absolute;
-    top: 77px;
-    left: 0px;
-    bottom: 66px;
-    max-width: 218px;
-    border-top: 1px solid #b6b6b6;
-    display: block;
+       background: #dfdfdf;
+       position: absolute;
+       top: 77px;
+       left: 0px;
+       bottom: 66px;
+       max-width: 218px;
+       border-top: 1px solid #b6b6b6;
+       display: block;
 }
 
 #presentation-controls-wrapper.drawing {
-    bottom: 40px; /* Hide the presentation toolbar (insert slide etc.) for 
doctype = drawing */
+       bottom: 40px; /* Hide the presentation toolbar (insert slide etc.) for 
doctype = drawing */
 }
 
 #presentation-controls-wrapper.readonly {
-    top: 36px;
+       top: 36px;
 }
 
 #toolbar-wrapper {
-    position: relative;
-    table-layout: fixed;
-    border-collapse: collapse;
+       position: relative;
+       table-layout: fixed;
+       border-collapse: collapse;
        width: 100%;
        border-top: 1px solid #bbbbbb;
 }
 
 #toolbar-logo {
-    width: 0;
+       width: 0;
 }
 
 #toolbar-hamburger {
-    width: 0;
+       width: 0;
 }
 
 #mobile-edit-button {
-    position: absolute;
-    width: 56px;
-    height: 56px;
-    right: 16px;
-    bottom: 16px;
-    background-color: #0b87e7;
-    border-radius: 50%;
-    box-shadow: 0 4px 8px 0 rgba(0, 0, 0, 0.2), 0 6px 20px 0 rgba(0, 0, 0, 
0.19);
-    z-index: 2000;
+       position: absolute;
+       width: 56px;
+       height: 56px;
+       right: 16px;
+       bottom: 16px;
+       background-color: #0b87e7;
+       border-radius: 50%;
+       box-shadow: 0 4px 8px 0 rgba(0, 0, 0, 0.2), 0 6px 20px 0 rgba(0, 0, 0, 
0.19);
+       z-index: 2000;
 }
 
 #mobile-edit-button-image {
-    position: relative;
-    left: 16px;
-    top: 16px;
-    width: 24px;
-    height: 24px;
-    background: url('images/baseline-edit-24px.svg') no-repeat center 
!important;
+       position: relative;
+       left: 16px;
+       top: 16px;
+       width: 24px;
+       height: 24px;
+       background: url('images/baseline-edit-24px.svg') no-repeat center 
!important;
 }
 
 @media (max-width: 767px),(max-device-height: 767px) {
-    /* Show slidesorter beyond 768px only */
-    #presentation-controls-wrapper {
+       /* Show slidesorter beyond 768px only */
+       #presentation-controls-wrapper {
        display: none;
-    }
+       }
 
-    #document-container.tablet {
-        top: 41px;
-    }
+       #document-container.tablet {
+               top: 41px;
+       }
 
-    #document-container.readonly {
-        top: 41px;
-    }
+       #document-container.readonly {
+               top: 41px;
+       }
 
-    #document-container.parts-preview-document {
+       #document-container.parts-preview-document {
        left: 0px !important;
-    }
-    #document-container.spreadsheet-document {
+       }
+       #document-container.spreadsheet-document {
        top: 103px !important;
-    }
-    #document-container.spreadsheet-document.readonly {
+       }
+       #document-container.spreadsheet-document.readonly {
        top: 61px !important;
-    }
-    #document-container {
+       }
+       #document-container {
        top: 41px;
-    }
-    #spreadsheet-row-column-frame {
+
+       }
+       #spreadsheet-row-column-frame {
        top: 83px !important;
-    }
-    #spreadsheet-row-column-frame.readonly {
+       }
+       #spreadsheet-row-column-frame.readonly {
        top: 41px !important;
-    }
-    #toolbar-hamburger {
+       }
+       #toolbar-hamburger {
        width: 41px;
-    }
-    #closebuttonwrapper {
+       }
+       #closebuttonwrapper {
        display: none;
        }
        /* Show menubar even if folded */
@@ -150,9 +151,9 @@ body {
 }
 
 .loleaflet-font {
-    font-family: "Segoe UI", Tahoma, Arial, Helvetica, sans-serif !important;
-    font-size: 12px !important;
-    font-weight: normal !important;
+       font-family: "Segoe UI", Tahoma, Arial, Helvetica, sans-serif 
!important;
+       font-size: 12px !important;
+       font-weight: normal !important;
 }
 
 .loleaflet-character {
@@ -248,8 +249,8 @@ body {
 }
 
 .loleaflet-dont-break {
-        /* These are technically the same, but use both */
-        overflow-wrap: break-word;
+               /* These are technically the same, but use both */
+               overflow-wrap: break-word;
        word-wrap: break-word;
 
        /* Don't eat new lines  */
@@ -313,32 +314,32 @@ body {
 
 .loleaflet-annotation-menu, .loleaflet-annotation-menu-redline, 
.loleaflet-redline-accept-button, .loleaflet-redline-reject-button {
        margin: 0;
-        padding: 0;
-        width: 24px;
-        height: 24px;
+               padding: 0;
+               width: 24px;
+               height: 24px;
        vertical-align: top;
        border: 1px solid transparent;
        display: inline-block;
 }
 
 .loleaflet-redline-accept-button {
-        background: url('images/lc_accepttrackedchanges.svg') no-repeat center 
!important;
+               background: url('images/lc_accepttrackedchanges.svg') no-repeat 
center !important;
 }
 
 .loleaflet-redline-reject-button {
-        background: url('images/lc_rejecttrackedchange.svg') no-repeat center 
!important;
+               background: url('images/lc_rejecttrackedchange.svg') no-repeat 
center !important;
 }
 
 .loleaflet-context-copy {
-        background: url('images/lc_copy.svg') no-repeat center !important;
+               background: url('images/lc_copy.svg') no-repeat center 
!important;
 }
 
 .loleaflet-context-cut {
-        background: url('images/lc_cut.svg') no-repeat center !important;
+               background: url('images/lc_cut.svg') no-repeat center 
!important;
 }
 
 .loleaflet-context-paste {
-        background: url('images/lc_paste.svg') no-repeat center !important;
+               background: url('images/lc_paste.svg') no-repeat center 
!important;
 }
 
 .loleaflet-annotation-menu, .loleaflet-annotation-menu-redline {
@@ -366,7 +367,7 @@ body {
 }
 
 .loleaflet-annotation-caption {
-        font-weight: bold;
+               font-weight: bold;
 }
 
 .loleaflet-bar {
@@ -449,14 +450,14 @@ body {
 }
 
 .lokdialog_canvas {
-        cursor: default;
-        display: block; /* required to remove all borders around canvas 
element */
-        caret-color: transparent; /* firefox shows a caret otherwise on 
top-left of the canvas */
-        user-select: none;
-        -moz-user-select: none;
-        -khtml-user-select: none;
-        -webkit-user-select: none;
-        -o-user-select: none;
+               cursor: default;
+               display: block; /* required to remove all borders around canvas 
element */
+               caret-color: transparent; /* firefox shows a caret otherwise on 
top-left of the canvas */
+               user-select: none;
+               -moz-user-select: none;
+               -khtml-user-select: none;
+               -webkit-user-select: none;
+               -o-user-select: none;
 }
 
 /* Infobar */
commit 6348d9fe50746c8a6494ab9ed50f6a9e1ad22a56
Author:     Szymon Kłos <szymon.k...@collabora.com>
AuthorDate: Tue Jan 29 16:43:23 2019 +0100
Commit:     Szymon Kłos <szymon.k...@collabora.com>
CommitDate: Tue Jan 29 21:19:34 2019 +0100

    Reduce readonly toolbar height
    
    Change-Id: I431a2f3e87374a1cb6cb75557cb0d1eecccf17d0

diff --git a/loleaflet/css/loleaflet.css b/loleaflet/css/loleaflet.css
index fefaab466..d42c7c4e4 100644
--- a/loleaflet/css/loleaflet.css
+++ b/loleaflet/css/loleaflet.css
@@ -9,11 +9,11 @@
 }
 
 #document-container.tablet {
-       top: 41px;
+       top: 36px;
 }
 
 #document-container.readonly {
-    top: 41px;
+    top: 36px;
 }
 
 #toolbar-wrapper.readonly {
@@ -65,7 +65,7 @@ body {
 }
 
 #presentation-controls-wrapper.readonly {
-    top: 41px;
+    top: 36px;
 }
 
 #toolbar-wrapper {
@@ -110,6 +110,15 @@ body {
     #presentation-controls-wrapper {
        display: none;
     }
+
+    #document-container.tablet {
+        top: 41px;
+    }
+
+    #document-container.readonly {
+        top: 41px;
+    }
+
     #document-container.parts-preview-document {
        left: 0px !important;
     }
commit b4192f75ea1d3fa87cd5897b62f44660f6c2a223
Author:     Szymon Kłos <szymon.k...@collabora.com>
AuthorDate: Tue Jan 29 17:46:05 2019 +0100
Commit:     Szymon Kłos <szymon.k...@collabora.com>
CommitDate: Tue Jan 29 21:06:44 2019 +0100

    Start with readonly UI, then extend
    
    Change-Id: I96352890e9a76107aa1c1df9cf4f5979688a1969

diff --git a/loleaflet/html/loleaflet.html.m4 b/loleaflet/html/loleaflet.html.m4
index c8cf895c6..96bd3704e 100644
--- a/loleaflet/html/loleaflet.html.m4
+++ b/loleaflet/html/loleaflet.html.m4
@@ -87,7 +87,7 @@ ifelse(MOBILEAPP,[true],
        </div>
        <!-- Mobile menu toggle button (hamburger/x icon) -->
        <input id="main-menu-state" type="checkbox" style="display: none"/>
-       <ul id="main-menu" class="sm sm-simple lo-menu"></ul>
+       <ul id="main-menu" class="sm sm-simple lo-menu readonly"></ul>
        <div id="document-titlebar">
          <div class="document-title">
            <input id="document-name-input" type="text" disabled="true" 
style="display: none"/>
@@ -121,15 +121,15 @@ ifelse(MOBILEAPP,[true],
       <div class="closebuttonimage" id="closebutton"></div>
     </div>
 
-    <div id="spreadsheet-row-column-frame"></div>
+    <div id="spreadsheet-row-column-frame" class="readonly"></div>
 
-    <div id="document-container">
+    <div id="document-container" class="readonly">
       <div id="map"></div>
     </div>
 
     <div id="spreadsheet-toolbar" style="display: none"></div>
 
-    <div id="presentation-controls-wrapper">
+    <div id="presentation-controls-wrapper" class="readonly">
       <div id="slide-sorter"></div>
       <div id="presentation-toolbar" style="display: none"></div>
     </div>
diff --git a/loleaflet/src/map/Map.js b/loleaflet/src/map/Map.js
index ca76a11da..06e26f6ca 100644
--- a/loleaflet/src/map/Map.js
+++ b/loleaflet/src/map/Map.js
@@ -56,6 +56,11 @@ L.Map = L.Evented.extend({
                // hack for https://github.com/Leaflet/Leaflet/issues/1980
                this._onResize = L.bind(this._onResize, this);
 
+               // Start with readonly toolbars on desktop
+               if (!L.Browser.mobile) {
+                       L.DomUtil.addClass(L.DomUtil.get('toolbar-wrapper'), 
'readonly');
+               }
+
                this._initEvents();
 
                if (options.maxBounds) {
_______________________________________________
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to