~ubuntu-branches/ubuntu/raring/codeblocks/raring-proposed

« back to all changes in this revision

Viewing changes to src/plugins/contrib/ThreadSearch/ThreadSearchLoggerList.h

  • Committer: Bazaar Package Importer
  • Author(s): Cosme Domínguez Díaz
  • Date: 2010-08-09 04:38:38 UTC
  • mfrom: (1.1.1 upstream)
  • mto: This revision was merged to the branch mainline in revision 4.
  • Revision ID: james.westby@ubuntu.com-20100809043838-a59ygguym4eg0jgw
Tags: 10.05-0ubuntu1
* New upstream release. Closes (LP: #322350)
 - Switch to dpkg-source 3.0 (quilt) format
 - Remove unneeded README.source
 - Add debian/get-source-orig script that removes all
   Windows prebuilt binaries
* Bump Standards-Version to 3.9.1
 - Stop shipping *.la files
* debian/control
 - Add cdbs package as Build-Depend
 - Add libbz2-dev and zlib1g-dev packages as
   Build-Depends (needed by libhelp_plugin.so)
 - Remove dpatch package of Build-Depends
 - Add codeblocks-contrib-debug package
 - Split architecture-independent files of codeblocks
   package in codeblocks-common package
* debian/rules
 - Switch to CDBS rules system
 - Add parallel build support
 - Add a call to debian/get-source-orig script
 - Use lzma compression (saves 23,5 MB of free space)
* debian/patches
 - Refresh 01_codeblocks_plugin_path
 - Add 02_no_Makefiles_in_debian_dir to remove any link
   in codeblocks build system to deleted Makefiles of debian directory
 - Drop 02_ftbfs_gcc44 and 03_ftbfs_glib221 (merged in upstream)
* debian/watch
 - Update to use the new host (berlios.de)

Show diffs side-by-side

added added

removed removed

Lines of Context:
28
28
class ThreadSearchLoggerList : public wxEvtHandler, public ThreadSearchLoggerBase
29
29
{
30
30
public:
31
 
        /** Constructor. */
32
 
        ThreadSearchLoggerList(ThreadSearchView& threadSearchView, ThreadSearch& threadSearchPlugin,
33
 
                                                        InsertIndexManager::eFileSorting fileSorting, wxPanel* pParent, long id);
 
31
    /** Constructor. */
 
32
    ThreadSearchLoggerList(ThreadSearchView& threadSearchView, ThreadSearch& threadSearchPlugin,
 
33
                            InsertIndexManager::eFileSorting fileSorting, wxPanel* pParent, long id);
34
34
 
35
 
        /** Destructor. */
36
 
        virtual ~ThreadSearchLoggerList();
37
 
 
38
 
        /** Getter */
39
 
        virtual eLoggerTypes GetLoggerType() {return TypeList;}
40
 
 
41
 
        /** Called by ThreadSearchView when new settings are applied. */
42
 
        virtual void Update();
43
 
 
44
 
        /** Called by ThreadSearchView to process a ThreadSearchEvent
45
 
          * sent by worker thread.
46
 
          */
47
 
        virtual void OnThreadSearchEvent(const ThreadSearchEvent& event);
48
 
 
49
 
        /** Removes all items from logger. */
50
 
        virtual void Clear();
51
 
 
52
 
        /** Returns the logger window. */
53
 
        virtual wxWindow* GetWindow();
54
 
 
55
 
        /** Sets focus on list window. */
56
 
        virtual void SetFocus();
57
 
 
58
 
        /** Single click event handler */
59
 
        void OnLoggerListClick(wxListEvent& event);
60
 
 
61
 
        /** Double click event handler */
62
 
        void OnLoggerListDoubleClick(wxListEvent& event);
 
35
    /** Destructor. */
 
36
    virtual ~ThreadSearchLoggerList();
 
37
 
 
38
    /** Getter */
 
39
    virtual eLoggerTypes GetLoggerType() {return TypeList;}
 
40
 
 
41
    /** Called by ThreadSearchView when new settings are applied. */
 
42
    virtual void Update();
 
43
 
 
44
    /** Called by ThreadSearchView to process a ThreadSearchEvent
 
45
      * sent by worker thread.
 
46
      */
 
47
    virtual void OnThreadSearchEvent(const ThreadSearchEvent& event);
 
48
 
 
49
    /** Removes all items from logger. */
 
50
    virtual void Clear();
 
51
 
 
52
    /** Called on search begin to prepare logger. */
 
53
    virtual void OnSearchBegin(const ThreadSearchFindData& findData);
 
54
 
 
55
    /** Returns the logger window. */
 
56
    virtual wxWindow* GetWindow();
 
57
 
 
58
    /** Sets focus on list window. */
 
59
    virtual void SetFocus();
 
60
 
 
61
    /** Single click event handler */
 
62
    void OnLoggerListClick(wxListEvent& event);
 
63
 
 
64
    /** Double click event handler */
 
65
    void OnLoggerListDoubleClick(wxListEvent& event);
63
66
 
64
67
protected:
65
 
        /** SetListColumns
66
 
          * The SimpleListLog constructor does not set the provided columns on Linux.
67
 
          * It is necessary to set columns after the ThreadSearchLoggerList constructor.
68
 
          */
69
 
        void SetListColumns();
70
 
 
71
 
        /** GetFileLineFromListEvent
72
 
          * Return the file path at index from the list control using dir and file columns.
73
 
          * @param event    : list control event
74
 
          * @param filepath : reference that will receive the path
75
 
          * @param line     : reference that will receive the line index
76
 
          * @return true if successful.
77
 
          */
78
 
        bool GetFileLineFromListEvent(wxListEvent& event, wxString& filepath, long &line);
79
 
 
80
 
        /** Dynamic events connection. */
81
 
        virtual void ConnectEvents(wxEvtHandler* pEvtHandler);
82
 
 
83
 
        /** Dynamic events disconnection. */
84
 
        virtual void DisconnectEvents(wxEvtHandler* pEvtHandler);
85
 
 
86
 
        wxListCtrl* m_pListLog;
 
68
    /** SetListColumns
 
69
      * The SimpleListLog constructor does not set the provided columns on Linux.
 
70
      * It is necessary to set columns after the ThreadSearchLoggerList constructor.
 
71
      */
 
72
    void SetListColumns();
 
73
 
 
74
    /** GetFileLineFromListEvent
 
75
      * Return the file path at index from the list control using dir and file columns.
 
76
      * @param event    : list control event
 
77
      * @param filepath : reference that will receive the path
 
78
      * @param line     : reference that will receive the line index
 
79
      * @return true if successful.
 
80
      */
 
81
    bool GetFileLineFromListEvent(wxListEvent& event, wxString& filepath, long &line);
 
82
 
 
83
    /** IsLineResultLine
 
84
      * Return true if line is a result line. It is not the case for the
 
85
      * first line of a new search without deleting previous results.
 
86
      * @param index : item index in list control. If -1 is given (default
 
87
      * value), first selected line will be processed.
 
88
      * @return true if line is usable.
 
89
      */
 
90
    bool IsLineResultLine(long index = -1);
 
91
 
 
92
    /** Dynamic events connection. */
 
93
    virtual void ConnectEvents(wxEvtHandler* pEvtHandler);
 
94
 
 
95
    /** Dynamic events disconnection. */
 
96
    virtual void DisconnectEvents(wxEvtHandler* pEvtHandler);
 
97
 
 
98
    /** Contextual menu event handler */
 
99
    void OnLoggerListContextualMenu(wxContextMenuEvent& event);
 
100
 
 
101
    /** Delete item menu event handler */
 
102
    void OnDeleteListItem(wxCommandEvent& event);
 
103
 
 
104
    /** Delete item menu event handler */
 
105
    void OnDeleteAllListItems(wxCommandEvent& event);
 
106
 
 
107
    /** Deletes an item from the List */
 
108
    void DeleteListItem(long index);
 
109
 
 
110
    /** Deletes all items from the List */
 
111
    void DeleteListItems();
 
112
 
 
113
    wxListCtrl* m_pListLog;
 
114
    long        m_IndexOffset;
87
115
};
88
116
 
89
117
#endif // THREAD_SEARCH_LOGGER_LIST_H