| OLD | NEW |
| 1 <!-- | 1 <!-- |
| 2 -- Copyright 2015 The Chromium Authors. All rights reserved. | 2 -- Copyright 2015 The Chromium Authors. All rights reserved. |
| 3 -- Use of this source code is governed by a BSD-style license that can be | 3 -- Use of this source code is governed by a BSD-style license that can be |
| 4 -- found in the LICENSE file. | 4 -- found in the LICENSE file. |
| 5 --> | 5 --> |
| 6 | 6 |
| 7 <link rel="import" href="chrome://resources/polymer/polymer/polymer.html"> | 7 <link rel="import" href="chrome://resources/polymer/v1_0/polymer/polymer.html"> |
| 8 <link rel="import" href="track_list.html"> | 8 <link rel="import" href="track_list.html"> |
| 9 <link rel="import" href="control_panel.html"> | 9 <link rel="import" href="control_panel.html"> |
| 10 | 10 |
| 11 <polymer-element name="audio-player" | 11 <dom-module id="audio-player"> |
| 12 attributes="playing currenttrackurl playcount"> | 12 <link rel="import" type="css" href="audio_player.css"> |
| 13 <template> | 13 <template> |
| 14 <link rel="stylesheet" href="audio_player.css"> | 14 <track-list id="trackList" |
| 15 expanded$="[[expanded]]" |
| 16 shuffle="[[shuffle]]" |
| 17 current-track-index="{{currentTrackIndex}}" |
| 18 on-replay="onReplayCurrentTrack"></track-list> |
| 19 <control-panel id="audioController" |
| 20 playing="{{playing}}" |
| 21 time="{{time}}" |
| 22 duration="[[duration]]" |
| 23 shuffle="{{shuffle}}" |
| 24 repeat="{{repeat}}" |
| 25 volume="{{volume}}" |
| 26 expanded="{{expanded}}" |
| 27 on-next-clicked="onControllerNextClicked" |
| 28 on-previous-clicked="onControllerPreviousClicked"></control-panel> |
| 29 <audio id="audio" |
| 30 volume="[[computeAudioVolume_(volume)]]"></audio> |
| 31 </template> |
| 32 </dom-module> |
| 15 | 33 |
| 16 <track-list id="trackList" expanded?="{{model.expanded}}" | 34 <script src="audio_player.js"></script> |
| 17 on-replay="{{onReplayCurrentTrack}}"></track-list> | |
| 18 <control-panel id="audioController" | |
| 19 on-next-clicked="{{onControllerNextClicked}}" | |
| 20 on-previous-clicked="{{onControllerPreviousClicked}}"> | |
| 21 </control-panel> | |
| 22 <audio id="audio"></audio> | |
| 23 </template> | |
| 24 <script src="audio_player.js"></script> | |
| 25 </polymer-element> | |
| OLD | NEW |