Skip to content

Commit e36b583

Browse files
sowicmsowicm
authored andcommitted
Merge commit 'fab6feec70b5a871469f8e808b8aa58dd93f1525'
Conflicts: CMakeLists.txt LiteEditor/webupdatethread.cpp Runtime/rc/menu.xrc
2 parents e0f3cab + fab6fee commit e36b583

16 files changed

+149
-69
lines changed

CMakeLists.txt

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -37,12 +37,8 @@ project( "Sowicm's Codepad" )
3737

3838
## Generate compile_commands.json file for code completion
3939
set( CMAKE_EXPORT_COMPILE_COMMANDS 1 )
40-
41-
if( UNIX AND NOT APPLE)
42-
set( CMAKE_LIBRARY_ARCHITECTURE x86_64-linux-gnu ) # add search path needed by (at least) libssh and gtk2 libraries
43-
endif()
44-
4540
set( CL_PREFIX "/usr" )
41+
4642
if (CMAKE_CURRENT_LIST_DIR) # since cmake 2.8.3
4743
set( CL_SRC_ROOT ${CMAKE_CURRENT_LIST_DIR})
4844
else()

InnoSetup/codelite64_mingw.iss

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,15 @@
55
AppName=CodeLite
66
AppVerName=CodeLite
77
AppPublisher=Eran Ifrah
8-
AppVersion=9.1.0
8+
AppVersion=9.1.1
99
AppPublisherURL=http://codelite.org
1010
AppSupportURL=http://codelite.org
1111
AppUpdatesURL=http://codelite.org
1212
DefaultDirName={pf64}\CodeLite
1313
DefaultGroupName=CodeLite
1414
LicenseFile=license.txt
1515
OutputDir=output
16-
OutputBaseFilename=codelite-amd64-9.1.0
16+
OutputBaseFilename=codelite-amd64-9.1.1
1717
ChangesEnvironment=yes
1818
FlatComponentsList=yes
1919
SetupIconFile=box_software.ico

InnoSetup/codelite_mingw.iss

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,15 @@
55
AppName=CodeLite
66
AppVerName=CodeLite
77
AppPublisher=Eran Ifrah
8-
AppVersion=9.1.0
8+
AppVersion=9.1.1
99
AppPublisherURL=http://codelite.org
1010
AppSupportURL=http://codelite.org
1111
AppUpdatesURL=http://codelite.org
1212
DefaultDirName={pf}\CodeLite
1313
DefaultGroupName=CodeLite
1414
LicenseFile=license.txt
1515
OutputDir=output
16-
OutputBaseFilename=codelite-x86-9.1.0
16+
OutputBaseFilename=codelite-x86-9.1.1
1717
ChangesEnvironment=yes
1818
FlatComponentsList=yes
1919
SetupIconFile=box_software.ico

LiteEditor.workspace

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@
9393
<Project Name="wxsqlite3" ConfigName="Win_x86_Release"/>
9494
<Project Name="ZoomNavigator" ConfigName="Win_x86_Release"/>
9595
</WorkspaceConfiguration>
96-
<WorkspaceConfiguration Name="CMake_Release" Selected="no">
96+
<WorkspaceConfiguration Name="CMake_Release" Selected="yes">
9797
<Environment/>
9898
<Project Name="ZoomNavigator" ConfigName="DebugUnicode"/>
9999
<Project Name="wxsqlite3" ConfigName="Win_x86_Release"/>
@@ -265,7 +265,7 @@
265265
<Project Name="WebTools" ConfigName="DebugUnicode"/>
266266
<Project Name="HelpPlugin" ConfigName="Win_x64_Debug"/>
267267
</WorkspaceConfiguration>
268-
<WorkspaceConfiguration Name="Win_x64_Release" Selected="yes">
268+
<WorkspaceConfiguration Name="Win_x64_Release" Selected="no">
269269
<Environment/>
270270
<Project Name="abbreviation" ConfigName="Win_x64_Release"/>
271271
<Project Name="CallGraph" ConfigName="Win_x64_Release"/>

