~ubuntu-branches/debian/sid/kdevelop/sid

« back to all changes in this revision

Viewing changes to parts/filelist/filelist_item.h

  • Committer: Bazaar Package Importer
  • Author(s): Jeremy Lainé
  • Date: 2006-05-23 18:39:42 UTC
  • Revision ID: james.westby@ubuntu.com-20060523183942-hucifbvh68k2bwz7
Tags: upstream-3.3.2
Import upstream version 3.3.2

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/***************************************************************************
 
2
 *   Copyright (C) 2004 by Jens Dagerbo                                    *
 
3
 *   jens.dagerbo@swipnet.se                                               *
 
4
 *                                                                         *
 
5
 *   This program is free software; you can redistribute it and/or modify  *
 
6
 *   it under the terms of the GNU General Public License as published by  *
 
7
 *   the Free Software Foundation; either version 2 of the License, or     *
 
8
 *   (at your option) any later version.                                   *
 
9
 *                                                                         *
 
10
 ***************************************************************************/
 
11
 
 
12
#ifndef __FILELIST_ITEM_H__
 
13
#define __FILELIST_ITEM_H__
 
14
 
 
15
 
 
16
#include <qlistview.h>
 
17
#include <qpixmap.h>
 
18
 
 
19
#include <kurl.h>
 
20
 
 
21
#include <kdevpartcontroller.h>
 
22
                 
 
23
class FileListItem : public QListViewItem
 
24
{
 
25
public:
 
26
        FileListItem( QListView * parent, KURL const & url, DocumentState = Clean );
 
27
        
 
28
        KURL url();
 
29
        
 
30
        DocumentState state();
 
31
        void setState( DocumentState );
 
32
        
 
33
        bool isActive();
 
34
        static void setActive( FileListItem * item );
 
35
        
 
36
private:
 
37
        virtual void setHeight( int );  // override of QListViewItem::setHeight()
 
38
    virtual void paintCell( QPainter * p, const QColorGroup & cg, int column, int width, int align );   // override of QListViewItem::paintCell()
 
39
        
 
40
        KURL _url;
 
41
        DocumentState _state;
 
42
    QPixmap _icon;
 
43
    
 
44
        static FileListItem * s_activeItem;
 
45
        
 
46
};
 
47
 
 
48
 
 
49
 
 
50
#endif
 
51
 
 
52
// kate: space-indent off; indent-width 4; tab-width 4; show-tabs off;