Set NetEq playout mode through the Config struct

This change opens up the possibility to set the playout mode when
creating the NetEq object. The old methods SetPlayoutMode and
PlayoutMode are still available, but are deprecated.

BUG=3520
R=turaj@webrtc.org

Review URL: https://webrtc-codereview.appspot.com/23869004

git-svn-id: http://webrtc.googlecode.com/svn/trunk@7381 4adac7df-926f-26a2-2b94-8c16560cd09d
diff --git a/webrtc/modules/audio_coding/neteq/neteq_impl.h b/webrtc/modules/audio_coding/neteq/neteq_impl.h
index cfe6a40..fc2284d 100644
--- a/webrtc/modules/audio_coding/neteq/neteq_impl.h
+++ b/webrtc/modules/audio_coding/neteq/neteq_impl.h
@@ -138,9 +138,13 @@
   virtual int CurrentDelay() OVERRIDE { return kNotImplemented; }
 
   // Sets the playout mode to |mode|.
+  // Deprecated.
+  // TODO(henrik.lundin) Delete.
   virtual void SetPlayoutMode(NetEqPlayoutMode mode) OVERRIDE;
 
   // Returns the current playout mode.
+  // Deprecated.
+  // TODO(henrik.lundin) Delete.
   virtual NetEqPlayoutMode PlayoutMode() const OVERRIDE;
 
   // Writes the current network statistics to |stats|. The statistics are reset
@@ -327,9 +331,8 @@
   virtual void UpdatePlcComponents(int fs_hz, size_t channels)
       EXCLUSIVE_LOCKS_REQUIRED(crit_sect_);
 
-  // Creates DecisionLogic object for the given mode.
-  virtual void CreateDecisionLogic(NetEqPlayoutMode mode)
-      EXCLUSIVE_LOCKS_REQUIRED(crit_sect_);
+  // Creates DecisionLogic object with the mode given by |playout_mode_|.
+  virtual void CreateDecisionLogic() EXCLUSIVE_LOCKS_REQUIRED(crit_sect_);
 
   const scoped_ptr<CriticalSectionWrapper> crit_sect_;
   const scoped_ptr<BufferLevelFilter> buffer_level_filter_
@@ -383,6 +386,7 @@
   int error_code_ GUARDED_BY(crit_sect_);  // Store last error code.
   int decoder_error_code_ GUARDED_BY(crit_sect_);
   const BackgroundNoiseMode background_noise_mode_ GUARDED_BY(crit_sect_);
+  NetEqPlayoutMode playout_mode_ GUARDED_BY(crit_sect_);
 
   // These values are used by NACK module to estimate time-to-play of
   // a missing packet. Occasionally, NetEq might decide to decode more