3 |
* LinuxSampler - modular, streaming capable sampler * |
* LinuxSampler - modular, streaming capable sampler * |
4 |
* * |
* * |
5 |
* Copyright (C) 2003, 2004 by Benno Senoner and Christian Schoenebeck * |
* Copyright (C) 2003, 2004 by Benno Senoner and Christian Schoenebeck * |
6 |
* Copyright (C) 2005 - 2014 Christian Schoenebeck * |
* Copyright (C) 2005 - 2016 Christian Schoenebeck * |
7 |
* * |
* * |
8 |
* This program is free software; you can redistribute it and/or modify * |
* This program is free software; you can redistribute it and/or modify * |
9 |
* it under the terms of the GNU General Public License as published by * |
* it under the terms of the GNU General Public License as published by * |
164 |
} |
} |
165 |
|
|
166 |
uint MidiInputDevice::PortCount() { |
uint MidiInputDevice::PortCount() { |
167 |
return Ports.size(); |
return (uint) Ports.size(); |
168 |
} |
} |
169 |
|
|
170 |
std::map<String,DeviceCreationParameter*> MidiInputDevice::DeviceParameters() { |
std::map<String,DeviceCreationParameter*> MidiInputDevice::DeviceParameters() { |
209 |
|
|
210 |
void MidiInputDevice::AcquirePorts(uint newPorts) { |
void MidiInputDevice::AcquirePorts(uint newPorts) { |
211 |
//FIXME: hooo, this looks scary, no synchronization AT ALL yet! |
//FIXME: hooo, this looks scary, no synchronization AT ALL yet! |
212 |
int diff = this->Ports.size() - newPorts; |
int diff = int(this->Ports.size() - newPorts); |
213 |
if (!diff) |
if (!diff) |
214 |
return; // number of ports matches already, nothing to do |
return; // number of ports matches already, nothing to do |
215 |
|
|
230 |
fireMidiPortAdded(midiPort); |
fireMidiPortAdded(midiPort); |
231 |
} |
} |
232 |
} |
} |
233 |
fireMidiPortCountChanged(Ports.size()); |
fireMidiPortCountChanged((int)Ports.size()); |
234 |
} |
} |
235 |
|
|
236 |
} // namespace LinuxSampler |
} // namespace LinuxSampler |