diff --git a/uppsrc/Core/Core.h b/uppsrc/Core/Core.h index f9796ae87..0a5cae8a8 100644 --- a/uppsrc/Core/Core.h +++ b/uppsrc/Core/Core.h @@ -419,13 +419,11 @@ NTL_MOVEABLE(RECT) //Place it to the begining of each file to be the first function called in whole executable... //This is now backup to init_priority attribute in heapdbg.cpp -//$- struct MemDiagCls { MemDiagCls(); ~MemDiagCls(); }; static const MemDiagCls sMemDiagHelper__upp__; -//$+ #endif diff --git a/uppsrc/Core/Fn.h b/uppsrc/Core/Fn.h index eec0a62e3..100df095b 100644 --- a/uppsrc/Core/Fn.h +++ b/uppsrc/Core/Fn.h @@ -6,9 +6,6 @@ #undef max #endif -//$-template inline constexpr const T& min(const T& a, const T& b, ...); -//$-template inline constexpr const T& max(const T& a, const T& b, ...); - template constexpr const T& min(const T& a, const T& b) { @@ -33,16 +30,12 @@ constexpr const T& max(const T& a, const T& b, const Args& ...args) return max(a, max(b, args...)); } -//$+ - template constexpr T clamp(const T& x, const T& min_, const T& max_) { return min(max(x, min_), max_); } -//$-constexpr int findarg(const T& x, const T1& p0, ...); - template constexpr int findarg(const T& x, const K& k) { @@ -58,8 +51,6 @@ constexpr int findarg(const T& sel, const K& k, const L& ...args) return q >= 0 ? q + 1 : -1; } -//$-constexpr auto decode(const T& x, const T1& p0, const V1& v0, ...); - template constexpr const char *decode_chr_(const T& sel, const char *def) { @@ -90,8 +81,6 @@ constexpr V decode(const T& sel, const K& k, const V& v, const L& ...args) return sel == k ? v : (V)decode(sel, args...); } -//$-constexpr T get_i(int i, const T& p0, const T1& p1, ...); - template constexpr A get_i(int i, const A& p0, const T& ...args) { @@ -106,8 +95,6 @@ constexpr const P *get_i(int i, const P* p0, const T& ...args) return list[clamp(i, 0, (int)sizeof...(args))]; } -//$-void foreach_arg(F fn, const T& p0, const T1& p1, ...); - template void foreach_arg(F fn, V&& v) { @@ -121,8 +108,6 @@ void foreach_arg(F fn, V&& v, Args&& ...args) foreach_arg(fn, std::forward(args)...); } -//$+ - template void iter_set(I t, Args&& ...args) { diff --git a/uppsrc/Core/SplitMerge.h b/uppsrc/Core/SplitMerge.h index 1d9cc39b6..4a2a98e62 100644 --- a/uppsrc/Core/SplitMerge.h +++ b/uppsrc/Core/SplitMerge.h @@ -19,27 +19,6 @@ Vector Split(const wchar *s, const wchar *text, bool ignoreempty = true String Join(const Vector& im, const String& delim, bool ignoreempty = false); WString Join(const Vector& im, const WString& delim, bool ignoreempty = false); -//$ bool SplitTo(const char *s, int delim, bool ignoreempty, String& p1...); -//$ bool SplitTo(const char *s, int delim, String& p1...); -//$ bool SplitTo(const char *s, int (*filter)(int), String& p1...); -//$ bool SplitTo(const char *s, int (*filter)(int), String& p1...); -//$ bool SplitTo(const char *s, const char *delim, bool ignoreempty, String& p1...); -//$ bool SplitTo(const char *s, const char *delim, String& p1...); - -//$ bool SplitTo(const wchar *s, int delim, bool ignoreempty, WString& p1...); -//$ bool SplitTo(const wchar *s, int delim, WString& p1...); -//$ bool SplitTo(const wchar *s, int (*filter)(int), WString& p1...); -//$ bool SplitTo(const wchar *s, int (*filter)(int), WString& p1...); -//$ bool SplitTo(const wchar *s, const wchar *delim, bool ignoreempty, WString& p1...); -//$ bool SplitTo(const wchar *s, const wchar *delim, WString& p1...); - -//$ String Merge(const char *delim, String& p1...); -//$ WString Merge(const wchar *delim, WString& p1...); - -//$ void MergeWith(String& dest, const char *delim, String& p1...); -//$ void MergeWith(WString& dest, const wchar *delim, WString& p1...); - -//$- template bool SplitTo(const char *s, int delim, bool ignoreempty, Args& ...args) { @@ -151,5 +130,3 @@ WString Merge(const wchar *delim, const Args& ...args) MergeWith(r, delim, args...); return r; } - -//$- diff --git a/uppsrc/CtrlCore/CocoCtrl.h b/uppsrc/CtrlCore/CocoCtrl.h index 7288050fb..55603fdbc 100644 --- a/uppsrc/CtrlCore/CocoCtrl.h +++ b/uppsrc/CtrlCore/CocoCtrl.h @@ -1,4 +1,3 @@ -//$ class Upp::Ctrl { private: friend struct MMCtrl; friend struct MMImp; @@ -31,4 +30,3 @@ public: void RegisterCocoaDropFormats(); static Rect GetScreenArea(Point pt); -//$ }; diff --git a/uppsrc/CtrlCore/CocoTop.h b/uppsrc/CtrlCore/CocoTop.h index acbee0398..ff9a89d09 100644 --- a/uppsrc/CtrlCore/CocoTop.h +++ b/uppsrc/CtrlCore/CocoTop.h @@ -1,4 +1,3 @@ -//$ class Upp::TopWindow { protected: friend struct MMImp; @@ -22,4 +21,3 @@ public: Event WhenDockMenu; void SetMainMenu(Event menu); -//$ }; \ No newline at end of file diff --git a/uppsrc/CtrlCore/Gtk.h b/uppsrc/CtrlCore/Gtk.h index 3334cd3c3..48d73eb2f 100644 --- a/uppsrc/CtrlCore/Gtk.h +++ b/uppsrc/CtrlCore/Gtk.h @@ -179,7 +179,6 @@ Vector GetPropertyInts(GdkWindow *w, const char *property); #define GUIPLATFORM_KEYCODES_INCLUDE -//$ struct Ctrl::Top { #define GUIPLATFORM_CTRL_TOP_DECLS \ GtkWidget *window; \ GtkIMContext *im_context; \ @@ -187,7 +186,6 @@ Vector GetPropertyInts(GdkWindow *w, const char *property); GtkIMContext *im_context_multi; \ int64 cursor_id; \ int id; \ -//$ } #define GUIPLATFORM_CTRL_DECLS_INCLUDE diff --git a/uppsrc/CtrlCore/GtkCtrl.h b/uppsrc/CtrlCore/GtkCtrl.h index c0186916c..a796770c5 100644 --- a/uppsrc/CtrlCore/GtkCtrl.h +++ b/uppsrc/CtrlCore/GtkCtrl.h @@ -1,5 +1,3 @@ -//$ namespace Upp { -//$ class Ctrl { void Create(Ctrl *owner, bool popup); static gboolean GtkProc(GtkWidget *widget, GdkEvent *event, gpointer user_data); @@ -213,5 +211,3 @@ public: GtkWindow *gtk() const; static GdkFilterReturn RootKeyFilter(GdkXEvent *xevent, GdkEvent *event, gpointer data); - -//$ }}; diff --git a/uppsrc/CtrlCore/GtkTop.h b/uppsrc/CtrlCore/GtkTop.h index 66d47704b..cb44b5f6a 100644 --- a/uppsrc/CtrlCore/GtkTop.h +++ b/uppsrc/CtrlCore/GtkTop.h @@ -1,4 +1,3 @@ -//$ class Upp::TopWindow : Ctrl { ImageGdk gdk_icon; ImageGdk gdk_largeicon; bool topmost; @@ -12,4 +11,3 @@ static gboolean StateEvent(GtkWidget *widget, GdkEventWindowState *event, gpointer user_data); friend class Ctrl; -//$ }; diff --git a/uppsrc/CtrlCore/Win32Ctrl.h b/uppsrc/CtrlCore/Win32Ctrl.h index b73c28dc6..76948195b 100644 --- a/uppsrc/CtrlCore/Win32Ctrl.h +++ b/uppsrc/CtrlCore/Win32Ctrl.h @@ -1,5 +1,3 @@ -//$ namespace Upp { -//$ class Ctrl { private: bool activex:1; bool isdhctrl:1; @@ -72,5 +70,3 @@ public: static void InitWin32(HINSTANCE hinst); static void ExitWin32(); static void GuiFlush() { ::GdiFlush(); } -//$ }; -//$ }; \ No newline at end of file diff --git a/uppsrc/CtrlCore/Win32Top.h b/uppsrc/CtrlCore/Win32Top.h index bd28d9d3d..5d2cb43da 100644 --- a/uppsrc/CtrlCore/Win32Top.h +++ b/uppsrc/CtrlCore/Win32Top.h @@ -1,4 +1,3 @@ -//$ class Upp::TopWindow { public: virtual LRESULT WindowProc(UINT message, WPARAM wParam, LPARAM lParam); @@ -16,4 +15,3 @@ public: dword GetStyle() const { return style; } TopWindow& ExStyle(dword _exstyle); dword GetExStyle() const { return exstyle; } -//$ }; \ No newline at end of file diff --git a/uppsrc/CtrlCore/X11Ctrl.h b/uppsrc/CtrlCore/X11Ctrl.h index 759bc4fd3..3ba866acf 100644 --- a/uppsrc/CtrlCore/X11Ctrl.h +++ b/uppsrc/CtrlCore/X11Ctrl.h @@ -1,5 +1,3 @@ -//$ namespace Upp { -//$ class Ctrl { bool ignoretakefocus:1; protected: struct XWindow { @@ -110,4 +108,3 @@ public: static void InitX11(const char *display); static void ExitX11(); static void GuiFlush() { XFlush(Xdisplay); } -//$ }}; diff --git a/uppsrc/CtrlCore/X11Top.h b/uppsrc/CtrlCore/X11Top.h index 78772790c..2c619fe50 100644 --- a/uppsrc/CtrlCore/X11Top.h +++ b/uppsrc/CtrlCore/X11Top.h @@ -1,4 +1,3 @@ -//$ class Upp::TopWindow { protected: virtual void EventProc(XWindow& w, XEvent *event); private: @@ -20,4 +19,4 @@ private: WString title2; static Rect windowFrameMargin; -//$ }; + diff --git a/uppsrc/CtrlLib/ArrayCtrl.cpp b/uppsrc/CtrlLib/ArrayCtrl.cpp index fe0f24415..b8fd56875 100644 --- a/uppsrc/CtrlLib/ArrayCtrl.cpp +++ b/uppsrc/CtrlLib/ArrayCtrl.cpp @@ -2151,7 +2151,6 @@ void ArrayCtrl::AddSeparator() DisableLine(ii); } -//$- #define E__Addv(I) Set0(q, I - 1, p##I) #define E__AddF(I) \ void ArrayCtrl::Add(__List##I(E__Value)) { \ @@ -2160,7 +2159,6 @@ void ArrayCtrl::Add(__List##I(E__Value)) { \ AfterSet(q); \ } __Expand(E__AddF) -//$+ void ArrayCtrl::Insert(int i, int count) { if(i < array.GetCount()) { diff --git a/uppsrc/CtrlLib/ArrayCtrl.h b/uppsrc/CtrlLib/ArrayCtrl.h index 91d9a96da..068b06fa9 100644 --- a/uppsrc/CtrlLib/ArrayCtrl.h +++ b/uppsrc/CtrlLib/ArrayCtrl.h @@ -489,10 +489,8 @@ public: void Add(Vector&& v) { Set(array.GetCount(), pick(v)); } void Add(const Nuller& null) { Add((Value)Null); } void Add(const VectorMap& m); -//$-void Add(const Value& [, const Value& ]...); template void Add(const Args& ...args) { Add(gather>(args...)); } -//$+ void SetMap(int i, const ValueMap& m); void AddMap(const ValueMap& m); diff --git a/uppsrc/Draw/iml_header.h b/uppsrc/Draw/iml_header.h index 1253ca825..3e13a8dc9 100644 --- a/uppsrc/Draw/iml_header.h +++ b/uppsrc/Draw/iml_header.h @@ -1,7 +1,5 @@ //#BLITZ_APPROVE -//$- - #define IMAGE_META(k, v) #define IMAGE_SCAN(s) #define IMAGE_PACKED(n, d) diff --git a/uppsrc/Draw/iml_source.h b/uppsrc/Draw/iml_source.h index 82c99d8dc..5ebc84247 100644 --- a/uppsrc/Draw/iml_source.h +++ b/uppsrc/Draw/iml_source.h @@ -1,7 +1,5 @@ //#BLITZ_APPROVE -//$ - #define IMAGE_META(k, v) #define PREMULTIPLIED diff --git a/uppsrc/ide/Assist.cpp b/uppsrc/ide/Assist.cpp index 8de81f863..563dd9868 100644 --- a/uppsrc/ide/Assist.cpp +++ b/uppsrc/ide/Assist.cpp @@ -374,8 +374,10 @@ CurrentFileContext AssistEditor::CurrentContext(int pos) cfx.filename = master_source; } else - if(!IsHeaderFile(cfx.filename)) + if(!IsHeaderFile(cfx.filename)) { cfx.content.Clear(); + cfx.is_source_file = false; + } } } #ifdef _DEBUG @@ -413,12 +415,14 @@ void AssistEditor::SyncCurrentFile(const CurrentFileContext& cfx) void AssistEditor::SyncCurrentFile() { - int line_delta; - CurrentFileContext cfx = CurrentContext(); - SyncCurrentFile(cfx); + if(is_source_file) { + int line_delta; + CurrentFileContext cfx = CurrentContext(); + SyncCurrentFile(cfx); + } } -void AssistEditor::NewFile() +void AssistEditor::NewFile(bool reloading) { annotations.Clear(); references.Clear(); @@ -426,22 +430,26 @@ void AssistEditor::NewFile() SyncMaster(); CurrentFileContext cfx = CurrentContext(); -// DLOG("============="); -// DDUMP(cfx.real_filename); - annotating = true; - int q = CodeIndex().Find(cfx.real_filename); -// DDUMP(q); - if(q >= 0) { - const FileAnnotation& f = CodeIndex()[q]; - SetAnnotations(f); -// DDUMP(f.time); - if(f.defines == cfx.defines && f.includes == cfx.includes && f.time >= GetFileTime(cfx.real_filename)) { - annotating = false; - PutVerbose(cfx.real_filename + " annotations loaded from index"); - } - } + if(!reloading) + is_source_file = cfx.is_source_file; - SyncCurrentFile(cfx); + if(is_source_file) { + // DLOG("============="); + // DDUMP(cfx.real_filename); + annotating = true; + int q = CodeIndex().Find(cfx.real_filename); + // DDUMP(q); + if(q >= 0) { + const FileAnnotation& f = CodeIndex()[q]; + SetAnnotations(f); + // DDUMP(f.time); + if(f.defines == cfx.defines && f.includes == cfx.includes && f.time >= GetFileTime(cfx.real_filename)) { + annotating = false; + PutVerbose(cfx.real_filename + " annotations loaded from index"); + } + } + SyncCurrentFile(cfx); + } } void AssistEditor::Assist(bool macros) @@ -544,6 +552,9 @@ bool sILess(const String& a, const String& b) void AssistEditor::Complete() { + if(!is_source_file) + return; + CloseAssist(); int c = GetCursor32(); diff --git a/uppsrc/ide/Assist.h b/uppsrc/ide/Assist.h index 2503e0cb9..729ad5504 100644 --- a/uppsrc/ide/Assist.h +++ b/uppsrc/ide/Assist.h @@ -97,6 +97,7 @@ struct AssistEditor : CodeEditor, Navigator { } assist_display; RichTextCtrl annotation_popup; + bool is_source_file = false; bool annotating = false; Vector annotations; Vector references; @@ -140,7 +141,7 @@ struct AssistEditor : CodeEditor, Navigator { void SyncCurrentFile(const CurrentFileContext& ctx); void SyncCurrentFile(); void SyncMaster(); - void NewFile(); + void NewFile(bool reloading); bool DoIncludeTrick(Index& visited, int level, StringBuffer& out, String path, const String& target_path, int& line_delta); void MakeIncludeTrick(CurrentFileContext& cfx); diff --git a/uppsrc/ide/AssistDisplay.cpp b/uppsrc/ide/AssistDisplay.cpp index 35f1d4bec..99bdd1e1a 100644 --- a/uppsrc/ide/AssistDisplay.cpp +++ b/uppsrc/ide/AssistDisplay.cpp @@ -90,7 +90,7 @@ int PaintCpp(Draw& w, const Rect& r, int kind, const String& name, const String& int count = n.GetCount(); if(retval_last) for(int i = 0; i < n.GetCount(); i++) - if(n[i].type == ITEM_NAME || pretty[n[i].pos] == '(') { + if(findarg(n[i].type, ITEM_NAME, ITEM_OPERATOR) >= 0 || pretty[n[i].pos] == '(') { PaintText(w, x, y, pretty, n, i, count - i, focuscursor, ink, false); count = i; while(count) { // remove trailing spaces diff --git a/uppsrc/ide/IncludeTrick.cpp b/uppsrc/ide/IncludeTrick.cpp index e9c05a8f9..95527b709 100644 --- a/uppsrc/ide/IncludeTrick.cpp +++ b/uppsrc/ide/IncludeTrick.cpp @@ -6,7 +6,6 @@ void AssistEditor::SyncMaster() { - TIMESTOP("SyncHeaders"); master_source.Clear(); String editfile = NormalizePath(theide->editfile); if(editfile.GetCount() && IsCHeaderFile(editfile)) { diff --git a/uppsrc/ide/clang/clang.h b/uppsrc/ide/clang/clang.h index 8c02177ca..caf890ab8 100644 --- a/uppsrc/ide/clang/clang.h +++ b/uppsrc/ide/clang/clang.h @@ -151,6 +151,7 @@ struct CurrentFileContext { String includes; String defines; String content; + bool is_source_file = true; }; struct CppFileInfo : Moveable { diff --git a/uppsrc/ide/clang/done.txt b/uppsrc/ide/clang/done.txt index 43ea6b518..8b154f17d 100644 --- a/uppsrc/ide/clang/done.txt +++ b/uppsrc/ide/clang/done.txt @@ -1,5 +1,33 @@ DONE: +- check dialog mode of navigator + +- missing preamble folder - check preamble creation + +- AutoComplete remove duplicate lines + +- use codeindex info for file annotations + +- Hdepend NoConsole + +- current file indexing + +- Navigator: () -> operator char * + +- when scope is selected in navigator, search should be ingored + +- optimise loading + +- NewFile gets called on .log update resulting in SetCurrentFile and SyncHeaders (maybe not?) + +- Alt+J bool IsIgnored(const String& id) jump on Find + +- * line in navigator + +- Enel/Scenarios.cpp:52 int i = list.; + +- inside AutoObstacleTerrainsLayerMulti, J inside CoFor + - OpenWind/PowerCurve.cpp:3883 J on GetElevation - Vector/VectorLayer.cpp:870 J on GetBuffer diff --git a/uppsrc/ide/clang/todo.txt b/uppsrc/ide/clang/todo.txt index 7e4391fee..c26d7bb0b 100644 --- a/uppsrc/ide/clang/todo.txt +++ b/uppsrc/ide/clang/todo.txt @@ -1,15 +1,36 @@ -CRITICAL: +EPICS: + += Handling of C files +- C:\u\llvm_ide\uppsrc\plugin\z\lib\compress.c (22:24) unknown type name 'dest' - do we need CBLITZ? +- .c files + += AltC fixes +- AltC Vector Indexer::jobs; should be: Vector Indexer::jobs; +- Alt+C static void AtShutdown(void (*shutdownfn)()); + += Assist configuration +- Option "first config only" +- Option "reindex manual" (autosetup based on CPU cores) +- options to disable assist + += Annotations/Visitor/formatting + += Navigator +- class AString : public B { - remove template<> in navigator +- navigator "BAD" - should be first +- Navigator cycling struct AssistEditor : CodeEditor, Navigator { goes to contructor as well +- (unnamed) BAD -> LogicalReport - fix enum in autocomplete +- Sort navigator in header order + += Macros +- first macro in the file (AssistTest) is ignored ISUES: - out of sync SetCurrentFile -- NewFile gets called on .log update resulting in SetCurrentFile and SyncHeaders (maybe not?) - - MSVC -- optimise loading - - TPP HELP WINDOW->EDITOR - go to active label - Do TODOs @@ -20,8 +41,6 @@ ISUES: - Remove template < > in autocomplete -- current file indexing - - check editor mode - Error output: (): x += GetTextSize(" Ôćĺ ", StdFont()); @@ -30,44 +49,16 @@ ISUES: - Core/String.h - conversion operators wrong nests (template argument) -- check dialog mode of navigator - - void NavDlg::GoTo() -- Hdepend NoConsole - -- AltC Vector Indexer::jobs; should be: Vector Indexer::jobs; - -- C:\u\llvm_ide\uppsrc\plugin\z\lib\compress.c (22:24) unknown type name 'dest' - do we need CBLITZ? - -- Alt+C static void AtShutdown(void (*shutdownfn)()); - -- class AString : public B { - remove template<> in navigator - - unnamed union in String0 -- options to disable assist - -- * line in navigator - -- first macro in the file (AssistTest) is ignored - -- when scope is selected in navigator, search should be ingored - -- use codeindex info for file annotations - -- AutoComplete remove duplicate lines - - Wait for indexer? - FFound key to reuse pane for repeated finds -- Sort navigator in header order - - mainconfig/dependecies -- Alt+J bool IsIgnored(const String& id) jump on Find - - Visitor.cpp hasid = false - remove initialisation - Remove //$ @@ -78,40 +69,20 @@ ISUES: - Cancel Assist when cursor moves out (test with above) -- .c files - - check default parameters and virtuals / alt+c, commentdp - String GetClass(const AnnotationItem& m) vs m.nest - do we need GetClass? -- Navigator cycling struct AssistEditor : CodeEditor, Navigator { goes to contructor as well - - Wind/MetMastLayer.cpp:6354 no jump on sqrt (?) - Macros with PPInfo -- Option "first config only" - -- Option "reindex manual" (autosetup based on CPU cores) - - Icons Alt-J/I/U - void ClearTurbineVarsCache() - after switching main config, reparse file -- (unnamed) BAD -> LogicalReport - fix enum in autocomplete - -- navigator "BAD" - should be first - - Core/Parser.h slow for some reason... -- inside AutoObstacleTerrainsLayerMulti, J inside CoFor - -- Enel/Scenarios.cpp:52 int i = list.; - -- missing preamble folder - check preamble creation - -- Navigator: () -> operator char * - NONCLANG: diff --git a/uppsrc/ide/ide.h b/uppsrc/ide/ide.h index c449ea717..477ef4ecf 100644 --- a/uppsrc/ide/ide.h +++ b/uppsrc/ide/ide.h @@ -773,7 +773,7 @@ public: void ChangeCharset(); void FlushFile(); void EditFile0(const String& path, byte charset, int spellcheck_comments, - const String& headername = Null); + const String& headername = Null, bool reloading = false); void EditFile(const String& path); void AddEditFile(const String& path); void ReloadFile(); diff --git a/uppsrc/ide/idebar.cpp b/uppsrc/ide/idebar.cpp index 4ff381e43..39f18974d 100644 --- a/uppsrc/ide/idebar.cpp +++ b/uppsrc/ide/idebar.cpp @@ -758,7 +758,7 @@ void Ide::BrowseMenu(Bar& menu) menu.Add(AK_GOTO, THISBACK(SearchCode)) .Enable(!designer) .Help("Go to given line"); - menu.Add(AK_GOTOGLOBAL, THISBACK(NavigatorDlg)); +// menu.Add(AK_GOTOGLOBAL, THISBACK(NavigatorDlg)); menu.Add(!designer, AK_JUMPS, THISBACK(ContextGoto)); menu.Add(!designer, AK_SWAPS, THISBACK(SwapS)); menu.Add(!designer, AK_USAGE, THISBACK(Usage)); diff --git a/uppsrc/ide/idefile.cpp b/uppsrc/ide/idefile.cpp index 0f379849d..892fe0bb3 100644 --- a/uppsrc/ide/idefile.cpp +++ b/uppsrc/ide/idefile.cpp @@ -460,7 +460,7 @@ bool Ide::FileRemove() return true; } -void Ide::EditFile0(const String& path, byte charset, int spellcheck_comments, const String& headername) +void Ide::EditFile0(const String& path, byte charset, int spellcheck_comments, const String& headername, bool reloading) { animate_current_file = animate_current_file_dir = animate_autocomplete = animate_autocomplete_dir = 0; @@ -618,7 +618,7 @@ void Ide::EditFile0(const String& path, byte charset, int spellcheck_comments, c editor.SyncNavigatorShow(); editor.CheckEdited(true); editor.SyncNavigator(); - editor.NewFile(); + editor.NewFile(reloading); editfile_repo = GetRepoKind(editfile); editfile_includes = IncludesMD5(); } @@ -855,7 +855,7 @@ void Ide::ReloadFile() int ln = editor.GetCursorLine(); editfile.Clear(); int sc = filelist.GetSbPos(); - EditFile0(fn, editor.GetCharset(), editor.GetSpellcheckComments()); + EditFile0(fn, editor.GetCharset(), editor.GetSpellcheckComments(), Null, true); filelist.SetSbPos(sc); int l = LocateLine(data, ln, ~editor); editor.SetCursor(editor.GetPos64(l));