Debian Codegraph @

DatabaseExplorer/databaseexplorer.h

raw
1 //////////////////////////////////////////////////////////////////////////////
2 //////////////////////////////////////////////////////////////////////////////
3 //
4 // copyright : (C) 2014 Eran Ifrah
5 // file name : databaseexplorer.h
6 //
7 // -------------------------------------------------------------------------
8 // A
9 // _____ _ _ _ _
10 // / __ \ | | | | (_) |
11 // | / \/ ___ __| | ___| | _| |_ ___
12 // | | / _ \ / _ |/ _ \ | | | __/ _ )
13 // | \__/\ (_) | (_| | __/ |___| | || __/
14 // \____/\___/ \__,_|\___\_____/_|\__\___|
15 //
16 // F i l e
17 //
18 // This program is free software; you can redistribute it and/or modify
19 // it under the terms of the GNU General Public License as published by
20 // the Free Software Foundation; either version 2 of the License, or
21 // (at your option) any later version.
22 //
23 //////////////////////////////////////////////////////////////////////////////
24 //////////////////////////////////////////////////////////////////////////////
25
26 #ifndef __DatabaseExplorer__
27 #define __DatabaseExplorer__
28
29 #include "plugin.h"
30 #include "DbViewerPanel.h"
31 #include "cl_command_event.h"
32
33 class DatabaseExplorer : public IPlugin
34 {
35 public:
36 DatabaseExplorer(IManager* manager);
37 ~DatabaseExplorer();
38
39 //--------------------------------------------
40 // Abstract methods
41 //--------------------------------------------
42 virtual void CreateToolBar(clToolBarGeneric* toolbar);
43 virtual void CreatePluginMenu(wxMenu* pluginsMenu);
44 virtual void HookPopupMenu(wxMenu* menu, MenuType type);
45 virtual void UnPlug();
46
47 bool IsDbViewDetached();
48
49 static IManager* GetManager();
50 static DbViewerPanel* GetViewerPanel() { return m_dbViewerPanel; }
51
52 protected:
53 void OnAbout(wxCommandEvent& e);
54 void OnOpenWithDBE(clCommandEvent& e);
55 void DoOpenFile(const wxFileName& filename);
56 void OnUpdateOpenWithDBE(wxUpdateUIEvent& e);
57 void OnToggleTab(clCommandEvent& event);
58 void OnExecuteSQL(wxCommandEvent& event);
59 static DbViewerPanel* m_dbViewerPanel;
60 };
61
62 #endif // DatabaseExplorer