diff options
author | David Robillard <d@drobilla.net> | 2009-05-13 16:04:14 +0000 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2009-05-13 16:04:14 +0000 |
commit | b84b50d2bbbfcd196d62344eaeef7fb08e3d686c (patch) | |
tree | 5b65cb8ec437087f1352ac23730355d6cc6369cb /src/PatchageCanvas.cpp | |
parent | ddc09de45b45bdf2afdeff68eb8a17ad237ef6c3 (diff) | |
download | patchage-b84b50d2bbbfcd196d62344eaeef7fb08e3d686c.tar.gz patchage-b84b50d2bbbfcd196d62344eaeef7fb08e3d686c.tar.bz2 patchage-b84b50d2bbbfcd196d62344eaeef7fb08e3d686c.zip |
Strip trailing whitespace.
git-svn-id: http://svn.drobilla.net/lad/trunk/patchage@1999 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'src/PatchageCanvas.cpp')
-rw-r--r-- | src/PatchageCanvas.cpp | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/src/PatchageCanvas.cpp b/src/PatchageCanvas.cpp index 10fe33e..cfbf267 100644 --- a/src/PatchageCanvas.cpp +++ b/src/PatchageCanvas.cpp @@ -1,15 +1,15 @@ /* This file is part of Patchage. * Copyright (C) 2007 Dave Robillard <http://drobilla.net> - * + * * Patchage is free software; you can redistribute it and/or modify it under the * terms of the GNU General Public License as published by the Free Software * Foundation; either version 2 of the License, or (at your option) any later * version. - * + * * Patchage is distributed in the hope that it will be useful, but WITHOUT ANY * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS * FOR A PARTICULAR PURPOSE. See the GNU General Public License for details. - * + * * You should have received a copy of the GNU General Public License along * with this program; if not, write to the Free Software Foundation, Inc., * 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA @@ -73,7 +73,7 @@ PatchageCanvas::find_port(const PortID& id) #if defined(USE_LIBJACK) || defined(HAVE_JACK_DBUS) jack_port_t* jack_port = NULL; #endif - + SharedPtr<PatchageModule> module; boost::shared_ptr<PatchagePort> pp; @@ -84,36 +84,36 @@ PatchageCanvas::find_port(const PortID& id) jack_port = jack_port_by_id(_app->jack_driver()->client(), id.id.jack_id); if (!jack_port) return boost::shared_ptr<PatchagePort>(); - + _app->jack_driver()->port_names(id, module_name, port_name); - + module = find_module(module_name, (jack_port_flags(jack_port) & JackPortIsInput) ? Input : Output); - + if (module) return PtrCast<PatchagePort>(module->get_port(port_name)); else return boost::shared_ptr<PatchagePort>(); - + break; #endif - + #ifdef HAVE_ALSA case PortID::ALSA_ADDR: for (ItemList::iterator m = _items.begin(); m != _items.end(); ++m) { SharedPtr<PatchageModule> module = PtrCast<PatchageModule>(*m); if (!module) continue; - + for (PortVector::const_iterator p = module->ports().begin(); p != module->ports().end(); ++p) { pp = boost::dynamic_pointer_cast<PatchagePort>(*p); if (!pp) continue; - + if (pp->type() == ALSA_MIDI) { /*cerr << "ALSA PORT: " << (int)pp->alsa_addr()->client << ":" << (int)pp->alsa_addr()->port << endl;*/ - + if (pp->alsa_addr() && pp->alsa_addr()->client == id.id.alsa_addr.client && pp->alsa_addr()->port == id.id.alsa_addr.port) { @@ -180,7 +180,7 @@ PatchageCanvas::disconnect(boost::shared_ptr<Connectable> port1, boost::shared_p status_message("ERROR: Attempt to disconnect mismatched/unknown ports"); return; } - + if ((input->type() == JACK_AUDIO && output->type() == JACK_AUDIO) || (input->type() == JACK_MIDI && output->type() == JACK_MIDI)) { #if defined(USE_LIBJACK) || defined(HAVE_JACK_DBUS) @@ -216,7 +216,7 @@ PatchageCanvas::get_port(const string& node_name, const string& port_name) if (module->name() == node_name && port) return port; } - + return boost::shared_ptr<Port>(); } |