LiteEditor/CMakeLists.txt

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -198,7 +198,13 @@ if(NOT APPLE)
198198
if (${WX_LIBSOUTPUT} MATCHES "^-L.+") # In recent, multi-architecture, distro versions it'll start with -L/foo/bar
199199
string(REGEX REPLACE "^-L([^ ;]+).*" "\\1" WX_LIBS_DIR ${WX_LIBSOUTPUT})
200200
else()
201-
set(WX_LIBS_DIR "/usr/lib") # ${WX_LIBS_DIR} will be empty for older, non multi-architecture, distro versions that still use /usr/lib
201+
# In recent fedoras, which do things with wx-config that might politely be described as 'strange, wx-config doesn't emit -L/usr/lib64
202+
find_file( USRLIBSIXTYFOUR "libwx_baseu-3.1.so" "/usr/lib64" )
203+
if ( NOT USRLIBSIXTYFOUR MATCHES ".*NOTFOUND" )
204+
set(WX_LIBS_DIR "/usr/lib64")
205+
else()
206+
set(WX_LIBS_DIR "/usr/lib") # ${WX_LIBS_DIR} will be empty for older, non multi-architecture, distro versions that still use /usr/lib
207+
endif()
202208
endif()
203209
message("-- wxlibsdir is: ${WX_LIBS_DIR}")
204210

@@ -210,9 +216,9 @@ if(NOT APPLE)
210216
# We want to replace -l with lib. We also want to exclude imaginary libs called _all.so, which buggy wx-config scripts can invent
211217
if (${ITEM} MATCHES "-lwx_.+" AND NOT ${ITEM} MATCHES "-l.+_all.+")
212218
string(REGEX REPLACE "^-l" "lib" LIBITEM ${ITEM})
213-
# openSUSE have started to use libwx_gtk2u_xrc-suse.so instead of libwx_gtk2u_xrc-3.1, so chop off the end
214-
string(REGEX REPLACE "-.+" "-" LIBITEMCUT ${LIBITEM})
215-
list(APPEND WX_LIBS_ALL ${WX_LIBS_DIR}/${LIBITEMCUT}*.so*) # we need the terminal [.]so because the rpms contain both dynamic and static libs
219+
# openSUSE have started to use libwx_gtk2u_xrc-suse.so instead of libwx_gtk2u_xrc-3.1, so allow for extra text there
220+
string(REGEX REPLACE "(libwx_[a-z0-9_]+-)(.+)" "\\1*\\2" LIBITEMADJ ${LIBITEM})
221+
list(APPEND WX_LIBS_ALL ${WX_LIBS_DIR}/${LIBITEMADJ}*.so*) # we need the terminal [.]so because the rpms contain both dynamic and static libs
216222
endif()
217223
endforeach()
218224

LiteEditor/autoversion.h

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,6 @@
2626
#ifndef CODELITE_AUTOVERSION_H
2727
#define CODELITE_AUTOVERSION_H
2828

29-
#define CODELITE_VERSION_STRING "9.1.0"
30-
#define CODELITE_VERSION_NUMBER 909
29+
#define CODELITE_VERSION_STRING "9.1.1"
3130

3231
#endif

LiteEditor/context_cpp.cpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2664,12 +2664,14 @@ int ContextCpp::GetHyperlinkRange(int pos, int& start, int& end)
26642664

