dbusvideomanager.cpp 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687
  1. /*
  2. * Copyright (C) 2004-2017 Savoir-faire Linux Inc.
  3. *
  4. * Author: Philippe Proulx <philippe.proulx@savoirfairelinux.com>
  5. *
  6. * This program is free software; you can redistribute it and/or modify
  7. * it under the terms of the GNU General Public License as published by
  8. * the Free Software Foundation; either version 3 of the License, or
  9. * (at your option) any later version.
  10. *
  11. * This program is distributed in the hope that it will be useful,
  12. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  13. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  14. * GNU General Public License for more details.
  15. *
  16. * You should have received a copy of the GNU General Public License
  17. * along with this program; if not, write to the Free Software
  18. * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
  19. */
  20. #include "dbusvideomanager.h"
  21. #include "client/videomanager.h"
  22. DBusVideoManager::DBusVideoManager(DBus::Connection& connection)
  23. : DBus::ObjectAdaptor(connection, "/cx/ring/Ring/VideoManager")
  24. {}
  25. auto
  26. DBusVideoManager::getDeviceList() -> decltype(DRing::getDeviceList())
  27. {
  28. return DRing::getDeviceList();
  29. }
  30. auto
  31. DBusVideoManager::getCapabilities(const std::string& name) -> decltype(DRing::getCapabilities(name))
  32. {
  33. return DRing::getCapabilities(name);
  34. }
  35. auto
  36. DBusVideoManager::getSettings(const std::string& name) -> decltype(DRing::getSettings(name))
  37. {
  38. return DRing::getSettings(name);
  39. }
  40. void
  41. DBusVideoManager::applySettings(const std::string& name, const std::map<std::string, std::string>& settings)
  42. {
  43. DRing::applySettings(name, settings);
  44. }
  45. void
  46. DBusVideoManager::setDefaultDevice(const std::string& dev)
  47. {
  48. DRing::setDefaultDevice(dev);
  49. }
  50. auto
  51. DBusVideoManager::getDefaultDevice() -> decltype(DRing::getDefaultDevice())
  52. {
  53. return DRing::getDefaultDevice();
  54. }
  55. void
  56. DBusVideoManager::startCamera()
  57. {
  58. DRing::startCamera();
  59. }
  60. void
  61. DBusVideoManager::stopCamera()
  62. {
  63. DRing::stopCamera();
  64. }
  65. auto
  66. DBusVideoManager::switchInput(const std::string& resource) -> decltype(DRing::switchInput(resource))
  67. {
  68. return DRing::switchInput(resource);
  69. }
  70. auto
  71. DBusVideoManager::hasCameraStarted() -> decltype(DRing::hasCameraStarted())
  72. {
  73. return DRing::hasCameraStarted();
  74. }