|
8 | 8 |
|
9 | 9 | #include "interface_derived.hpp" |
10 | 10 | #include <fstream> |
11 | | -#include <wx/msgdlg.h> |
12 | 11 | #include <wx/dirdlg.h> |
13 | 12 | #include <wx/aboutdlg.h> |
14 | 13 | #if defined _WIN32 |
@@ -45,13 +44,17 @@ EVT_BUTTON(OPEN_WITH, MainFrameDerived::OnOpenWith) |
45 | 44 | EVT_LIST_ITEM_ACTIVATED(wxID_HARDDISK, MainFrameDerived::OnOpenProject) |
46 | 45 | EVT_LISTBOX_DCLICK(wxID_FLOPPY,MainFrameDerived::OnRevealEditor) |
47 | 46 | EVT_LISTBOX_DCLICK(wxID_HOME,MainFrameDerived::OnRevealInstallLocation) |
| 47 | + |
| 48 | +#if defined __APPLE__ || defined _WIN32 |
48 | 49 | EVT_NOTEBOOK_PAGE_CHANGED(NOTEBOOK, MainFrameDerived::OnPageChanging) |
49 | 50 | EVT_BUTTON(Nav_Back, MainFrameDerived::OnNavigateBack) |
50 | 51 | EVT_BUTTON(Nav_Forward, MainFrameDerived::OnNavigateForwards) |
51 | 52 | EVT_BUTTON(Nav_Home, MainFrameDerived::OnNavigateHome) |
52 | 53 | EVT_WEBVIEW_NAVIGATED(WEBVIEW,MainFrameDerived::OnNavigationComplete) |
53 | 54 | EVT_WEBVIEW_NEWWINDOW(WEBVIEW, MainFrameDerived::OnNavigationNewWindow) |
54 | 55 | EVT_TIMER(TIMER, MainFrameDerived::OnTimerExpire) |
| 56 | +#endif |
| 57 | + |
55 | 58 | wxEND_EVENT_TABLE() |
56 | 59 |
|
57 | 60 | //call superclass constructor |
@@ -81,8 +84,9 @@ MainFrameDerived::MainFrameDerived() : MainFrame(NULL){ |
81 | 84 | } |
82 | 85 | //if no projects to load, the interface will be blank |
83 | 86 |
|
84 | | - timeout = new wxTimer(this,TIMER); |
85 | | - |
| 87 | + #if defined __APPLE || defined _WIN32 |
| 88 | + timeout = new wxTimer(this,TIMER); |
| 89 | + #endif |
86 | 90 | //show current version in titlebar |
87 | 91 | this->SetLabel("Unity Hub Native " + AppVersion); |
88 | 92 | } |
@@ -189,6 +193,7 @@ void MainFrameDerived::OnAddProject(wxCommandEvent& event){ |
189 | 193 | } |
190 | 194 | } |
191 | 195 |
|
| 196 | +#if defined __APPLE__ || defined _WIN32 |
192 | 197 | /** |
193 | 198 | Called when the top segmented control switches pages |
194 | 199 | @param event the wxBookCtrlEvent sent by the segmented control. Used to get the currently selected page |
@@ -219,7 +224,7 @@ void MainFrameDerived::OnPageChanging(wxBookCtrlEvent& event){ |
219 | 224 | } |
220 | 225 | } |
221 | 226 | } |
222 | | - |
| 227 | +#endif |
223 | 228 | /** |
224 | 229 | Loads an editor search path into the app, updating the UI and the vector |
225 | 230 | @param path the string path to laod |
|
0 commit comments