26652665
void ContextCpp::GoHyperlink(int start, int end, int type, bool alt)
26662666
{
2667+
(void) alt;
2668+
26672669
if(type == XRCID("open_include_file")) {
26682670
m_selectedWord = GetCtrl().GetTextRange(start, end);
26692671
DoOpenWorkspaceFile();
26702672
} else {
26712673
if(type == XRCID("find_tag")) {
2672-
wxCommandEvent e(wxEVT_COMMAND_MENU_SELECTED, alt ? XRCID("find_impl") : XRCID("find_decl"));
2674+
wxCommandEvent e(wxEVT_COMMAND_MENU_SELECTED, XRCID("find_impl"));
26732675
clMainFrame::Get()->GetEventHandler()->AddPendingEvent(e);
26742676
}
26752677
}

LiteEditor/frame.cpp

Lines changed: 63 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -187,8 +187,8 @@ EVT_IDLE(clMainFrame::OnIdle)
187187
EVT_ACTIVATE(clMainFrame::OnAppActivated)
188188
EVT_CLOSE(clMainFrame::OnClose)
189189
EVT_TIMER(FrameTimerId, clMainFrame::OnTimer)
190-
// EVT_AUI_RENDER(Frame::OnAuiManagerRender)
191-
// EVT_AUI_PANE_CLOSE(Frame::OnDockablePaneClosed)
190+
// EVT_AUI_RENDER(Frame::OnAuiManagerRender)
191+
// EVT_AUI_PANE_CLOSE(Frame::OnDockablePaneClosed)
192192

193193
//---------------------------------------------------
194194
// File menu
@@ -293,6 +293,8 @@ EVT_MENU(XRCID("whitepsace_invisible"), clMainFrame::OnShowWhitespace)
293293
EVT_MENU(XRCID("whitepsace_always"), clMainFrame::OnShowWhitespace)
294294
EVT_MENU(XRCID("whitespace_visiable_after_indent"), clMainFrame::OnShowWhitespace)
295295
EVT_MENU(XRCID("whitespace_indent_only"), clMainFrame::OnShowWhitespace)
296+
EVT_MENU(XRCID("next_tab"), clMainFrame::OnNextTab)
297+
EVT_MENU(XRCID("prev_tab"), clMainFrame::OnPrevTab)
296298
EVT_MENU(XRCID("full_screen"), clMainFrame::OnShowFullScreen)
297299
EVT_MENU(XRCID("view_welcome_page"), clMainFrame::OnShowWelcomePage)
298300
EVT_MENU(XRCID("view_welcome_page_at_startup"), clMainFrame::OnLoadWelcomePage)
@@ -314,6 +316,8 @@ EVT_UPDATE_UI(XRCID("fold_all"), clMainFrame::OnFileExistUpdateUI)
314316
EVT_UPDATE_UI(XRCID("fold_all_in_selection"), clMainFrame::DispatchUpdateUIEvent)
315317
EVT_UPDATE_UI(XRCID("fold_topmost_in_selection"), clMainFrame::DispatchUpdateUIEvent)
316318
EVT_UPDATE_UI(XRCID("display_eol"), clMainFrame::OnViewDisplayEOL_UI)
319+
EVT_UPDATE_UI(XRCID("next_tab"), clMainFrame::OnNextPrevTab_UI)
320+
EVT_UPDATE_UI(XRCID("prev_tab"), clMainFrame::OnNextPrevTab_UI)
317321
EVT_UPDATE_UI(XRCID("whitepsace_invisible"), clMainFrame::OnShowWhitespaceUI)
318322
EVT_UPDATE_UI(XRCID("whitepsace_always"), clMainFrame::OnShowWhitespaceUI)
319323
EVT_UPDATE_UI(XRCID("whitespace_visiable_after_indent"), clMainFrame::OnShowWhitespaceUI)
@@ -778,6 +782,18 @@ clMainFrame::clMainFrame(
778782
"selection_to_multi_caret", "Ctrl-Shift-L", _("Edit::Split selection into multiple carets"));
779783
clKeyboardManager::Get()->AddGlobalAccelerator(
780784
"incremental_replace", "", _("Search::Toggle the Quick-Replace Bar"));
785+
clKeyboardManager::Get()->AddGlobalAccelerator(
786+
"copy_file_relative_path_to_workspace", "Ctrl-Alt-Shift-C", "Edit::Copy Path Relative to Clipboard");
787+
clKeyboardManager::Get()->AddGlobalAccelerator(
788+
"copy_file_name", "", "Edit::Copy Path to Clipboard");
789+
clKeyboardManager::Get()->AddGlobalAccelerator(
790+
"copy_file_path", "", "Edit::Copy Full Path to Clipboard");
791+
clKeyboardManager::Get()->AddGlobalAccelerator(
792+
"copy_file_name_only", "", "Edit::Copy File Name to Clipboard");
793+
clKeyboardManager::Get()->AddGlobalAccelerator(
794+
"open_shell_from_filepath", "Ctrl-Shift-T", "Search::Open Shell From File Path");
795+
clKeyboardManager::Get()->AddGlobalAccelerator(
796+
"open_file_explorer", "Ctrl-Alt-Shift-T", "Search::Open Containing Folder");
781797
}
782798

