Bug 1162442: add tooltips to the context edit and close buttons inside the Loop conversation window. r=Standard8
authorMike de Boer <mdeboer@mozilla.com>
Fri, 08 May 2015 12:30:42 +0200
changeset 260128 54fc944ba4a4f616fc8d5920abc57e9d33205a98
parent 260127 201c323dcf16f47ae0d35bfd5ca50bb07ac04b46
child 260129 b7c36b1d035f9d8a9c5b2ce65432bf9ce52cc213
push id4830
push userjlund@mozilla.com
push dateMon, 29 Jun 2015 20:18:48 +0000
treeherdermozilla-esr52@4c2175bb0420 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersStandard8
bugs1162442
milestone40.0a1
Bug 1162442: add tooltips to the context edit and close buttons inside the Loop conversation window. r=Standard8
browser/components/loop/content/js/roomViews.js
browser/components/loop/content/js/roomViews.jsx
browser/locales/en-US/chrome/browser/loop/loop.properties
--- a/browser/components/loop/content/js/roomViews.js
+++ b/browser/components/loop/content/js/roomViews.js
@@ -507,17 +507,18 @@ loop.roomViews = (function(mozL10n) {
                   valueLink: this.linkState("newRoomURL")}), 
                 React.createElement("textarea", {rows: "4", type: "text", className: "room-context-comments", 
                   onBlur: this.handleFormSubmit, 
                   onKeyDown: this.handleTextareaKeyDown, 
                   placeholder: mozL10n.get("context_edit_comments_placeholder"), 
                   valueLink: this.linkState("newRoomDescription")})
               ), 
               React.createElement("button", {className: "room-context-btn-close", 
-                      onClick: this.handleCloseClick})
+                      onClick: this.handleCloseClick, 
+                      title: mozL10n.get("cancel_button")})
             )
           )
         );
       }
 
       if (!locationData) {
         return null;
       }
@@ -532,19 +533,21 @@ loop.roomViews = (function(mozL10n) {
             React.createElement("a", {className: "room-context-url", 
                href: location, 
                target: "_blank", 
                title: locationData.location}, locationData.hostname), 
             this.props.roomData.roomDescription ?
               React.createElement("div", {className: "room-context-comment"}, this.props.roomData.roomDescription) :
               null, 
             React.createElement("button", {className: "room-context-btn-close", 
-                    onClick: this.handleCloseClick}), 
+                    onClick: this.handleCloseClick, 
+                    title: mozL10n.get("context_hide_tooltip")}), 
             React.createElement("button", {className: "room-context-btn-edit", 
-                    onClick: this.handleEditClick})
+                    onClick: this.handleEditClick, 
+                    title: mozL10n.get("context_edit_tooltip")})
           )
         )
       );
     }
   });
 
   /**
    * Desktop room conversation view.
--- a/browser/components/loop/content/js/roomViews.jsx
+++ b/browser/components/loop/content/js/roomViews.jsx
@@ -507,17 +507,18 @@ loop.roomViews = (function(mozL10n) {
                   valueLink={this.linkState("newRoomURL")} />
                 <textarea rows="4" type="text" className="room-context-comments"
                   onBlur={this.handleFormSubmit}
                   onKeyDown={this.handleTextareaKeyDown}
                   placeholder={mozL10n.get("context_edit_comments_placeholder")}
                   valueLink={this.linkState("newRoomDescription")} />
               </form>
               <button className="room-context-btn-close"
-                      onClick={this.handleCloseClick}/>
+                      onClick={this.handleCloseClick}
+                      title={mozL10n.get("cancel_button")}/>
             </div>
           </div>
         );
       }
 
       if (!locationData) {
         return null;
       }
@@ -532,19 +533,21 @@ loop.roomViews = (function(mozL10n) {
             <a className="room-context-url"
                href={location}
                target="_blank"
                title={locationData.location}>{locationData.hostname}</a>
             {this.props.roomData.roomDescription ?
               <div className="room-context-comment">{this.props.roomData.roomDescription}</div> :
               null}
             <button className="room-context-btn-close"
-                    onClick={this.handleCloseClick}/>
+                    onClick={this.handleCloseClick}
+                    title={mozL10n.get("context_hide_tooltip")}/>
             <button className="room-context-btn-edit"
-                    onClick={this.handleEditClick}/>
+                    onClick={this.handleEditClick}
+                    title={mozL10n.get("context_edit_tooltip")}/>
           </div>
         </div>
       );
     }
   });
 
   /**
    * Desktop room conversation view.
--- a/browser/locales/en-US/chrome/browser/loop/loop.properties
+++ b/browser/locales/en-US/chrome/browser/loop/loop.properties
@@ -335,8 +335,11 @@ context_offer_label=Let's talk about thi
 context_inroom_label=Let's talk about:
 ## LOCALIZATION_NOTE (context_edit_activate_label): {{title}} will be replaced
 ## by the title of the active tab, also known as the title of an HTML document.
 ## The quotes around the title are intentional.
 context_edit_activate_label=Talk about "{{title}}"
 context_edit_name_placeholder=Conversation Name
 context_edit_comments_placeholder=Comments
 context_add_some_label=Add some context
+context_edit_tooltip=Edit Context
+context_hide_tooltip=Hide Context
+context_show_tooltip=Show Context