internal void PreferredBitrate(sp_bitrate bitrate) { lock (libspotify.Mutex) { libspotify.sp_session_preferred_bitrate(sessionPtr, bitrate); } }
public static extern IntPtr sp_session_preferred_offline_bitrate(IntPtr session, sp_bitrate bitrate, bool allow_resync);
public static extern IntPtr sp_session_preferred_bitrate(IntPtr session, sp_bitrate bitrate);
public static extern sp_error sp_session_preferred_offline_bitrate(IntPtr sessionPtr, sp_bitrate bitrate, bool allow_resync);
public static extern sp_error sp_session_preferred_bitrate(IntPtr sessionPtr, sp_bitrate bitrate);
internal static extern void sp_session_preferred_bitrate(IntPtr sessionPtr, sp_bitrate bitrate);
public void SetPrefferedBitrate(sp_bitrate bitrate) { lock (libspotify.Mutex) libspotify.sp_session_preferred_bitrate(sessionPtr, bitrate); }
private bool LoadSettings() { bool retValue = false; string newUsername = this.pluginConfig.ReadField("/APPCONFIG/USERNAME"); if (newUsername != username) { retValue = true; } username = newUsername; string _encryptedPassword = this.pluginConfig.ReadField("/APPCONFIG/PASSWORD"); if (!String.IsNullOrEmpty(_encryptedPassword)) { try { password = EncryptionHelper.DecryptString(_encryptedPassword, Setup.PASSWORD); } catch (Exception ex) { CF_displayMessage(ex.Message); WriteError(ex); } } string tempPathString = this.pluginConfig.ReadField("/APPCONFIG/LOCATION"); if (!string.IsNullOrEmpty(tempPathString)) tempPath = tempPathString; else tempPath = Utility.GetDefaultLocationPath(); string bitrateString = this.pluginConfig.ReadField("/APPCONFIG/BITRATE"); if (string.IsNullOrEmpty(bitrateString)) { preferredBitrate = sp_bitrate.BITRATE_160k; } else { try { object bitrate = Enum.Parse(typeof(sp_bitrate), bitrateString); preferredBitrate = (sp_bitrate)bitrate; } catch { preferredBitrate = sp_bitrate.BITRATE_160k; } } //[GrantA] Load music auto play setting. string newAutoPlay = this.pluginConfig.ReadField("/APPCONFIG/AUTOPLAY"); if (newAutoPlay.Equals("True")) { autoPlay = true; } else { autoPlay = false; } return retValue; }
public static extern sp_error sp_session_preferred_offline_bitrate(IntPtr sessionPtr, sp_bitrate bitrate, [MarshalAs(UnmanagedType.I1)]bool allow_resync);