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

« back to all changes in this revision

Viewing changes to src/plugins/contrib/codesnippets/Search/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:
 
1
/***************************************************************
 
2
 * Name:      ThreadSearchLoggerList
 
3
 * Purpose:   ThreadSearchLoggerList implements the
 
4
 *            ThreadSearchLoggerBase with a wxListCtrl.
 
5
 * Author:    Jerome ANTOINE
 
6
 * Created:   2007-07-28
 
7
 * Copyright: Jerome ANTOINE
 
8
 * License:   GPL
 
9
 **************************************************************/
 
10
 
 
11
#ifndef THREAD_SEARCH_LOGGER_LIST_H
 
12
#define THREAD_SEARCH_LOGGER_LIST_H
 
13
 
 
14
#include <wx/event.h>
 
15
 
 
16
#include "ThreadSearchLoggerBase.h"
 
17
 
 
18
class wxPanel;
 
19
class wxWindow;
 
20
class wxListEvent;
 
21
class wxListCtrl;
 
22
class wxString;
 
23
 
 
24
class ThreadSearch;
 
25
class ThreadSearchView;
 
26
class ThreadSearchEvent;
 
27
 
 
28
class ThreadSearchLoggerList : public wxEvtHandler, public ThreadSearchLoggerBase
 
29
{
 
30
public:
 
31
        /** Constructor. */
 
32
        ThreadSearchLoggerList(ThreadSearchView& threadSearchView, ThreadSearch& threadSearchPlugin,
 
33
                                                        InsertIndexManager::eFileSorting fileSorting, wxPanel* pParent, long id);
 
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);
 
63
 
 
64
    void SyncLoggerToPreview();
 
65
 
 
66
 
 
67
protected:
 
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
        /** Dynamic events connection. */
 
84
        virtual void ConnectEvents(wxEvtHandler* pEvtHandler);
 
85
 
 
86
        /** Dynamic events disconnection. */
 
87
        virtual void DisconnectEvents(wxEvtHandler* pEvtHandler);
 
88
 
 
89
    void OnMouseWheelEvent(wxMouseEvent& event);
 
90
 
 
91
        wxListCtrl* m_pListLog;
 
92
        long m_LastLeftMouseClickIndex;
 
93
};
 
94
 
 
95
#endif // THREAD_SEARCH_LOGGER_LIST_H