diff --git a/editor/studio/AMXX_Studio.dof b/editor/studio/AMXX_Studio.dof index 3bc0eae4..4c5fa94e 100755 --- a/editor/studio/AMXX_Studio.dof +++ b/editor/studio/AMXX_Studio.dof @@ -115,7 +115,7 @@ AutoIncBuild=1 MajorVer=1 MinorVer=3 Release=0 -Build=12 +Build=14 Debug=0 PreRelease=0 Special=0 @@ -126,7 +126,7 @@ CodePage=1252 [Version Info Keys] CompanyName=AMX Mod X Dev Team FileDescription= -FileVersion=1.3.0.12 +FileVersion=1.3.0.14 InternalName= LegalCopyright= LegalTrademarks= diff --git a/editor/studio/AMXX_Studio.exe b/editor/studio/AMXX_Studio.exe index af2804d8..67a50a87 100755 Binary files a/editor/studio/AMXX_Studio.exe and b/editor/studio/AMXX_Studio.exe differ diff --git a/editor/studio/AMXX_Studio.res b/editor/studio/AMXX_Studio.res index 2d775603..2c0170f5 100755 Binary files a/editor/studio/AMXX_Studio.res and b/editor/studio/AMXX_Studio.res differ diff --git a/editor/studio/UnitCodeInspector.pas b/editor/studio/UnitCodeInspector.pas index 52186319..566a4c33 100755 --- a/editor/studio/UnitCodeInspector.pas +++ b/editor/studio/UnitCodeInspector.pas @@ -54,6 +54,7 @@ var eCILine: Integer; FItems: TObjectList; STLItem: TSelectionTextList; eStock: Boolean; + eUpdating: Boolean; implementation @@ -371,12 +372,15 @@ end; procedure UpdateCI(eLine: Integer); begin + if eUpdating then exit; + eUpdating := True; if not Plugin_UpdateCodeInspector(GetCurrLang.Name, ActiveDoc.FileName, frmMain.tsMain.Items[frmMain.tsMain.ActiveTabIndex].Caption, True) then exit; if GetCurrLang.Name = 'Pawn' then begin UpdateCI_Pawn(eLine); Plugin_UpdateCodeInspector(GetCurrLang.Name, ActiveDoc.FileName, frmMain.tsMain.Items[frmMain.tsMain.ActiveTabIndex].Caption, False); end; + eUpdating := False; end; procedure UpdateCI_Pawn(eLine: Integer); @@ -387,6 +391,7 @@ var eCurrLine, eBackupLine: string; eVarCount, eConstCount: Integer; eFound: Boolean; begin + eCILine := eLine; eBackupLine := frmMain.sciEditor.Lines[eLine]; // Prevent parse errors eBackupLine := StringReplace(eBackupLine, #1, '', [rfReplaceAll]); @@ -576,9 +581,7 @@ begin eStr.Free; frmMain.jviCode.EndUpdate; if eLine <> eCILine then - UpdateCI_Pawn(eLine) - else - eCILine := -1; + UpdateCI_Pawn(eLine); exit; end; { Return } @@ -598,9 +601,7 @@ begin eStr.Free; frmMain.jviCode.EndUpdate; if eLine <> eCILine then - UpdateCI_Pawn(eLine) - else - eCILine := -1; + UpdateCI_Pawn(eLine); exit; end; { For-Loop } @@ -639,9 +640,7 @@ begin eStr.Free; frmMain.jviCode.EndUpdate; if eLine <> eCILine then - UpdateCI_Pawn(eLine) - else - eCILine := -1; + UpdateCI_Pawn(eLine); exit; end; { While-Loops } @@ -689,9 +688,7 @@ begin eStr.Free; frmMain.jviCode.EndUpdate; if eLine <> eCILine then - UpdateCI_Pawn(eLine) - else - eCILine := -1; + UpdateCI_Pawn(eLine); exit; end; @@ -779,9 +776,7 @@ begin eStr.Free; frmMain.jviCode.EndUpdate; if eLine <> eCILine then - UpdateCI_Pawn(eLine) - else - eCILine := -1; + UpdateCI_Pawn(eLine); exit; end else if (Pos('(', eCurrLine) <> Pos(')', eCurrLine)) and (Assignment(eBackupLine) = '') then begin // Function Call @@ -896,9 +891,7 @@ begin eStr2.Free; frmMain.jviCode.EndUpdate; if eLine <> eCILine then - UpdateCI_Pawn(eLine) - else - eCILine := -1; + UpdateCI_Pawn(eLine); exit; end { Assignment } @@ -922,9 +915,7 @@ begin eStr.Free; frmMain.jviCode.EndUpdate; if eLine <> eCILine then - UpdateCI_Pawn(eLine) - else - eCILine := -1; + UpdateCI_Pawn(eLine); exit; end; @@ -934,9 +925,7 @@ begin frmMain.jviCode.EndUpdate; if eLine <> eCILine then - UpdateCI_Pawn(eLine) - else - eCILine := -1; + UpdateCI_Pawn(eLine); end; { TSTLWrapper } @@ -1153,7 +1142,8 @@ begin if Trim(eLine) <> '' then frmMain.sciEditor.Lines[eCILine] := eLine; -// UpdateCI(eCILine); + frmMain.mnuModified.Caption := lModified; + ActiveDoc.Modified := True; end; initialization diff --git a/editor/studio/UnitfrmMain.pas b/editor/studio/UnitfrmMain.pas index 074463ae..9eca6501 100755 --- a/editor/studio/UnitfrmMain.pas +++ b/editor/studio/UnitfrmMain.pas @@ -1323,7 +1323,7 @@ begin case tsMain.ActiveTabIndex of 0: Collection := PawnProjects; 1: Collection := CPPProjects; - else Collection := OtherProjects; + else Collection := OtherProjects; end; frmAllFilesForm.Caption := lCloseAllCaption1; @@ -2847,17 +2847,18 @@ end; procedure TfrmMain.trvExplorerClick(Sender: TObject); begin - if Assigned(trvExplorer.Selected) then + if Assigned(trvExplorer.Selected) then begin + if trvExplorer.Selected.ImageIndex >= 42 then exit; + UpdateCI(Integer(trvExplorer.Selected.Data)); + end; end; procedure TfrmMain.jviCodeItemValueChanged(Sender: TObject; Item: TJvCustomInspectorItem); begin - if GetCurrLang.Name = 'Pawn' then begin - eCILine := sciEditor.GetCurrentLineNumber; + if GetCurrLang.Name = 'Pawn' then RebuildLine; - end; end; procedure TfrmMain.mnuRestoreBackupClick(Sender: TObject);