public void Set(AddNotifyLoginStatusChangedOptions other) { if (other != null) { m_ApiVersion = AuthInterface.AddnotifyloginstatuschangedApiLatest; } }
/// <summary> /// Register to receive login status updates. /// @note must call RemoveNotifyLoginStatusChanged to remove the notification /// </summary> /// <param name="options">structure containing the api version of AddNotifyLoginStatusChanged to use</param> /// <param name="clientData">arbitrary data that is passed back to you in the callback</param> /// <param name="notification">a callback that is fired when the login status for a user changes</param> /// <returns> /// handle representing the registered callback /// </returns> public ulong AddNotifyLoginStatusChanged(AddNotifyLoginStatusChangedOptions options, object clientData, OnLoginStatusChangedCallback notification) { System.IntPtr optionsAddress = new System.IntPtr(); Helper.TryMarshalSet <AddNotifyLoginStatusChangedOptionsInternal, AddNotifyLoginStatusChangedOptions>(ref optionsAddress, options); var clientDataAddress = System.IntPtr.Zero; var notificationInternal = new OnLoginStatusChangedCallbackInternal(OnLoginStatusChangedCallbackInternalImplementation); Helper.AddCallback(ref clientDataAddress, clientData, notification, notificationInternal); var funcResult = EOS_Auth_AddNotifyLoginStatusChanged(InnerHandle, optionsAddress, clientDataAddress, notificationInternal); Helper.TryMarshalDispose(ref optionsAddress); Helper.TryAssignNotificationIdToCallback(clientDataAddress, funcResult); return(funcResult); }