private async void OneTimeSave() { isFirstLoaded = true; EnableNotification.IsOn = (bool)UtilityClass.ApplicationDataBool("Notification(WhatsApp)", true); _ucCommandBar.btsetting.Visibility = Visibility.Visible; EnableDarkMode.IsOn = UtilityData.isWhatsAppDark; if (!EnableDarkMode.IsOn) { spContentSplitView.Background = new SolidColorBrush(UtilityClass.ConvertStringToColor("#009688")); } if (UtilityData.isFluentDesign) { _ucCommandBar.cbAppbar.Style = Application.Current.Resources["CommandBarRevealStyle"] as Style; } cssToApply = UtilityData.getCss("WhatsApp"); style(); var _cssToApply = await UtilityClass.serverStyle("http://rebrand.ly/oneWhatsApp", "WhatsApp", "DesktopMain"); if (_cssToApply != "") { var result = _cssToApply.Split(new[] { '\r', '\n' }); if (result != null && result[0] != null) { styleDisplayNone += result[0]; } cssToApply = _cssToApply; style(); } }
public List <Store_Sale> GetStoreSaleData() { UtilityData UtilityData = new UtilityData(); List <Store_Sale> storesale = UtilityData.GetStoreSaleInfo(Convert.ToInt32(hdnStoreInfoID.Value)); return(storesale); }
public List <Store_Branches> GetBranchByStoreID(int Store_Info_ID) { UtilityData utilitydata = new UtilityData(); List <Store_Branches> Branches = utilitydata.GetBranchByStoreID(Store_Info_ID); return(Branches); }
private void AddCountry(ComboBox combo) { using (UtilityData ut = new UtilityData(true)) { ut.BindToCombo(combo, DBCore.UtilityDataName.Country); } }
private void AddRobbingTemple(ComboBox combo) { using (UtilityData ut = new UtilityData(true)) { ut.BindToCombo(combo, DBCore.UtilityDataName.placeRobing); } }
private void AddUpasampadaTemple(ComboBox combo) { using (UtilityData ut = new UtilityData(true)) { ut.BindToCombo(combo, DBCore.UtilityDataName.PlaceUpasampada); } }
public override void setProjection(string val) { Matrix4x4 p = UtilityData.getMatrix4X4(val); p[2, 2] = defProj[10]; p[2, 3] = defProj[14]; cam.projectionMatrix = p; }
public virtual void setVisible(string val) { bool isVisible = UtilityData.getBool(val); if (child != null) { child.SetActive(isVisible); } }
private void UpdateCountry() { using (UtilityData ut = new UtilityData(true)) { ut.BindToCombo(countryCombo, DBCore.UtilityDataName.Country); } countryCombo.SelectedIndex = 0; }
private async void OneTimeSave() { isFirstLoaded = true; try { if (ApplicationView.GetForCurrentView().IsViewModeSupported(ApplicationViewMode.CompactOverlay)) { _ucCommandBar.btCompactOverlay.Visibility = Visibility.Visible; _ucCommandBar.btCompactOverlay.Click += btCompactOverlay_Click; } } catch (Exception) { } _ucCommandBar.btsetting.Visibility = Visibility.Visible; cbLiteItems.Visibility = _ucCommandBar.btforward.Visibility; if (cbLiteItems.Visibility == Visibility.Visible) { cbLiteItems.SelectedIndex = (int)UtilityClass.ApplicationDataBool("(Twit)cbLiteItems", 1); cbLiteItemsSelection(); } else { web.Source = new Uri("https://twitter.com/login"); } chbGoToTop.IsChecked = (bool)UtilityClass.ApplicationDataBool("isGoToTop(Twit)", false); EnableDarkMode.IsOn = UtilityData.isTwitterDark; if (!EnableDarkMode.IsOn) { spContentSplitView.Background = new SolidColorBrush(UtilityClass.ConvertStringToColor("#138BDE")); } if (UtilityData.isFluentDesign) { _ucCommandBar.cbAppbar.Style = Application.Current.Resources["CommandBarRevealStyle"] as Style; } DesktopCss = UtilityData.getCss("DTwit"); MobileCss = UtilityData.getCss("MTwit"); style(); DownloadMobileCss(); var _DesktopCss = await UtilityClass.serverStyle("https://rebrand.ly/TwitDesktopMain", "Twitter", "DesktopMain"); if (_DesktopCss != "") { var result = _DesktopCss.Split(new[] { '\r', '\n' }); if (result != null && result[0] != null) { styleDisplayNone += result[0]; } DesktopCss = _DesktopCss; style(); } }
public virtual void transofrmInfos(string infos) { var datas = UtilityData.getTransformInfos(infos); if (child != null) { child.SetActive(datas.isVisible); } transform.position = datas.position; transform.rotation = datas.rotation; transform.localScale = datas.scale; }
public override void setTrackedImage(string val) { var datas = UtilityData.getTransformInfos(val); if (child != null) { child.SetActive(datas.isVisible); } transform.position = datas.position; transform.rotation = datas.rotation; transform.localScale = datas.scale; }
private void deleteBtn_Click(object sender, EventArgs e) { using (UtilityData ut = new UtilityData(true)) { ut.ID = ID; if (MessageView.ShowQuestionMsg("Delete Details of '" + nameTextBoxX.Text + "'") == DialogResult.OK) { ut.Delete(); clear(); MessageView.ShowMsg("Sucessfully Deleted"); } } }
public void BindData() { UtilityData utilitydata = new UtilityData(); Store_Info store_info = utilitydata.GetStoreInfoByStoreInfoID(Convert.ToInt32(Request.QueryString["StoreInfoID"])); txtStoreName.Text = store_info.Store_Name; if (store_info.Is_Active == true) { chkIsActive.Checked = true; } else { chkIsActive.Checked = false; } }
private void addbtn_Click(object sender, EventArgs e) { try { if (ValidateBeforeAdd()) { using (UtilityData ut = new UtilityData(true)) { ut.NameID = NameID; ut.Value = nameTextBoxX.Text; if (ID == 0) { if (ut.Add() == 1) { MessageView.ShowMsg("Sucessfully Added"); //errorProvider1.SetError(idTxt, string.Empty); //errorProvider1.SetError(nameTxt, string.Empty); clear(); } } else { ut.ID = ID; if (MessageView.ShowQuestionMsg("Update ") == DialogResult.OK) { if (ut.Update() == 1) { MessageView.ShowMsg("Sucessfully Updated"); //errorProvider1.SetError(idTxt, string.Empty); //errorProvider1.SetError(nameTxt, string.Empty); clear(); } } } } } } catch (Exception ex) { MessageView.ShowErrorMsg(ex.Message); } }
protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) { string Menus = ""; DateTime dt = DateTime.Now; UtilityData UtilityDataClass = new UtilityData(); List <Utility.Data.Utility> Utility = UtilityDataClass.GetAllUtilities(); foreach (var item in Utility) { Menus += "<li id=\"li" + item.Utility_ID + "\" ><a href=\"Home.aspx?Utility=" + item.Utility_ID + "\";\"><i ></i><span class=\"title\">" + item.Utility_Name + "</span><span id=\"span" + item.Utility_ID + "\"></span></a></li>"; } Literal_MenuItems.Text = Menus; } }
public override void setTrackedImage(string val) { var datas = UtilityData.getTrackableInfos(val); if (objects != null) { GameObject child = objects.Where(x => x.name == datas.name).SingleOrDefault().gameObject; if (child != null) { TrackableImageStatus status = getStatus(datas.status); child.SetActive(status == TrackableImageStatus.tracked); child.transform.position = datas.position; child.transform.rotation = datas.rotation; child.transform.localScale = datas.scale; } } }
private async void OneTimeSave() { isFirstLoaded = true; try { if (ApplicationView.GetForCurrentView().IsViewModeSupported(ApplicationViewMode.CompactOverlay)) { _ucCommandBar.btCompactOverlay.Visibility = Visibility.Visible; _ucCommandBar.btCompactOverlay.Click += btCompactOverlay_Click; } } catch (Exception) { } _ucCommandBar.btsetting.Visibility = Visibility.Visible; chbGoToTop.IsChecked = (bool)UtilityClass.ApplicationDataBool("isGoToTop(Insta)", false); EnableDarkMode.IsOn = UtilityData.isInstagramDark; if (!EnableDarkMode.IsOn) { spContentSplitView.Background = new SolidColorBrush(UtilityClass.ConvertStringToColor("#8D3EBB")); } if (UtilityData.isFluentDesign) { _ucCommandBar.cbAppbar.Style = Application.Current.Resources["CommandBarRevealStyle"] as Style; } DesktopCss = UtilityData.getCss("Insta"); style(); var _DesktopCss = await UtilityClass.serverStyle("https://rebrand.ly/InstaMain", "Instagram", "InstaMain"); if (_DesktopCss != "") { var result = _DesktopCss.Split(new[] { '\r', '\n' }); if (result != null && result[0] != null) { styleDisplayNone = result[0]; } DesktopCss = _DesktopCss; style(); } }
private void findButton_Click(object sender, EventArgs e) { try { using (UtilityData ut = new UtilityData(true)) { ut.NameID = NameID; ut.Value = nameTextBoxX.Text; DataTable ds = ut.SelectFind(); frmSearch frmSub = new frmSearch(ds, this.Text, 1); frmSub.Width = 800; HandleSearch(frmSub); } } catch (Exception ex) { MessageView.ExceptionError(ex); } }
private async void OneTimeSave() { isFirstLoaded = true; try { if (ApplicationView.GetForCurrentView().IsViewModeSupported(ApplicationViewMode.CompactOverlay)) { _ucCommandBar.btCompactOverlay.Visibility = Visibility.Visible; _ucCommandBar.btCompactOverlay.Click += btCompactOverlay_Click; } } catch (Exception) { } // EnableNotification.IsOn = (bool)Utility.ApplicationDataBool("Notification(Telegram)", true); _ucCommandBar.btsetting.Visibility = Visibility.Visible; EnableDarkMode.IsOn = UtilityData.isTelegramDark; if (!EnableDarkMode.IsOn) { spContentSplitView.Background = new SolidColorBrush(UtilityClass.ConvertStringToColor("#5682A3")); } if (UtilityData.isFluentDesign) { _ucCommandBar.cbAppbar.Style = Application.Current.Resources["CommandBarRevealStyle"] as Style; } TeleCss = UtilityData.getCss("Tele"); style(); var _TeleCss = await UtilityClass.serverStyle("https://rebrand.ly/TeleMain", "Telegram", "TeleMain"); if (_TeleCss != "") { TeleCss = _TeleCss; style(); } }
public override void setPosition(string val) { transform.position = UtilityData.getVector3(val); }
IEnumerator OutnetGetUrlList() { var args = string.Format("package={0}&app_version={1}&res_version={2}¬ice_version={3}", ChannelManager.instance.channelName, ChannelManager.instance.appVersion, clientResVersion, ChannelManager.instance.noticeVersion); bool GetUrlListComplete = false; WWW www = null; SimpleHttp.HttpPost(URLSetting.START_UP_URL, null, UtilityData.StringToBytes(args), (WWW wwwInfo) => { www = wwwInfo; GetUrlListComplete = true; }); yield return(new WaitUntil(() => { return GetUrlListComplete; })); if (www == null || !string.IsNullOrEmpty(www.error) || www.bytes == null || www.bytes.Length == 0) { Logger.LogError("Get url list for args {0} with err : {1}", args, www == null ? "www null" : (!string.IsNullOrEmpty(www.error) ? www.error : "bytes length 0")); yield return(OutnetGetUrlList()); } var urlList = (Dictionary <string, object>)MiniJSON.Json.Deserialize(UtilityData.BytesToString(www.bytes)); if (urlList == null) { Logger.LogError("Get url list for args {0} with err : {1}", args, "Deserialize url list null!"); yield return(OutnetGetUrlList()); } if (urlList.ContainsKey("serverlist")) { URLSetting.SERVER_LIST_URL = urlList["serverlist"].ToString(); } if (urlList.ContainsKey("verifying")) { URLSetting.LOGIN_URL = urlList["verifying"].ToString(); } if (urlList.ContainsKey("logserver")) { URLSetting.REPORT_ERROR_URL = urlList["logserver"].ToString(); } if (urlList.ContainsKey("app_version") && !string.IsNullOrEmpty(urlList["app_version"].ToString())) { serverAppVersion = urlList["app_version"].ToString(); } if (urlList.ContainsKey("res_version") && !string.IsNullOrEmpty(urlList["res_version"].ToString())) { serverResVersion = urlList["res_version"].ToString(); } if (urlList.ContainsKey("notice_version") && !string.IsNullOrEmpty(urlList["notice_version"].ToString())) { ChannelManager.instance.noticeVersion = urlList["notice_version"].ToString(); UtilityGame.SafeWriteAllText(noticeVersionPath, ChannelManager.instance.noticeVersion); } if (urlList.ContainsKey("notice_url") && !string.IsNullOrEmpty(urlList["notice_url"].ToString())) { URLSetting.NOTICE_URL = urlList["notice_url"].ToString(); } if (urlList.ContainsKey("app") && !string.IsNullOrEmpty(urlList["app"].ToString())) { URLSetting.APP_DOWNLOAD_URL = urlList["app"].ToString(); } else if (urlList.ContainsKey("res") && !string.IsNullOrEmpty(urlList["res"].ToString())) { URLSetting.SERVER_RESOURCE_URL = urlList["res"].ToString(); } yield break; }
public void UtilityDataProcesing(ref UtilityData dataInstance, byte CMD, byte eventAdr = 0x00, byte _event = 0x00) { if (CMD == 0x3b) { int dataLength; byte[] _UtilityDataBytes = new byte[64]; float[] dataFloats = new float[12]; int _bytes; _UtilityDataBytes = UtilityClient.TCPrequest(BuildPacket(0x01, 0x11, 0, 0x3b, StabPacket, out dataLength), dataLength, out _bytes); if (_bytes > 7)//if(_bytes == 55) => 7 + 12*4 { int index = 0; //dataFloats = ParsePacket(ResponcePacket, _bytes); Int32 _TempGPSx = BitConverter.ToInt32(_UtilityDataBytes, (4 * index++ + 5)); Int32 _TempGPSy = BitConverter.ToInt32(_UtilityDataBytes, (4 * index++ + 5)); if (_TempGPSy < 0) { Console.WriteLine(); } dataInstance.GPSx = string.Format("{0}°{1}.{2}\'N", _TempGPSx / 10000000, ((_TempGPSx / 100000) % 100), _TempGPSx % 100000); dataInstance.GPSy = string.Format("{0}°{1}.{2}\'E", _TempGPSy / 10000000, ((_TempGPSy / 100000) % 100), _TempGPSy % 100000); dataInstance.Yg = BitConverter.ToInt32(_UtilityDataBytes, (4 * index++ + 5)); dataInstance.Pg = BitConverter.ToSingle(_UtilityDataBytes, (4 * index++ + 5)); dataInstance.Rg = BitConverter.ToSingle(_UtilityDataBytes, (4 * index++ + 5)); dataInstance.Eview = BitConverter.ToSingle(_UtilityDataBytes, (4 * index++ + 5)); dataInstance.Ev = BitConverter.ToSingle(_UtilityDataBytes, (4 * index++ + 5)); dataInstance.Eg = BitConverter.ToSingle(_UtilityDataBytes, (4 * index++ + 5)); dataInstance.Patm = BitConverter.ToSingle(_UtilityDataBytes, (4 * index++ + 5)); dataInstance.T = BitConverter.ToSingle(_UtilityDataBytes, (4 * index++ + 5)); dataInstance.Sw = BitConverter.ToSingle(_UtilityDataBytes, (4 * index++ + 5)); dataInstance.Dw = BitConverter.ToSingle(_UtilityDataBytes, (4 * index++ + 5)); /* * dataInstance.GPSx = dataFloats[0]; * dataInstance.GPSy = dataFloats[1]; * dataInstance.Yg = dataFloats[2]; * * dataInstance.Pg = dataFloats[3]; * dataInstance.Rg = dataFloats[4]; * dataInstance.Eview = dataFloats[5]; * dataInstance.Ev = dataFloats[6]; * dataInstance.Eg = dataFloats[7]; * dataInstance.Patm = dataFloats[8]; * dataInstance.T = dataFloats[9]; * dataInstance.Sw = dataFloats[10]; * dataInstance.Dw = dataFloats[11]; */ } } else if (CMD == 0x1b) { int dataLength; float[] dataFloats = new float[3]; int _bytes; ResponcePacket = UtilityClient.TCPrequest(BuildPacket(0x01, 0x11, 0, CMD, StabPacket, out dataLength), dataLength, out _bytes); if (_bytes > 7)//if(_bytes == 19) => 7 + 3*4 { dataFloats = ParsePacket(ResponcePacket, _bytes); dataInstance.Length_1 = dataFloats[0]; dataInstance.Length_1 = dataFloats[1]; dataInstance.Length_1 = dataFloats[2]; } } else if (CMD == 0x4b) { if (eventAdr > 0x04) { byte[] _dataBytes = { 0x02, 0x01, eventAdr, _event }; UtilityClient.TCPrequest(BuildPacket(0x01, 0x11, 4, CMD, _dataBytes, out int dataLength), dataLength, out int _bytes); } if (eventAdr <= 0x04) { byte[] _dataBytes = { eventAdr, _event }; UtilityClient.TCPrequest(BuildPacket(0x01, 0x11, 2, CMD, _dataBytes, out int dataLength), dataLength, out int _bytes); } } else if (CMD == 0x5b) { byte[] _dataBytes = { eventAdr, _event }; UtilityClient.TCPrequest(BuildPacket(0x01, 0x11, 2, CMD, _dataBytes, out int dataLength), dataLength, out int _bytes); } }
public Utility(UtilityData ud) : base(ud) { base.type = ShipComponentType.Utility; _canBeActivated = ud.canBeActivated; }
public override void setRotation(string val) { transform.rotation = UtilityData.getQuaternion(val); }
public override void setHit(string val) { spawnPrefabInPos(UtilityData.getVector3(val)); }
public Utility.Data.Utility GetUtilityByID(int UtilityID) { UtilityData utilitydata = new UtilityData(); return(utilitydata.GetUtilityByID(UtilityID)); }
public List <City> GetAllCities() { UtilityData utilitydata = new UtilityData(); return(utilitydata.GetAllCities()); }
public Store_Sale GetStoreSalebySaleID(int SaleID) { UtilityData utilitydata = new UtilityData(); return(utilitydata.GetSaleInfoBySaleID(SaleID)); }
protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) { if (Request.QueryString["Utility"] != null) { hdnUtilityID.Value = Request.QueryString["Utility"].ToString(); UtilityData Data = new UtilityData(); List <Store_Info> StoreInformation = Data.GetStoreInfoByUtilityID(Convert.ToInt32(hdnUtilityID.Value)); StringBuilder UtilityInformation = new StringBuilder(); StringBuilder BranchesAddress = new StringBuilder(); int i = 0; foreach (var item in StoreInformation) { UtilityInformation.Append("<div class=\"row\">\n" + "\n" + " <div class=\"col-md-6\">\n" + " <div class=\"portlet box red\">\n" + " <div class=\"portlet-title\">\n" + " <div class=\"caption\">\n" + " <i class=\"fa fa-gift\"></i>" + item.Store_Name + " </div>\n" + " <ul class=\"nav nav-tabs\">\n" + " <li class=\"active\">\n"); BranchesAddress.Clear(); BranchesAddress.Append("<div class=\"portlet-body\">\n" + " <div class=\"tab-content\">\n"); foreach (var Branches in item.Store_Branches) { if (item.Store_Branches.First() == Branches) { UtilityInformation.Append("<li class=\"active\"> <a href=\"#portlet_tab_" + i + "\" data-toggle=\"tab\" aria-expanded=\"true\"> " + Branches.Branch_Name + " </a>\n </li>\n"); BranchesAddress.Append(" <div class=\"tab-pane active\" id=\"portlet_tab_" + i + "\">\n" + " <p> " + Branches.Branch_Address + " </p>\n" + " </div>\n"); } else { UtilityInformation.Append("<li class=\"\">\n" + " <a href=\"#portlet_tab_" + i + "\" data-toggle=\"tab\" aria-expanded=\"false\"> " + Branches.Branch_Name + " </a>\n" + " </li>\n"); BranchesAddress.Append(" <div class=\"tab-pane\" id=\"portlet_tab_" + i + "\">\n" + " <p> " + Branches.Branch_Address + " </p>\n" + " </div>\n"); } i++; } UtilityInformation.Append(" </ul>\n" + " </div>\n"); UtilityInformation.Append(BranchesAddress); UtilityInformation.Append(" </div>\n" + " </div>\n" + " </div>\n" + " </div>\n" + " \n" + " </div>"); } literalUtilityInformation.Text = UtilityInformation.ToString(); } else { hdnUtilityID.Value = "0"; lblText.Text = "HOME PAGE....THINK"; } } }