1 #ifndef __BF_GUI_FILESPANEL_H__
2 #define __BF_GUI_FILESPANEL_H__
3
4 #include "BF_GUI_NodePanel.h"
5 #include "BF_GUI_OperRoster.h"
6
7
8
9 class BF_GUI_FilesPanel:public BF_GUI_NodePanel{
10 public:
11 BF_GUI_FilesPanel(const BRect & o_Rect,bool b_WinPos_OnLeft);
12
13 virtual void AttachedToWindow(void);
14 void Pub_GoPath(const char *pc_Path);
15
16
17 private:
18 BF_FilesPath oPath;
19 BL_List lsPathHistory;
20 thread_id idThreadLoading;
21 int32 iThreadLoading_Count,iThreadLoading_Index;
22 BL_String sThreadLoading_FutureFocus;
23 uint32 iTempDelType;
24
25
26
27 void NavGoParentDir();
28 virtual bool NavChangeCursor(int i_NewCursor,bool b_DrawNodes=true,bool b_ChangeVars=true);
29 void NavGoPath(const BF_Path & o_NewPath,
30 BString *ps_FocusItem=NULL,
31 bool b_LoadNodes=true,
32 bool b_AddToHistory=true);
33
34 virtual void Action_SwitchShowIcons();
35 virtual bool NavEnter();
36
37 virtual bool OnClose();
38 virtual bool OnKeyDown(const char *bytes, int32 numBytes);
39
40 virtual void PrepareKeysMenu();
41 virtual void PrepareCmdLine();
42 virtual void PrepareTopMenuItem(BF_GUI_TopMenu_HItem *po_HItem);
43 virtual void PrepareHotKeys(bool b_Focused);
44
45 virtual const BL_String Path() const;
46
47 virtual void MessageReceived(BMessage* po_Message);
48
49 virtual void DrawListInfo(bool b_DrawBack);
50
51 virtual void ActionDelete_Run(BF_NodeCollection & lo_Node);
52 virtual void ActionCopyTo_Run(BL_String & s_Path,BF_NodeCollection & lo_Node);
53 virtual void ActionMoveTo_Run(BL_String & s_Path,BF_NodeCollection & lo_Node);
54 virtual void ActionMakeDir_Run(BL_String & s_Title);
55 virtual void ActionRename_Run(BF_NodeCollection & lo_Node,BL_String & s_NewName);
56
57 virtual void Nodes_Add(BF_Node *po_Node,BF_NodeCollection *plo_Node);
58 virtual void Nodes_Remove(BF_Node *po_Node,BF_NodeCollection *plo_Node);
59
60 virtual void Action_CopyToBuffer();
61 virtual void Action_PasteFromBuffer();
62 virtual void Action_PasteFromBuffer_Step2(BMessage *po_Message);
63
64
65 void Action_Search_0();
66 void Action_Search_1(BMessage* po_Message);
67 void Action_CopyMoveTo_Run(BL_String & s_Path,BF_NodeCollection & lo_Node,bool b_Move);
68
69 void Action_ChangeCase_0();
70 void Action_ChangeCase_1(BMessage *po_Message);
71
72 void Action_MakeLinks_StartDialog();
73 void Action_MakeLinks_StartTask(BMessage *po_Message);
74
75 void Action_GoPath_StartDialog();
76 void Action_GoPath_Run(BMessage *po_Message);
77
78 void Action_Run_File(BF_Node *po_Node);
79 void Action_Edit_File(BF_Node *po_Node=NULL);
80
81 void Action_TextViewer_Start();
82
83 void Action_Tracker_Addons_Start();
84 void Action_Tracker_Addons_Start_LoadAddOns(bool b_FromHome,BL_List &lo_MenuResult,bool b_LoadSIcons);
85 void Action_Tracker_Addons_Run(const char *pc_AddOn);
86
87 void Action_MakeSH_Dialog();
88 void Action_MakeSH_Run(BMessage *po_Message);
89
90 void Load_Files(bool b_AlwaysLoadSIcons=false);
91
92 void PathHistory_Add(BF_Path * po_Path);
93 void PathHistory_GoBack();
94
95 int32 LoadStyles();
96
97 void HandlingMonitor(BMessage &o_Message);
98 void HandlingMonitor_Removed(BMessage &o_Message,node_ref & u_Ref);
99 void HandlingMonitor_Moved(BMessage &o_Message,node_ref & u_Ref);
100 void HandlingMonitor_Created(BMessage &o_Message,node_ref & u_Ref);
101 void HandlingMonitor_Changed(BMessage &o_Message,node_ref & u_Ref);
102
103
104 void SayFriend_About_CursorChanged_Ext();
105
106
107 friend int32 BF_GUI_FilesPanel_LoadFiles_Thread(void *data);
108 };
109
110