OLD | NEW |
(Empty) | |
| 1 // Copyright 2016 Google Inc. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 // Open a pre-filled email to send feedback to the extension developers. The |
| 6 // initial content of the email depends on whether the URL of the current page |
| 7 // is provided. |
| 8 function reportPage(url) { |
| 9 var subject = chrome.i18n.getMessage('reportSubject'); |
| 10 var body = ''; |
| 11 if (url) |
| 12 body = chrome.i18n.getMessage('reportBodyWithURL', url); |
| 13 else |
| 14 body = chrome.i18n.getMessage('reportBody'); |
| 15 var msg = 'mailto:gobackwithbackspace@google.com' + |
| 16 '?subject=' + encodeURIComponent(subject) + |
| 17 '&body=' + encodeURIComponent(body); |
| 18 chrome.tabs.create({ |
| 19 url: msg, |
| 20 active: true}); |
| 21 } |
OLD | NEW |