midi-topaz 0.0.10 → 0.0.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/lib/topaz/midi_sync_output.rb +2 -0
- data/lib/topaz/tempo.rb +16 -3
- data/lib/topaz.rb +1 -1
- metadata +1 -1
data/lib/topaz/tempo.rb
CHANGED
@@ -109,11 +109,24 @@ module Topaz
|
|
109
109
|
alias_method :time_since_start, :time
|
110
110
|
|
111
111
|
# add a destination
|
112
|
-
# accepts
|
112
|
+
# accepts UniMIDI::Output or array of
|
113
113
|
def add_destination(dest)
|
114
|
-
|
114
|
+
dest = [dest].flatten.compact
|
115
|
+
dest.each do |d|
|
116
|
+
@destinations << MIDISyncOutput.new(d)
|
117
|
+
end
|
118
|
+
end
|
119
|
+
|
120
|
+
# remove a destination
|
121
|
+
# accepts UniMIDI::Output or array of
|
122
|
+
def remove_destination(dest)
|
123
|
+
dest = [dest].flatten.compact
|
124
|
+
dest.each do |output|
|
125
|
+
@destinations.each do |sync_output|
|
126
|
+
@destinations.delete(sync_output) if sync_output.output == output
|
127
|
+
end
|
128
|
+
end
|
115
129
|
end
|
116
|
-
#alias_method :<<, :add_destination
|
117
130
|
|
118
131
|
protected
|
119
132
|
|
data/lib/topaz.rb
CHANGED