OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 /** | 5 /** |
6 * @fileoverview | 6 * @fileoverview |
7 * Class representing the application's context menu. | 7 * Class representing the application's context menu. |
8 */ | 8 */ |
9 | 9 |
10 'use strict'; | 10 'use strict'; |
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
58 rttMs < 50 ? /*i18n-content*/'CONNECTION_QUALITY_GOOD' : | 58 rttMs < 50 ? /*i18n-content*/'CONNECTION_QUALITY_GOOD' : |
59 rttMs < 100 ? /*i18n-content*/'CONNECTION_QUALITY_FAIR' : | 59 rttMs < 100 ? /*i18n-content*/'CONNECTION_QUALITY_FAIR' : |
60 /*i18n-content*/'CONNECTION_QUALITY_POOR'; | 60 /*i18n-content*/'CONNECTION_QUALITY_POOR'; |
61 rttText = l10n.getTranslationOrError(rttText); | 61 rttText = l10n.getTranslationOrError(rttText); |
62 this.adapter_.updateTitle( | 62 this.adapter_.updateTitle( |
63 remoting.ApplicationContextMenu.kShowStatsId, | 63 remoting.ApplicationContextMenu.kShowStatsId, |
64 l10n.getTranslationOrError(/*i18n-content*/'SHOW_STATS_WITH_RTT', | 64 l10n.getTranslationOrError(/*i18n-content*/'SHOW_STATS_WITH_RTT', |
65 rttText)); | 65 rttText)); |
66 }; | 66 }; |
67 | 67 |
68 /** @param {OnClickData} info */ | 68 /** @param {OnClickData=} info */ |
69 remoting.ApplicationContextMenu.prototype.onClicked_ = function(info) { | 69 remoting.ApplicationContextMenu.prototype.onClicked_ = function(info) { |
70 switch (info.menuItemId) { | 70 switch (info.menuItemId) { |
71 | 71 |
72 case remoting.ApplicationContextMenu.kSendFeedbackId: | 72 case remoting.ApplicationContextMenu.kSendFeedbackId: |
73 var windowAttributes = { | 73 var windowAttributes = { |
74 bounds: { | 74 bounds: { |
75 width: 400, | 75 width: 400, |
76 height: 100 | 76 height: 100 |
77 }, | 77 }, |
78 resizable: false | 78 resizable: false |
(...skipping 25 matching lines...) Expand all Loading... |
104 break; | 104 break; |
105 } | 105 } |
106 }; | 106 }; |
107 | 107 |
108 | 108 |
109 /** @type {string} */ | 109 /** @type {string} */ |
110 remoting.ApplicationContextMenu.kSendFeedbackId = 'send-feedback'; | 110 remoting.ApplicationContextMenu.kSendFeedbackId = 'send-feedback'; |
111 | 111 |
112 /** @type {string} */ | 112 /** @type {string} */ |
113 remoting.ApplicationContextMenu.kShowStatsId = 'show-stats'; | 113 remoting.ApplicationContextMenu.kShowStatsId = 'show-stats'; |
OLD | NEW |