~ubuntu-branches/ubuntu/trusty/qgis/trusty

« back to all changes in this revision

Viewing changes to src/gui/qgsdetaileditemdata.cpp

  • Committer: Bazaar Package Importer
  • Author(s): Johan Van de Wauw
  • Date: 2010-07-11 20:23:24 UTC
  • mfrom: (3.1.4 squeeze)
  • Revision ID: james.westby@ubuntu.com-20100711202324-5ktghxa7hracohmr
Tags: 1.4.0+12730-3ubuntu1
* Merge from Debian unstable (LP: #540941).
* Fix compilation issues with QT 4.7
* Add build-depends on libqt4-webkit-dev 

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/***************************************************************************
 
2
     qgsdetailedlistdata.cpp  -  A data represenation for a rich QItemData subclass
 
3
                             -------------------
 
4
    begin                : Sat May 17 2008
 
5
    copyright            : (C) 2008 Tim Sutton
 
6
    email                : tim@linfiniti.com
 
7
 ***************************************************************************/
 
8
 
 
9
/***************************************************************************
 
10
 *                                                                         *
 
11
 *   This program is free software; you can redistribute it and/or modify  *
 
12
 *   it under the terms of the GNU General Public License as published by  *
 
13
 *   the Free Software Foundation; either version 2 of the License, or     *
 
14
 *   (at your option) any later version.                                   *
 
15
 *                                                                         *
 
16
 ***************************************************************************/
 
17
/* $Id:$ */
 
18
 
 
19
#include "qgsdetaileditemdata.h"
 
20
QgsDetailedItemData::QgsDetailedItemData()
 
21
{
 
22
  mRenderAsWidgetFlag = false;
 
23
  mEnabledFlag = true;
 
24
}
 
25
 
 
26
QgsDetailedItemData::~QgsDetailedItemData()
 
27
{
 
28
}
 
29
 
 
30
void QgsDetailedItemData::setTitle( const QString theTitle )
 
31
{
 
32
  mTitle = theTitle;
 
33
}
 
34
 
 
35
void QgsDetailedItemData::setDetail( const QString theDetail )
 
36
{
 
37
  mDetail = theDetail;
 
38
}
 
39
 
 
40
void QgsDetailedItemData::setIcon( const QPixmap theIcon )
 
41
{
 
42
  mPixmap = theIcon;
 
43
}
 
44
void QgsDetailedItemData::setCheckable( const bool theFlag )
 
45
{
 
46
  mCheckableFlag = theFlag;
 
47
}
 
48
void QgsDetailedItemData::setChecked( const bool theFlag )
 
49
{
 
50
  mCheckedFlag = theFlag;
 
51
}
 
52
void QgsDetailedItemData::setRenderAsWidget( const bool theFlag )
 
53
{
 
54
  mRenderAsWidgetFlag = theFlag;
 
55
}
 
56
 
 
57
QString QgsDetailedItemData::title() const
 
58
{
 
59
  return mTitle;
 
60
}
 
61
 
 
62
QString QgsDetailedItemData::detail() const
 
63
{
 
64
  return mDetail;
 
65
}
 
66
 
 
67
QPixmap QgsDetailedItemData::icon() const
 
68
{
 
69
  return mPixmap;
 
70
}
 
71
 
 
72
bool QgsDetailedItemData::isCheckable() const
 
73
{
 
74
  return mCheckableFlag;
 
75
}
 
76
 
 
77
bool QgsDetailedItemData::isChecked() const
 
78
{
 
79
  return mCheckedFlag;
 
80
}
 
81
 
 
82
bool QgsDetailedItemData::isRenderedAsWidget() const
 
83
{
 
84
  return mRenderAsWidgetFlag;
 
85
}
 
86
 
 
87
void QgsDetailedItemData::setEnabled( bool theFlag )
 
88
{
 
89
  mEnabledFlag = theFlag;
 
90
}
 
91
 
 
92
bool QgsDetailedItemData::isEnabled() const
 
93
{
 
94
  return mEnabledFlag;
 
95
}