Bug 1489791 - Remove calendar-caption binding. r=MakeMyDay
authorArshad Khan <arshdkhn1@gmail.com>
Sat, 08 Sep 2018 22:12:36 +0530
changeset 33167 d197d42b67d83e5991554fa300ddeff7d1be5203
parent 33166 c6d36dbf6916a586fb2482c9c31f97fbaae40e04
child 33168 b027417cfd9fabc5e60db7e57b7d3047a0b99092
push id387
push userclokep@gmail.com
push dateMon, 10 Dec 2018 21:30:47 +0000
reviewersMakeMyDay
bugs1489791
Bug 1489791 - Remove calendar-caption binding. r=MakeMyDay
calendar/base/content/calendar-bindings.css
calendar/base/content/calendar-item-bindings.xml
calendar/base/content/dialogs/calendar-event-dialog-reminder.xul
calendar/base/content/dialogs/calendar-summary-dialog.xul
--- a/calendar/base/content/calendar-bindings.css
+++ b/calendar/base/content/calendar-bindings.css
@@ -1,46 +1,42 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 @namespace url("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul");
 
 
-calendar-day-view { 
+calendar-day-view {
   -moz-binding: url(chrome://calendar/content/calendar-views.xml#calendar-day-view);
 }
 
-calendar-week-view { 
+calendar-week-view {
   -moz-binding: url(chrome://calendar/content/calendar-views.xml#calendar-week-view);
 }
 
-calendar-multiweek-view { 
+calendar-multiweek-view {
   -moz-binding: url(chrome://calendar/content/calendar-views.xml#calendar-multiweek-view);
 }
 
 calendar-month-view {
   -moz-binding: url(chrome://calendar/content/calendar-views.xml#calendar-month-view);
 }
 
-calendar-task-tree { 
+calendar-task-tree {
   -moz-binding: url(chrome://calendar/content/calendar-task-tree.xml#calendar-task-tree);
 }
 
 menupopup[type="task-progress"] > arrowscrollbox {
   -moz-binding: url(chrome://calendar/content/calendar-menus.xml#task-progress-menupopup);
 }
 
 menupopup[type="task-priority"] > arrowscrollbox {
   -moz-binding: url(chrome://calendar/content/calendar-menus.xml#task-priority-menupopup);
 }
 
 task-menupopup {
   -moz-binding: url(chrome://calendar/content/calendar-menus.xml#task-menupopup);
 }
 
-calendar-caption {
-  -moz-binding: url("chrome://calendar/content/calendar-item-bindings.xml#calendar-caption");
-}
-
 .item-date-row {
   -moz-binding: url(chrome://calendar/content/calendar-item-bindings.xml#item-date-row);
 }
--- a/calendar/base/content/calendar-item-bindings.xml
+++ b/calendar/base/content/calendar-item-bindings.xml
@@ -5,24 +5,16 @@
 
 <!DOCTYPE bindings SYSTEM "chrome://calendar/locale/calendar.dtd">
 
 <bindings id="calendar-item-bindings"
           xmlns="http://www.mozilla.org/xbl"
           xmlns:xul="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
           xmlns:xbl="http://www.mozilla.org/xbl">
 
-  <!-- Header with a line beside it, used i.e in the event dialog -->
-  <binding id="calendar-caption" extends="xul:hbox">
-    <content align="center">
-      <xul:label xbl:inherits="value=label,control" class="header"/>
-      <xul:separator class="groove" flex="1"/>
-    </content>
-  </binding>
-
   <binding id="item-date-row" extends="xul:row">
     <content xbl:inherits="mode">
       <xul:label anonid="item-datetime-label"
                  class="headline"
                  xbl:inherits="align"/>
       <xul:textbox readonly="true"
                    class="selectable-label plain"
                    anonid="item-datetime-value"/>
--- a/calendar/base/content/dialogs/calendar-event-dialog-reminder.xul
+++ b/calendar/base/content/dialogs/calendar-event-dialog-reminder.xul
@@ -43,18 +43,20 @@
               oncommand="onNewReminder()"/>
       <button id="reminder-remove-button"
               label="&reminder.remove.label;"
               accesskey="&reminder.remove.accesskey;"
               oncommand="onRemoveReminder()"/>
     </hbox>
   </vbox>
 
-  <!-- Custom reminder details -->
-  <calendar-caption id="reminder-details-caption" label="&reminder.reminderDetails.label;"/>
+  <hbox id="reminder-details-caption" class="calendar-caption" align="center">
+    <label value="&reminder.reminderDetails.label;" class="header"/>
+    <separator class="groove" flex="1"/>
+  </hbox>
   <radiogroup id="reminder-relation-radiogroup"
                 onselect="setupRadioEnabledState(); updateReminder(event)">
     <hbox id="reminder-relative-box" align="top" flex="1">
       <radio id="reminder-relative-radio"
              value="relative"
              aria-labeledby="reminder-length reminder-unit reminder-relation reminder-origin"/>
       <vbox id="reminder-relative-box" flex="1">
         <hbox id="reminder-relative-length-unit-relation" flex="1">
@@ -95,20 +97,21 @@
     <hbox id="reminder-absolute-box" flex="1">
       <radio id="reminder-absolute-radio"
              control="reminder-absolute-date"
              value="absolute"/>
       <datetimepicker id="reminder-absolute-date"/>
     </hbox>
   </radiogroup>
 
-  <!-- Custom reminder action -->
-  <calendar-caption id="reminder-actions-caption"
-                    control="reminder-actions-menulist"
-                    label="&reminder.action.label;"/>
+  <hbox id="reminder-actions-caption" class="calendar-caption" align="center">
+    <label value="&reminder.action.label;" control="reminder-actions-menulist"
+           class="header"/>
+    <separator class="groove" flex="1"/>
+  </hbox>
   <menulist id="reminder-actions-menulist"
             oncommand="updateReminder(event)"
             class="reminder-icon">
     <!-- Make sure the id is formatted "reminder-action-<VALUE>", for accessibility -->
     <!-- TODO provider specific -->
     <menupopup id="reminder-actions-menupopup">
       <menuitem id="reminder-action-DISPLAY"
                 class="reminder-icon menuitem-iconic"
--- a/calendar/base/content/dialogs/calendar-summary-dialog.xul
+++ b/calendar/base/content/dialogs/calendar-summary-dialog.xul
@@ -124,17 +124,20 @@
       </toolbarbutton>
     </toolbar>
   </toolbox>
 
   <notificationbox id="status-notification"/>
 
   <!-- General -->
   <box id="item-general-box" orient="vertical">
-    <calendar-caption label="&read.only.general.label;"/>
+    <hbox id="item-general-caption" class="calendar-caption" align="center">
+      <label value="&read.only.general.label;" class="header"/>
+      <separator class="groove" flex="1"/>
+    </hbox>
     <box orient="horizontal">
       <grid flex="1">
         <columns>
           <column/>
           <column flex="1"/>
         </columns>
         <rows>
           <row align="center">
@@ -331,39 +334,48 @@
       </box>
       <box hidden="true" flex="1"/>
     </hbox>
   </vbox>
 
   <!-- Attendees -->
   <box id="item-attendees" orient="vertical" hidden="true" flex="1">
     <spacer class="default-spacer"/>
-    <calendar-caption label="&read.only.attendees.label;"
-                      control="item-attendees-box"/>
+    <hbox id="item-attendees-caption" class="calendar-caption" align="center">
+      <label value="&read.only.attendees.label;"
+             control="item-attendees-box" class="header"/>
+      <separator class="groove" flex="1"/>
+    </hbox>
     <vbox id="item-attendees-box" flex="1" />
   </box>
 
   <!-- Description -->
   <box id="item-description-box" hidden="true" orient="vertical" flex="1">
     <spacer class="default-spacer"/>
-    <calendar-caption label="&read.only.description.label;"
-                      control="item-description"/>
+    <hbox id="item-description-caption" class="calendar-caption" align="center">
+      <label value="&read.only.description.label;"
+             control="item-description" class="header"/>
+      <separator class="groove" flex="1"/>
+    </hbox>
     <box orient="horizontal" flex="1">
       <textbox id="item-description"
                multiline="true"
                rows="6"
                flex="1"/>
     </box>
   </box>
 
   <!-- URL link -->
   <box id="event-grid-link-row" hidden="true" orient="vertical">
     <spacer class="default-spacer"/>
-    <calendar-caption label="&read.only.link.label;"
-                      control="url-link"/>
+    <hbox id="event-grid-link-caption" class="calendar-caption" align="center">
+      <label value="&read.only.link.label;"
+             control="url-link" class="header"/>
+      <separator class="groove" flex="1"/>
+    </hbox>
     <label id="url-link"
            class="text-link default-indent"
            onclick="launchBrowser(this.getAttribute('href'), event)"
            oncommand="launchBrowser(this.getAttribute('href'), event)"
            crop="end"/>
   </box>
 
 </dialog>