| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 'use strict'; | 5 'use strict'; |
| 6 | 6 |
| 7 /** | 7 /** |
| 8 * @return {number} Width of a scrollbar in pixels | 8 * @return {number} Width of a scrollbar in pixels |
| 9 */ | 9 */ |
| 10 function getScrollbarWidth() { | 10 function getScrollbarWidth() { |
| (...skipping 473 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 484 this.viewport_.position = position; | 484 this.viewport_.position = position; |
| 485 break; | 485 break; |
| 486 case 'setTranslatedStrings': | 486 case 'setTranslatedStrings': |
| 487 this.passwordScreen_.text = message.data.getPasswordString; | 487 this.passwordScreen_.text = message.data.getPasswordString; |
| 488 this.progressBar_.text = message.data.loadingString; | 488 this.progressBar_.text = message.data.loadingString; |
| 489 if (!this.isPrintPreview_) | 489 if (!this.isPrintPreview_) |
| 490 this.progressBar_.style.visibility = 'visible'; | 490 this.progressBar_.style.visibility = 'visible'; |
| 491 this.errorScreen_.text = message.data.loadFailedString; | 491 this.errorScreen_.text = message.data.loadFailedString; |
| 492 break; | 492 break; |
| 493 case 'cancelStreamUrl': | 493 case 'cancelStreamUrl': |
| 494 chrome.streamsPrivate.abort(this.streamDetails_.streamUrl); | 494 chrome.mimeHandlerPrivate.abortStream(); |
| 495 break; | 495 break; |
| 496 case 'bookmarks': | 496 case 'bookmarks': |
| 497 this.bookmarks_ = message.data.bookmarks; | 497 this.bookmarks_ = message.data.bookmarks; |
| 498 break; | 498 break; |
| 499 } | 499 } |
| 500 }, | 500 }, |
| 501 | 501 |
| 502 /** | 502 /** |
| 503 * @private | 503 * @private |
| 504 * A callback that's called before the zoom changes. Notify the plugin to stop | 504 * A callback that's called before the zoom changes. Notify the plugin to stop |
| (...skipping 199 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 704 this.streamDetails_.tabId != -1); | 704 this.streamDetails_.tabId != -1); |
| 705 }, | 705 }, |
| 706 | 706 |
| 707 /** | 707 /** |
| 708 * @type {Viewport} the viewport of the PDF viewer. | 708 * @type {Viewport} the viewport of the PDF viewer. |
| 709 */ | 709 */ |
| 710 get viewport() { | 710 get viewport() { |
| 711 return this.viewport_; | 711 return this.viewport_; |
| 712 } | 712 } |
| 713 }; | 713 }; |
| OLD | NEW |