OLD | NEW |
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef CHROMEOS_AUDIO_CRAS_AUDIO_HANDLER_H_ | 5 #ifndef CHROMEOS_AUDIO_CRAS_AUDIO_HANDLER_H_ |
6 #define CHROMEOS_AUDIO_CRAS_AUDIO_HANDLER_H_ | 6 #define CHROMEOS_AUDIO_CRAS_AUDIO_HANDLER_H_ |
7 | 7 |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 #include <queue> | 9 #include <queue> |
10 | 10 |
(...skipping 271 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
282 // audio nodes unplugged. | 282 // audio nodes unplugged. |
283 bool NonActiveDeviceUnplugged(size_t old_devices_size, | 283 bool NonActiveDeviceUnplugged(size_t old_devices_size, |
284 size_t new_device_size, | 284 size_t new_device_size, |
285 uint64_t current_active_node); | 285 uint64_t current_active_node); |
286 | 286 |
287 // Returns true if there is any device change for for input or output, | 287 // Returns true if there is any device change for for input or output, |
288 // specified by |is_input|. | 288 // specified by |is_input|. |
289 // The new discovered nodes are returned in |new_discovered|. | 289 // The new discovered nodes are returned in |new_discovered|. |
290 bool HasDeviceChange(const AudioNodeList& new_nodes, | 290 bool HasDeviceChange(const AudioNodeList& new_nodes, |
291 bool is_input, | 291 bool is_input, |
292 AudioNodeList* new_discovered); | 292 AudioDevicePriorityQueue* new_discovered); |
293 | 293 |
294 // Handles dbus callback for GetNodes. | 294 // Handles dbus callback for GetNodes. |
295 void HandleGetNodes(const chromeos::AudioNodeList& node_list, bool success); | 295 void HandleGetNodes(const chromeos::AudioNodeList& node_list, bool success); |
296 | 296 |
297 // Handles the dbus error callback. | 297 // Handles the dbus error callback. |
298 void HandleGetNodesError(const std::string& error_name, | 298 void HandleGetNodesError(const std::string& error_name, |
299 const std::string& error_msg); | 299 const std::string& error_msg); |
300 | 300 |
301 // Adds an active node. | 301 // Adds an active node. |
302 // If there is no active node, |node_id| will be switched to become the | 302 // If there is no active node, |node_id| will be switched to become the |
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
361 bool hdmi_rediscovering_; | 361 bool hdmi_rediscovering_; |
362 | 362 |
363 base::WeakPtrFactory<CrasAudioHandler> weak_ptr_factory_; | 363 base::WeakPtrFactory<CrasAudioHandler> weak_ptr_factory_; |
364 | 364 |
365 DISALLOW_COPY_AND_ASSIGN(CrasAudioHandler); | 365 DISALLOW_COPY_AND_ASSIGN(CrasAudioHandler); |
366 }; | 366 }; |
367 | 367 |
368 } // namespace chromeos | 368 } // namespace chromeos |
369 | 369 |
370 #endif // CHROMEOS_AUDIO_CRAS_AUDIO_HANDLER_H_ | 370 #endif // CHROMEOS_AUDIO_CRAS_AUDIO_HANDLER_H_ |
OLD | NEW |