Пример #1
0
        //Look for google-play-services_lib in the developers Android Sdk.
        //If not found, fallback to compilations path
//		private string GetGooglePlayServicesPath(){
//			string sdkPath = EditorPrefs.GetString ("AndroidSdkRoot") + "/extras/google/google_play_services/libproject/google-play-services_lib/";
//			string compilationsPath = compilationsRootPath + "/android/android-profile-google/google-play-services_lib/";
//			return System.IO.Directory.Exists (sdkPath) ? sdkPath : compilationsPath;
//		}

        private void WriteSocialIntegrationState()
        {
            List <string> savedStates = new List <string>();

            foreach (var entry in socialIntegrationState)
            {
                savedStates.Add(entry.Key + "," + ((entry.Value != null && entry.Value.Value) ? 1 : 0));
            }

            string result = string.Empty;

            if (savedStates.Count > 0)
            {
                result = string.Join(";", savedStates.ToArray());
            }

            SoomlaEditorScript.SetConfigValue(ProfileSettingsPrefix, "SocialIntegration", result);
            SoomlaEditorScript.DirtyEditor();
        }
Пример #2
0
        //Look for google-play-services_lib in the developers Android Sdk.
        //If not found, fallback to compilations path
//		private string GetGooglePlayServicesPath(){
//			string sdkPath = EditorPrefs.GetString ("AndroidSdkRoot") + "/extras/google/google_play_services/libproject/google-play-services_lib/";
//			string compilationsPath = compilationsRootPath + "/android/android-profile-google/google-play-services_lib/";
//			return System.IO.Directory.Exists (sdkPath) ? sdkPath : compilationsPath;
//		}

        private void WriteSocialIntegrationState()
        {
            List <string> savedStates = new List <string>();

            foreach (var entry in socialIntegrationState)
            {
                if (entry.Value != null)
                {
                    savedStates.Add(entry.Key + "," + (entry.Value.Value ? 1 : 0));
                }
            }

            string result = string.Empty;

            if (savedStates.Count > 0)
            {
                result = string.Join(";", savedStates.ToArray());
            }

            SoomlaEditorScript.Instance.setSettingsValue("SocialIntegration", result);
            SoomlaEditorScript.DirtyEditor();
        }