private void m_cmdHelp_Click() { string instPath = MMUtils.GetRegistry("", "InstPath"); string chmPath = instPath + "\\Synergy.chm"; System.Diagnostics.Process.Start(chmPath); }
private void btnNext_Click(object sender, EventArgs e) { if (txtDiskName.Text == "") { lblDiskName.ForeColor = System.Drawing.Color.Red; return; } using (StoragesDB _db = new StoragesDB()) { DataTable _dt = _db.ExecuteQuery("select * from STORAGES where STORAGENAME=`" + txtDiskName.Text + "`"); if (_dt.Rows.Count != 0) { lblDiskNameExists.Text = MMUtils.GetString("newnetworkdiskdlg.lblDiskNameExists.text"); return; } _db.ExecuteNonQuery("insert into STORAGES values(" + "`" + txtDiskName.Text + "`," + "`" + "networkdisk" + "`," + "``, ``, ``, ``, 0, 0)"); } this.DialogResult = DialogResult.OK; }
private void DeleteLevel() { iNumberOfObjects = 0; iNumberOfColors = 0; iNumberOfMovementObjects = 0; MMUtils.DeleteAllChildren(tContainer); }
public void Create(ribbonTab myTab) { m_myTab = myTab; string imagePath = MMUtils.imagePath; try { m_rgPlaces = m_myTab.Groups.Add(0, MMUtils.GetString("places.group.name"), "www.palmaross.com", imagePath + "lists_s.png"); m_cmdNewPlace = MMUtils.MindManager.Commands.Add(MMUtils.AddinName, "NewPlace"); m_cmdNewPlace.Caption = MMUtils.GetString("places.commands.newplace.caption"); m_cmdNewPlace.ToolTip = MMUtils.GetString("places.commands.newplace.tooltip") + "\n" + m_cmdNewPlace.Caption; m_cmdNewPlace.LargeImagePath = MMUtils.imagePath + "common_stock.png"; m_cmdNewPlace.ImagePath = imagePath + "audio.png"; m_cmdNewPlace.UpdateState += new ICommandEvents_UpdateStateEventHandler(m_cmdNewPlace_UpdateState); m_cmdNewPlace.Click += new ICommandEvents_ClickEventHandler(m_cmdNewPlace_Click); m_ctrlNewPlace = m_rgPlaces.GroupControls.AddButton(m_cmdNewPlace); m_cmdManagePlaces = MMUtils.MindManager.Commands.Add(MMUtils.AddinName, "ManagePlaces"); m_cmdManagePlaces.Caption = MMUtils.GetString("places.commands.manageplaces.caption"); m_cmdManagePlaces.ToolTip = MMUtils.GetString("places.commands.manageplaces.tooltip") + "\n" + m_cmdManagePlaces.Caption; m_cmdManagePlaces.LargeImagePath = MMUtils.imagePath + "common_stock.png"; m_cmdManagePlaces.ImagePath = imagePath + "audio.png"; m_cmdManagePlaces.UpdateState += new ICommandEvents_UpdateStateEventHandler(m_cmdManagePlaces_UpdateState); m_cmdManagePlaces.Click += new ICommandEvents_ClickEventHandler(m_cmdManagePlaces_Click); m_ctrlManagePlaces = m_rgPlaces.GroupControls.AddTwoPartButton(m_cmdManagePlaces); } catch (Exception ex) { System.Windows.Forms.MessageBox.Show(ex.Message); } }
public GetPathDlg(string storage = "", string _place = "", string cause = "", string type = "") { InitializeComponent(); btnCancel.Text = MMUtils.GetString("buttonCancel.text"); btnBack.Text = MMUtils.GetString("buttonBack.text"); aCause = cause; aPlace = _place; string aStorage = storage; if (cause == "receivemap") { btnBack.Enabled = false; Text = MMUtils.GetString("getpathdlg.receivemap.dlgtitle"); lblFolder.Text = String.Format(MMUtils.GetString("getpathdlg.lblFolderReceiveMap.text"), aStorage); } if (cause == "publish") { Text = MMUtils.GetString("getpathdlg.publish.dlgtitle"); lblFolder.Text = String.Format(MMUtils.GetString("getpathdlg.lblFolderForPublish.text"), aStorage); } if (cause == "newplace") { if (type == "cloud") { Text = MMUtils.GetString("getpathdlg.newplace.dlgtitle"); lblFolder.Text = String.Format(MMUtils.GetString("getpathdlg.lblFolderNewPlace.text"), aStorage); } } }
private void btnExit_Click(object sender, EventArgs e) { if (checkBoxForgetMe.Checked == true) { MMUtils.SetRegistry("", "RememberMe", "0"); } }
private bool ValidatePush(Vector3 v3Direction) { int index = MMUtils.MatrixIndexesToListIndex(v3CurrentPosition + v3Direction, gameController.GetCurrentLevel().MaxSize); return(MMUtils.IsPushableObject(gameController.scenarioObjects[index].GetComponent <ScenarioObject>().tTileType) && gameController.scenarioObjects[index].GetComponent <MovementObject>().bEnableMovement); }
private void btnNext_Click(object sender, EventArgs e) { aPlaceName = txtNetworkDiskName.Text; // If Place with this name exists using (PlacesDB _db = new PlacesDB()) { DataTable _dt = _db.ExecuteQuery("select * from PLACES"); foreach (DataRow _row in _dt.Rows) { // Storage name exists if (aPlaceName == _row["PLACENAME"].ToString()) { lblPlaceNameExists.Text = MMUtils.GetString("cloudstoragedlg.lblPlaceNameExists.text"); return; } } } if (aPlaceName == "") { lblPlace.ForeColor = System.Drawing.Color.Red; } else { this.DialogResult = DialogResult.OK; } }
public LinkedFilesDlg(List <string> links, Document _doc) { InitializeComponent(); aHelpProvider.HelpNamespace = MMUtils.instPath + "\\Synergy.chm"; aHelpProvider.SetHelpNavigator(this, HelpNavigator.Topic); aHelpProvider.SetHelpKeyword(this, "publishmap.htm"); // TODO checkedListBox.MouseHover += new EventHandler(checkedListBox_MouseHover); checkedListBox.MouseMove += new MouseEventHandler(checkedListBox_MouseMove); Text = MMUtils.GetString("linkedfilesdlg.dlgtitle.text"); lblList.Text = MMUtils.GetString("linkedfilesdlg.lblList.text"); btnCancel.Text = MMUtils.GetString("buttonCancel.text"); _links = links; doc = _doc; aLocalPath = doc.Path + "\\"; // path to map folder foreach (string link in links) { string fn = System.IO.Path.GetFileName(link); checkedListBox.Items.Add(fn); } }
public NewUserDlg() { InitializeComponent(); aHelpProvider.HelpNamespace = MMUtils.instPath + "\\Synergy.chm"; aHelpProvider.SetHelpNavigator(this, HelpNavigator.Topic); aHelpProvider.SetHelpKeyword(this, "start.htm"); Text = MMUtils.GetString("newuserDlg.dlgtitle.text"); lblPrompt.Text = MMUtils.GetString("newuserDlg.lblPrompt.text"); lblName.Text = MMUtils.GetString("newuserDlg.lblName.text"); lblLogin.Text = MMUtils.GetString("newuserDlg.lblLogin.text"); lblPassword.Text = MMUtils.GetString("newuserDlg.lblPassword.text"); lblRole.Text = MMUtils.GetString("newuserDlg.lblRole.text"); rbtnAdmin.Text = MMUtils.GetString("newuserDlg.rbtnAdmin.text"); rbtnDAdmin.Text = MMUtils.GetString("newuserDlg.rbtnDAdmin.text"); rbtnMember.Text = MMUtils.GetString("newuserDlg.rbtnMember.text"); btnCancel.Text = MMUtils.GetString("buttonCancel.text"); toolTipName.SetToolTip(this.lblName, MMUtils.GetString("newuserDlg.name.tooltip")); toolTipLogin.SetToolTip(this.lblLogin, MMUtils.GetString("newuserDlg.login.tooltip")); toolTipEmail.SetToolTip(this.lblEmail, MMUtils.GetString("newuserDlg.email.tooltip")); toolTipPassword.SetToolTip(this.lblPassword, MMUtils.GetString("newuserDlg.password.tooltip")); toolTipAdmin.SetToolTip(this.rbtnAdmin, MMUtils.GetString("newuserDlg.admin.tooltip")); toolTipDAdmin.SetToolTip(this.rbtnDAdmin, MMUtils.GetString("newuserDlg.dadmin.tooltip")); toolTipMember.SetToolTip(this.rbtnMember, MMUtils.GetString("newuserDlg.member.tooltip")); txtName.Text = MMUtils.MindManager.Options.UserName; txtEmail.Text = MMUtils.MindManager.Options.UserEmail; lblRequired.Text = ""; rbtnMember.Checked = true; }
private void ComboPlaces_SelectedIndexChanged(object sender, EventArgs e) { using (PlacesDB _db = new PlacesDB()) { DataTable _dt = _db.ExecuteQuery("select * from PLACES where PLACENAME='" + comboPlaces.Text + "'"); aStorage = _dt.Rows[0]["STORAGE"].ToString(); aPlacePath = _dt.Rows[0]["PLACEPATH"].ToString(); } string LeaveInPlace = MMUtils.GetString("receivedmapdlg.rbtnLeaveInPlace.text"); if (aStorage == "OneDrive") { LeaveInPlace = LeaveInPlace + MMUtils.GetString("receivedmapdlg.LeaveInPlaceRec.text"); rbtnLeaveInPlace.Checked = true; HelpRecommend.Visible = true; } else { rbtnPlace.Checked = true; HelpRecommend.Visible = false; } rbtnLeaveInPlace.Text = LeaveInPlace; // For FolderBrowser dialog System.IO.DirectoryInfo dir = new System.IO.DirectoryInfo(aPlacePath).Parent; initfolder = dir.FullName.ToString(); }
public CloudStorageDlg() { InitializeComponent(); aHelpProvider.HelpNamespace = MMUtils.instPath + "\\Synergy.chm"; aHelpProvider.SetHelpNavigator(this, HelpNavigator.Topic); aHelpProvider.SetHelpKeyword(this, "publishmap.htm"); // TODO Text = MMUtils.GetString("cloudstoragedlg.dlgtitle"); lblChooseStorage.Text = MMUtils.GetString("cloudstoragedlg.lblChooseStorage.text"); btnAddNewStorage.Text = MMUtils.GetString("cloudstoragedlg.btnAddNewStorage.text"); lblPlaceName.Text = MMUtils.GetString("cloudstoragedlg.lblPlaceName.text"); lblPlaceNameExists.Text = ""; btnCancel.Text = MMUtils.GetString("buttonCancel.text"); btnNext.Text = MMUtils.GetString("buttonNext.text"); btnBack.Text = MMUtils.GetString("buttonBack.text"); tltPlaceName.SetToolTip(help, MMUtils.GetString("cloudstoragedlg.PlaceName.tooltip")); using (StoragesDB _db = new StoragesDB()) { DataTable _dt = _db.ExecuteQuery("select * from STORAGES"); foreach (DataRow _row in _dt.Rows) { if (_row["TYPE"].ToString() == "cloud") { comboStorageName.Items.Add(_row["STORAGENAME"]); } } comboStorageName.SelectedIndex = 0; txtPlaceName.Text = comboStorageName.Text; } }
public void GenerateLevelFromLevelData() { DeleteLevel(); iTileSize = lvlExit.MaxSize; BuildLevelTiles(lvlExit.MaxSize); string[] sLevelData = lvlExit.levelBuild.Split(MMConstants.LEVEL_SEPARATOR); int iColorObjectIdx = 0, iRotationIdx = 0, iObjMoveIdx = 0; for (int i = 0; i < sLevelData.Length; i++) { tiles[i].GetComponent <Tile>().ttTile = (MMEnums.TileType) int.Parse(sLevelData[i]); if (MMUtils.IsColorObject(tiles[i].GetComponent <Tile>().ttTile)) { tiles[i].GetComponent <Tile>().clrObject = lvlExit.objColor[iColorObjectIdx]; iColorObjectIdx++; } if (MMUtils.IsScenarioObject(tiles[i].GetComponent <Tile>().ttTile)) { tiles[i].transform.rotation = Quaternion.Euler(lvlExit.objRotation[iRotationIdx]); iRotationIdx++; } if (MMUtils.IsPushableObject(tiles[i].GetComponent <Tile>().ttTile)) { tiles[i].GetComponent <Tile>().bMovementOn = lvlExit.objMovementEnabled[iObjMoveIdx]; iObjMoveIdx++; } } RefreshTiles(); }
private void m_cmdOpenMaps_Click() { if (OpenButtons.Count == 0) { System.Windows.Forms.MessageBox.Show(MMUtils.GetString("maps.nomapsyet.message")); } }
public void AddSolution(SplitterSolution ssNewSpliterSolution, Vector3 v3PrevDirection, GameObject goLaser) { Color32[] clrsToSplit = MMUtils.ColorSplitter(ssNewSpliterSolution.clrLaserColor); int iReverse = (bInvertRays) ? -1 : 1; ssNewSpliterSolution.tLasers = new Transform[clrsToSplit.Length]; ssSpliterSolutions.Add(ssNewSpliterSolution); float fAngleInBetween = 180; //ANGLE_TO_SPLIT / clrsToSplit.Length; float fStartingAngle = -90 * iReverse; //ANGLE_TO_SPLIT + fAngleInBetween; for (int i = 0; i < clrsToSplit.Length; i++) { GameObject go = Instantiate(goLaser, transform.position + goLaser.GetComponent <ScenarioObject>().v3Offset - this.v3Offset, Quaternion.LookRotation(v3PrevDirection)); go.transform.Rotate(new Vector3(0, fStartingAngle, 0), Space.Self); fStartingAngle += fAngleInBetween; go.transform.SetParent(transform); ssNewSpliterSolution.tLasers[i] = go.transform; go.GetComponent <RayLaser>().UpdateRayColor(clrsToSplit[i]); go.GetComponent <RayLaser>().SetCilinderActive(false); } }
void CreateLogin(bool _logInSynergy = false) { string imagePath = MMUtils.imagePath; string _caption = MMUtils.GetString("login.commands.login.caption"); string _tooltip = MMUtils.GetString("login.commands.login.tooltip"); if (_logInSynergy) { imagePath = imagePath + "user.png"; SUtils.currentUserName = MMUtils.GetRegistry("", "CurrentUserName"); _caption = SUtils.currentUserName + " |"; _tooltip = MMUtils.GetString("login.commands.logout.tooltip"); } else // Log out { imagePath = imagePath + "connection.png"; } m_cmdLogin = CreateCommand("synergylogin"); m_cmdLogin.Caption = _caption; m_cmdLogin.ToolTip = _tooltip; m_cmdLogin.ImagePath = imagePath; m_cmdLogin.UpdateState += new ICommandEvents_UpdateStateEventHandler(m_cmdLogin_UpdateState); m_cmdLogin.Click += new ICommandEvents_ClickEventHandler(m_cmdLogin_Click); m_ctrlLogin = MMUtils.MindManager.StatusBarControls.AddButton(m_cmdLogin); }
public void m_command_Click() // open map { string aMapGuid = m_command.ToolTip; string _mapName = m_command.Caption; string _mapPlacePath = ""; string aStorage = ""; string _mapLocalPath = ""; bool mapnotfound = true; using (MapsDB _db = new MapsDB()) { System.Data.DataTable _dt = _db.ExecuteQuery("select * from MAPS where MAPGUID=`" + aMapGuid + "`"); if (_dt.Rows.Count != 0) { mapnotfound = false; _mapLocalPath = _dt.Rows[0]["LOCALPATH"].ToString(); _mapPlacePath = _dt.Rows[0]["PATHTOPLACE"].ToString(); aStorage = _dt.Rows[0]["STORAGE"].ToString(); } } if (mapnotfound) { System.Windows.Forms.MessageBox.Show(String.Format(MMUtils.GetString("maps.mapnoexists.message"), _mapName), MMUtils.GetString("maps.mapnoexists.caption")); return; // TODO нужно предложить удалить ее - из БД и из меню } // if map is opened already foreach (Document _map in MMUtils.MindManager.AllDocuments) { if (SUtils.SynergyMapGuid(_map) == aMapGuid) { _map.Activate(); return; } } if (Directory.Exists(_mapPlacePath)) // TODO если по причине неподключенного сетевого диска - { string _latestfile = Directory.GetFiles(_mapPlacePath, "*.mmap").Last().ToString(); long localmap_lastwrite = Convert.ToInt64(File.GetLastWriteTimeUtc(_mapLocalPath).ToString("yyyyMMddHHmmssfff")); long placemap_time = Convert.ToInt64(Path.GetFileNameWithoutExtension(_latestfile)); // Check if map in Place is newer than local map, if yes - replace local map if (placemap_time > localmap_lastwrite) { try { File.Copy(_latestfile, _mapLocalPath, true); // copy (overwrite) map from its Place to local Synergy } catch { } // TODO } } DocumentStorage.reopenmap = false; System.IO.File.SetAttributes(_mapLocalPath, System.IO.FileAttributes.Normal); MMUtils.MindManager.AllDocuments.Open(_mapLocalPath); }
public void RefreshLevelReference(Vector3 v3Direction) { int iCurrIndex = MMUtils.MatrixIndexesToListIndex(v3TargetPosition, gameController.GetCurrentLevel().MaxSize); int iPrevIndex = MMUtils.MatrixIndexesToListIndex(v3CurrentPosition, gameController.GetCurrentLevel().MaxSize); GameObject goAux = gameController.scenarioObjects[iCurrIndex]; gameController.scenarioObjects[iCurrIndex] = gameController.scenarioObjects[iPrevIndex]; gameController.scenarioObjects[iPrevIndex] = goAux; }
public NewMapDlg() { InitializeComponent(); Text = MMUtils.GetString("newmapdlg.dlgtitle"); lblNotSaved.Text = MMUtils.GetString("newmapdlg.lblNotSaved.text"); textBox_MapName.Text = MMUtils.MindManager.ActiveDocument.CentralTopic.Text; btn_cancel.Text = MMUtils.GetString("buttonCancel.text"); }
public NetworkDiskDlg() { InitializeComponent(); aHelpProvider.HelpNamespace = MMUtils.instPath + "\\Synergy.chm"; aHelpProvider.SetHelpNavigator(this, HelpNavigator.Topic); aHelpProvider.SetHelpKeyword(this, "publishmap.htm"); // TODO Text = MMUtils.GetString("networkdiskdlg.dlgtitle"); lblChooseND.Text = MMUtils.GetString("networkdiskdlg.lblChooseND.text"); btnAddNewDisk.Text = MMUtils.GetString("cloudstoragedlg.btnAddNewStorage.text"); lblPlace.Text = MMUtils.GetString("networkdiskdlg.lblNetworkDisk.text"); lblPlaceNameExists.Text = ""; btnCancel.Text = MMUtils.GetString("buttonCancel.text"); btnNext.Text = MMUtils.GetString("buttonNext.text"); btnBack.Text = MMUtils.GetString("buttonBack.text"); using (StoragesDB _db = new StoragesDB()) { DataTable _dt = _db.ExecuteQuery("select * from STORAGES"); foreach (DataRow _row in _dt.Rows) { if (_row["PROCESS"].ToString() != "" && _row["SITE"].ToString() == "") { comboDisks.Items.Add(_row["STORAGENAME"]); } } } if (comboDisks.Items.Count != 0) { comboDisks.SelectedIndex = 0; } else { using (NewNetworkDiskDlg _dlg = new NewNetworkDiskDlg()) { DialogResult result = _dlg.ShowDialog(new WindowWrapper((IntPtr)MMUtils.MindManager.hWnd)); aStorage = _dlg.txtDiskName.Text; if (result == DialogResult.Cancel) { this.DialogResult = DialogResult.Cancel; return; } if (result == DialogResult.Retry) { this.DialogResult = DialogResult.Retry; return; } comboDisks.Items.Add(aStorage); comboDisks.Text = aStorage; } } }
void m_cmdNewPlace_Click() { using (NewPlaceDlg _dlg = new NewPlaceDlg()) { if (_dlg.ShowDialog(new WindowWrapper((IntPtr)MMUtils.MindManager.hWnd)) == System.Windows.Forms.DialogResult.OK) { System.Windows.Forms.MessageBox.Show(MMUtils.GetString("places.placecreated.message")); } } }
public CreateProjectDlg() { InitializeComponent(); aHelpProvider.HelpNamespace = MMUtils.instPath + "\\Synergy.chm"; aHelpProvider.SetHelpNavigator(this, HelpNavigator.Topic); aHelpProvider.SetHelpKeyword(this, "publishmap.htm"); // TODO Text = MMUtils.GetString("createprojectdlg.title"); lblPlace.Text = MMUtils.GetString("createprojectdlg.lblPlace.text"); lblProjectName.Text = MMUtils.GetString("createprojectdlg.lblProjectName.text"); btnCreate.Text = MMUtils.GetString("createprojectdlg.btnOK.text"); btnCancel.Text = MMUtils.GetString("buttonCancel.text"); lblProjectNameError.Text = ""; using (PlacesDB _db = new PlacesDB()) { DataTable _dt = _db.ExecuteQuery("select * from PLACES"); if (_dt.Rows.Count != 0) { foreach (DataRow _row in _dt.Rows) { comboPlaces.Items.Add(_row["PLACENAME"]); } } } // No places yet if (comboPlaces.Items.Count == 0) { if (MessageBox.Show(MMUtils.GetString("createprojectdlg.noplaces.text"), MMUtils.GetString("createprojectdlg.noplaces.caption"), MessageBoxButtons.YesNo, MessageBoxIcon.Question) == DialogResult.No) { this.DialogResult = DialogResult.Cancel; return; } using (Places.NewPlaceDlg _dlg = new Places.NewPlaceDlg()) { if (_dlg.ShowDialog(new WindowWrapper((IntPtr)MMUtils.MindManager.hWnd)) == DialogResult.Cancel) { this.DialogResult = DialogResult.Cancel; return; } aPlaceName = _dlg.aPlaceName; } comboPlaces.Items.Add(aPlaceName); } comboPlaces.Text = comboPlaces.Items[0].ToString(); }
private void btnOK_Click(object sender, EventArgs e) { foreach (int idx in checkedListBox.CheckedIndices) { string _pathorig = _links[idx]; string _pathdest = aLocalPath + checkedListBox.Items[idx]; try { if (System.IO.File.Exists(_pathdest)) // TODO потом сделать диалог { if (MessageBox.Show(String.Format(MMUtils.GetString("linkedfilesdlg.fileexists.message"), ""), MMUtils.GetString("linkedfilesdlg.fileexists.caption"), MessageBoxButtons.YesNo, MessageBoxIcon.Exclamation) == DialogResult.Yes) { System.IO.File.Copy(_pathorig, _pathdest, true); } } else { System.IO.File.Copy(_pathorig, _pathdest); } } catch (Exception _e) // TODO cause!!! read-only, etc... { MessageBox.Show(this, "Error " + _e.Message, "title", MessageBoxButtons.OK, MessageBoxIcon.Error); this.DialogResult = DialogResult.Cancel; } } // TODO меняем ссылку в локальной карте foreach (Topic t in doc.Range(MmRange.mmRangeAllTopics)) { if (t.Hyperlinks.Count > 0) { foreach (Hyperlink h in t.Hyperlinks) { foreach (int idx in checkedListBox.CheckedIndices) { string _path = _links[idx]; if (h.Address == _path) { h.Address = checkedListBox.Items[idx].ToString(); h.Absolute = false; break; } } } } } doc.Save(); _links.Clear(); }
public FirstUserDlg() { InitializeComponent(); aHelpProvider.HelpNamespace = MMUtils.instPath + "\\Synergy.chm"; aHelpProvider.SetHelpNavigator(this, HelpNavigator.Topic); aHelpProvider.SetHelpKeyword(this, "synergy_struct.htm"); btnOK.Text = MMUtils.GetString("firstuserdlg.btnOK.text"); btnCancel.Text = MMUtils.GetString("buttonCancel.text"); lblWelcome.Text = MMUtils.GetString("firstuserdlg.lblWelcome.text"); }
public void GetLevelData() { lvlExit.levelBuild = ""; Vector3[] v3ObjectsRotations = new Vector3[iNumberOfObjects]; Color[] clrObjects = new Color[iNumberOfColors]; bool[] bMovementObjects = new bool[iNumberOfMovementObjects]; int iObjIndex = 0, iClrIndex = 0, iObjMoveIndex = 0; for (int i = 0; i < tiles.Length; i++) { lvlExit.levelBuild += ((int)tiles[i].GetComponent <Tile>().ttTile).ToString() + MMConstants.LEVEL_SEPARATOR; if (MMUtils.IsScenarioObject(tiles[i].GetComponent <Tile>().ttTile)) { v3ObjectsRotations[iObjIndex] = tiles[i].transform.rotation.eulerAngles; iObjIndex++; } if (MMUtils.IsColorObject(tiles[i].GetComponent <Tile>().ttTile)) { clrObjects[iClrIndex] = tiles[i].GetComponent <Tile>().clrObject; iClrIndex++; } if (MMUtils.IsPushableObject(tiles[i].GetComponent <Tile>().ttTile)) { bMovementObjects[iObjMoveIndex] = tiles[i].GetComponent <Tile>().bMovementOn; iObjMoveIndex++; } } lvlExit.objColor = new Color[iNumberOfColors]; lvlExit.objColor = (Color[])clrObjects.Clone(); lvlExit.objRotation = new Vector3[iNumberOfObjects]; lvlExit.objRotation = (Vector3[])v3ObjectsRotations.Clone(); lvlExit.objMovementEnabled = new bool[iNumberOfMovementObjects]; lvlExit.objMovementEnabled = (bool[])bMovementObjects.Clone(); lvlExit.levelBuild = lvlExit.levelBuild.Substring(0, lvlExit.levelBuild.Length - 1); lvlExit.MaxSize = iTileSize; #if UNITY_EDITOR AssetDatabase.SaveAssets(); EditorSceneManager.MarkSceneDirty(EditorSceneManager.GetActiveScene()); EditorUtility.SetDirty(lvlExit); #endif print("DATA GENERATED!"); }
void m_cmdNewProject_Click() { using (CreateProjectDlg _dlg = new CreateProjectDlg()) { System.Windows.Forms.DialogResult result = _dlg.ShowDialog(new WindowWrapper((IntPtr)MMUtils.MindManager.hWnd)); if (result == System.Windows.Forms.DialogResult.OK) { System.Windows.Forms.MessageBox.Show(String.Format( MMUtils.GetString("createprojectdlg.newprojectcreated.message"), _dlg.txtProjectName.Text)); } } }
public void SetLevelStatus(string sLevel, int iLevelDim) { string[] sLevelArray = sLevel.Split(MMConstants.LEVEL_SEPARATOR); iLevelStatus = new int[iLevelDim, iLevelDim]; for (int x = 0; x < iLevelDim; x++) { for (int z = 0; z < iLevelDim; z++) { int index = MMUtils.MatrixIndexesToListIndex(x, z, iLevelDim); iLevelStatus[x, z] = int.Parse(sLevelArray[index]); } } }
public LogOutDlg() { InitializeComponent(); Text = MMUtils.GetString("logoutdlg.dlgtitle.text"); btnExit.Text = MMUtils.GetString("logoutdlg.btnExit.text"); checkBoxForgetMe.Text = MMUtils.GetString("logoutdlg.checkBoxForgetMe.text"); tltForgetMe.SetToolTip(this.checkBoxForgetMe, MMUtils.GetString("logoutdlg.checkBoxForgetMe.tooltip")); this.Location = new System.Drawing.Point(MMUtils.MindManager.Left + MMUtils.MindManager.Width - 510, MMUtils.MindManager.Top + MMUtils.MindManager.Height - this.Height - 17); }
public ProjectReceivedDlg() { InitializeComponent(); aHelpProvider.HelpNamespace = MMUtils.instPath + "\\Synergy.chm"; aHelpProvider.SetHelpNavigator(this, HelpNavigator.Topic); aHelpProvider.SetHelpKeyword(this, "publishmap.htm"); // TODO Text = MMUtils.GetString("receivedprojectdlg.dlgtitle.text"); lblProject.Text = MMUtils.GetString("receivedprojectdlg.lblPlace.text"); lblOr.Text = MMUtils.GetString("publishmapdlg.lblOr.text"); linkNewPlace.Text = MMUtils.GetString("receivedmapdlg.linkNewPlace.text"); btnCancel.Text = MMUtils.GetString("buttonCancel.text"); }
public LinkToFileDlg() { InitializeComponent(); aHelpProvider.HelpNamespace = MMUtils.instPath + "\\Synergy.chm"; aHelpProvider.SetHelpNavigator(this, HelpNavigator.Topic); aHelpProvider.SetHelpKeyword(this, "publishmap.htm"); // TODO // TODO Text = MMUtils.GetString("publishmapdlg.dlgtitle.text"); lblLink.Text = MMUtils.GetString("publishmapdlg.lblPickProject.text"); btnYes.Text = MMUtils.GetString("publishmapdlg.lblOr.text"); btnNo.Text = MMUtils.GetString("publishmapdlg.linkNewProject.text"); }