783799
clMainFrame::~clMainFrame(void)
@@ -3301,7 +3317,7 @@ void clMainFrame::CreateWelcomePage()
33013317
content.Replace(wxT("$(FilesTable)"), filesTable);
33023318
33033319
//replace the HTML colours with platfroms correct colours
3304-
wxColour active_caption = wxSystemSettings::GetColour(wxSYS_COLOUR_ACTIVECAPTION);
3320+
wxColour active_caption = wxSystemSettings::GetColour(wxSYS_COLOUR_ACTIVECAPTION);
33053321
wxColour active_caption_txt = wxSystemSettings::GetColour(wxSYS_COLOUR_WINDOWTEXT);
33063322
33073323
active_caption = DrawingUtils::LightColour(active_caption, 11.0);
@@ -4625,6 +4641,50 @@ void clMainFrame::OnShowWhitespace(wxCommandEvent& e)
46254641
EditorConfigST::Get()->SetOptions(options);
46264642
}
46274643

4644+
void clMainFrame::OnNextTab(wxCommandEvent& e)
4645+
{
4646+
int idx = GetMainBook()->GetCurrentPageIndex();
4647+
4648+
if (idx != wxNOT_FOUND) {
4649+
clTab::Vec_t tabs;
4650+
GetMainBook()->GetAllTabs(tabs);
4651+
4652+
idx = (idx + 1) % tabs.size();
4653+
GetMainBook()->SelectPage(GetMainBook()->GetPage(idx));
4654+
}
4655+
}
4656+
4657+
void clMainFrame::OnPrevTab(wxCommandEvent& e)
4658+
{
4659+
int idx = GetMainBook()->GetCurrentPageIndex();
4660+
4661+
if (idx != wxNOT_FOUND) {
4662+
idx--;
4663+
4664+
if (idx < 0) {
4665+
clTab::Vec_t tabs;
4666+
GetMainBook()->GetAllTabs(tabs);
4667+
4668+
idx = tabs.size() - 1;
4669+
}
4670+
4671+
GetMainBook()->SelectPage(GetMainBook()->GetPage(idx));
4672+
}
4673+
}
4674+
4675+
void clMainFrame::OnNextPrevTab_UI(wxUpdateUIEvent& e)
4676+
{
4677+
CHECK_SHUTDOWN();
4678+
LEditor* editor = GetMainBook()->GetActiveEditor();
4679+
bool hasEditor = editor ? true : false;
4680+
if(!hasEditor) {
4681+
e.Enable(false);
4682+
return;
4683+
}
4684+
4685+
e.Enable(true);
4686+
}
4687+
46284688
void clMainFrame::OnIncrementalSearch(wxCommandEvent& event)
46294689
{
46304690
wxUnusedVar(event);

LiteEditor/frame.h

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ class clMainFrame : public wxFrame
131131
void DoCreateBuildDropDownMenu(wxMenu* menu);
132132
void DoShowToolbars(bool show);
133133
void InitializeLogo();
134-
134+
135135
public:
136136
static clMainFrame* Get();
137137
static void Initialize(bool loadLastSession);
@@ -559,6 +559,9 @@ class clMainFrame : public wxFrame
559559
void OnSyntaxHighlight(wxCommandEvent& e);
560560
void OnShowWhitespaceUI(wxUpdateUIEvent& e);
561561
void OnShowWhitespace(wxCommandEvent& e);
562+
void OnNextTab(wxCommandEvent& e);
563+
void OnPrevTab(wxCommandEvent& e);
564+
void OnNextPrevTab_UI(wxUpdateUIEvent& e);
562565
void OnShowFullScreen(wxCommandEvent& e);
563566
void OnFindResourceXXX(wxCommandEvent& e);
564567
void OnShowActiveProjectSettings(wxCommandEvent& e);
@@ -584,6 +587,7 @@ class clMainFrame : public wxFrame
584587
void OnSettingsChanged(wxCommandEvent& e);
585588
void OnEditMenuOpened(wxMenuEvent& e);
586589
void OnProjectRenamed(clCommandEvent& event);
590+
587591
DECLARE_EVENT_TABLE()
588592
};
589593

LiteEditor/mainbook.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1213,6 +1213,7 @@ void MainBook::DoUpdateNotebookTheme()
12131213
}
12141214

12151215
wxWindow* MainBook::GetCurrentPage() { return m_book->GetCurrentPage(); }
1216+
int MainBook::GetCurrentPageIndex() { return m_book->GetSelection(); }
12161217

12171218
void MainBook::OnClosePage(wxBookCtrlEvent& e)
12181219
{

0 commit comments

Comments
 (0)