File tree Expand file tree Collapse file tree 1 file changed +9
-0
lines changed
Expand file tree Collapse file tree 1 file changed +9
-0
lines changed Original file line number Diff line number Diff line change @@ -57,6 +57,9 @@ IEnumerator Start()
5757 } ,
5858 ld : ( msg ) =>
5959 {
60+ #if UNITY_IPHONE
61+ PlayerPrefs . SetString ( "sessionCookie" , webViewObject . GetSessionCookieFromServer ( ) ) ;
62+ #endif
6063 Debug . Log ( string . Format ( "CallOnLoaded[{0}]" , msg ) ) ;
6164#if UNITY_EDITOR_OSX || ! UNITY_ANDROID
6265 // NOTE: depending on the situation, you might prefer
@@ -104,6 +107,12 @@ IEnumerator Start()
104107 } ,
105108 //ua: "custom user agent string",
106109 enableWKWebView : true ) ;
110+ #if UNITY_IPHONE
111+ if ( ! string . IsNullOrEmpty ( PlayerPrefs . GetString ( "sessionCookie" , "" ) ) ) {
112+ webViewObject . SetSessionCookieFromClient ( PlayerPrefs . GetString ( "sessionCookie" , "" ) ) ;
113+ }
114+ #endif
115+
107116#if UNITY_EDITOR_OSX || UNITY_STANDALONE_OSX
108117 webViewObject . bitmapRefreshCycle = 1 ;
109118#endif
You can’t perform that action at this time.
0 commit comments