diff options
author | Uffe Jakobsen | 2022-12-17 23:53:46 +0100 |
---|---|---|
committer | Uffe Jakobsen | 2022-12-17 23:53:46 +0100 |
commit | 53328fe888e2bbf3aa2a89d0004d6ca25666929c (patch) | |
tree | d1ab40a65f7653c00a99157114ef7f360fbf4cf7 /codelite-fsw-symlink.patch | |
parent | 799cac797db4adf4887b4ba3f72baa52d6afad0f (diff) | |
download | aur-53328fe888e2bbf3aa2a89d0004d6ca25666929c.tar.gz |
Refresh FSW patch
Diffstat (limited to 'codelite-fsw-symlink.patch')
-rw-r--r-- | codelite-fsw-symlink.patch | 64 |
1 files changed, 57 insertions, 7 deletions
diff --git a/codelite-fsw-symlink.patch b/codelite-fsw-symlink.patch index bac89f38102b..3deea4ebf48d 100644 --- a/codelite-fsw-symlink.patch +++ b/codelite-fsw-symlink.patch @@ -78,10 +78,19 @@ index 6bbdc24c5..462fcdc13 100644 \ No newline at end of file +} diff --git LiteEditor/mainbook.cpp LiteEditor/mainbook.cpp -index 9798c7189..e457d8c2d 100644 +index 9798c7189..a77c5a30b 100644 --- LiteEditor/mainbook.cpp +++ LiteEditor/mainbook.cpp -@@ -440,7 +440,7 @@ int MainBook::FindEditorIndexByFullPath(const wxString& fullpath) +@@ -433,14 +433,14 @@ void MainBook::GetAllEditors(clEditor::Vec_t& editors, size_t flags) + + int MainBook::FindEditorIndexByFullPath(const wxString& fullpath) + { +- wxString unixStyleFile(fullpath); ++ //wxString unixStyleFile(fullpath); + #ifdef __WXMSW__ +- unixStyleFile.Replace(wxT("\\"), wxT("/")); ++ //unixStyleFile.Replace(wxT("\\"), wxT("/")); + #endif #ifdef __WXGTK__ // On gtk either fileName or the editor filepath (or both) may be (or their paths contain) symlinks @@ -113,15 +122,33 @@ index 9798c7189..e457d8c2d 100644 fileName.MakeAbsolute(); #ifdef __WXMSW__ -@@ -1752,7 +1759,7 @@ WelcomePage* MainBook::GetOrCreateWelcomePage() +@@ -1751,7 +1758,7 @@ WelcomePage* MainBook::GetOrCreateWelcomePage() + clEditor* MainBook::OpenFileAsync(const wxString& file_name, std::function<void(IEditor*)>&& callback) { - wxString real_path = CLRealPath(file_name); -- auto editor = FindEditor(real_path); -+ auto editor = FindEditor(FileUtils::RealPath(real_path)); +- wxString real_path = CLRealPath(file_name); ++ wxString real_path = FileUtils::RealPath(file_name); + auto editor = FindEditor(real_path); if(editor) { push_callback(std::move(callback), real_path); - bool is_active = GetActiveEditor() == editor; +@@ -1762,7 +1769,7 @@ clEditor* MainBook::OpenFileAsync(const wxString& file_name, std::function<void( + m_book->SetSelection(index); + } + } else { +- editor = OpenFile(real_path); ++ editor = OpenFile(file_name); + if(editor) { + push_callback(std::move(callback), real_path); + } +@@ -1818,7 +1825,7 @@ void MainBook::OnIdle(wxIdleEvent& event) + auto editor = GetActiveEditor(false); + CHECK_PTR_RET(editor); + +- execute_callbacks_for_file(CLRealPath(editor->GetFileName().GetFullPath())); ++ execute_callbacks_for_file(FileUtils::RealPath(editor->GetFileName().GetFullPath())); + } + + void MainBook::OnEditorModified(clCommandEvent& event) diff --git Plugin/globals.cpp Plugin/globals.cpp index 68e87c0b1..2800d4b44 100644 --- Plugin/globals.cpp @@ -144,3 +171,26 @@ index 68e87c0b1..2800d4b44 100644 } int wxStringToInt(const wxString& str, int defval, int minval, int maxval) +diff --git Plugin/open_resource_dialog.cpp Plugin/open_resource_dialog.cpp +index 9432ae6ed..7e7763244 100644 +--- Plugin/open_resource_dialog.cpp ++++ Plugin/open_resource_dialog.cpp +@@ -335,8 +335,7 @@ void OpenResourceDialog::OnKeyDown(wxKeyEvent& event) + + if (event.GetKeyCode() == WXK_DOWN || event.GetKeyCode() == WXK_UP || + event.GetKeyCode() == WXK_NUMPAD_UP || event.GetKeyCode() == WXK_NUMPAD_DOWN || +- event.GetKeyCode() == WXK_PAGEUP || event.GetKeyCode() == WXK_PAGEDOWN || +- event.GetKeyCode() == WXK_HOME || event.GetKeyCode() == WXK_END) ++ event.GetKeyCode() == WXK_PAGEUP || event.GetKeyCode() == WXK_PAGEDOWN) + { + event.Skip(false); + +@@ -475,7 +474,7 @@ void OpenResourceDialog::GetLineAndColumnFromFilter(const wxString& filter, wxSt + tmpstr.Replace("\\", "/"); + + const size_t sep_last = tmpstr.Find('/', true); +- const size_t col_first = tmpstr.find(':', sep_last); ++ const size_t col_first = tmpstr.find(':', (sep_last == wxNOT_FOUND ? 0 : sep_last)); + if (col_first == wxNOT_FOUND) { + return; + } |