lib/overlayer.rb in sensible-cinema-0.7.4 vs lib/overlayer.rb in sensible-cinema-0.7.5

- old
+ new

@@ -48,14 +48,16 @@ current_mtime = File.stat(@filename).mtime if @file_mtime != current_mtime reload_yaml! @file_mtime = current_mtime else - p 'same mtime:', @file_mtime if $DEBUG && $VERBOSE + #p 'same mtime:', @file_mtime if $DEBUG && $VERBOSE end end + attr_accessor :all_sequences + def reload_yaml! @all_sequences = OverLayer.translate_yaml(File.read(@filename)) # LTODO... @all_sequences = @all_sequences.map{|k, v| v.sort!} etc. and validate... puts '(re) loaded mute sequences from ' + File.basename(@filename) + ' as', pretty_sequences.pretty_inspect, "" unless $DEBUG && !$VERBOSE # I hate these during unit tests... signal_change @@ -317,10 +319,10 @@ end else time_till_next_mute_starts = next_point - cur_time end - pps 'sleeping until next action (%s) begins in %fs (%f) %f' % [next_point, time_till_next_mute_starts, Time.now_f, cur_time] if $VERBOSE + # pps 'sleeping until next action (%s) begins in %fs (%f) %f' % [next_point, time_till_next_mute_starts, Time.now_f, cur_time] if $VERBOSE @cv.wait(@mutex, time_till_next_mute_starts) if time_till_next_mute_starts > 0 set_states! } }