public static bool GetCapability(TizenCapability capability) { string stringValue = GetCapability(capability.ToString()); if (string.IsNullOrEmpty(stringValue)) { return(false); } try { return((bool)System.ComponentModel.TypeDescriptor.GetConverter(typeof(bool)).ConvertFromString(stringValue)); } catch { Debug.LogError("Failed to parse value ('" + capability.ToString() + "," + stringValue + "') to bool type."); return(false); } }
public static void SetCapability(TizenCapability capability, bool value) { SetCapability(capability.ToString(), value.ToString()); }