Changeset - ea198addff5f
[Not reviewed]
default
0 2 0
Drew Perttula - 9 years ago 2016-06-08 07:04:40
drewp@bigasterisk.com
TL can stop following player song
Ignore-this: 81342af72a8bd4dc602f0364aecc831a
2 files changed with 11 insertions and 3 deletions:
0 comments (0 inline, 0 general)
light9/web/timeline/timeline-elements.html
Show inline comments
 
@@ -4,6 +4,7 @@
 
<link rel="import" href="light9-timeline-audio.html">
 
<link rel="import" href="../rdfdb-synced-graph.html">
 
<link rel="import" href="../light9-music.html">
 
<link rel="import" href="../edit-choice.html">
 

	
 

	
 
<!-- Whole editor- include this on your page.
 
@@ -35,12 +36,12 @@
 
    <div>
 
      <rdfdb-synced-graph graph="{{graph}}"></rdfdb-synced-graph>
 
      <light9-music id="music"
 
                    song="{{song}}"
 
                    song="{{playerSong}}"
 
                    t="{{songTime}}"
 
                    playing="{{songPlaying}}"
 
                    duration="{{songDuration}}"></light9-music>
 
      timeline editor: song [{{song}}] <button>unlink</button>
 
      <label><input type="checkbox"> follow player song choice</label>
 
      timeline editor: song <edit-choice graph="{{graph}}" uri="{{song}}"></edit-choice>
 
      <label><input type="checkbox" checked="{{followPlayerSong::change}}" > follow player song choice</label>
 
    </div>
 
    <div>[[debug]]</div>
 
    <iron-ajax id="vidrefTime" url="/vidref/time" method="PUT" content-type="application/json"></iron-ajax>
light9/web/timeline/timeline.coffee
Show inline comments
 
@@ -7,6 +7,8 @@ Polymer
 
    viewState: { type: Object }
 
    debug: {type: String}
 
    graph: {type: Object, notify: true}
 
    playerSong: {type: String, notify: true}
 
    followPlayerSong: {type: Boolean, notify: true, value: true}
 
    song: {type: String, notify: true}
 
    show: {value: 'http://light9.bigasterisk.com/show/dance2016'}
 
    songTime: {type: Number, notify: true, observer: '_onSongTime'}
 
@@ -17,12 +19,17 @@ Polymer
 
  width: ko.observable(1)
 
  listeners:
 
    'iron-resize': '_onIronResize'
 
  observers: [
 
    'setSong(playerSong, followPlayerSong)'
 
    ]
 
  _onIronResize: ->
 
    @width(@offsetWidth)
 
  _onSongTime: (t) ->
 
    @viewState.cursor.t(t)
 
  _onSongDuration: (d) ->
 
    @viewState.zoomSpec.duration(d)
 
  setSong: (s) ->
 
    @song = @playerSong if @followPlayerSong
 

	
 
  ready: ->
 
    @viewState =
0 comments (0 inline, 0 general)