00001 /*************************************************************************** 00002 * * 00003 * This program is free software; you can redistribute it and/or modify * 00004 * it under the terms of the GNU General Public License as published by * 00005 * the Free Software Foundation; either version 2 of the License, or * 00006 * (at your option) any later version. * 00007 * * 00008 ***************************************************************************/ 00009 00010 #include "listviewitemconf.h" 00011 00012 ListViewItemConf::ListViewItemConf(ListViewItemConf *parent) 00013 : QListViewItem(parent), _changed(false) 00014 { 00015 } 00016 00017 ListViewItemConf::ListViewItemConf(QListView *parent) 00018 : QListViewItem(parent), _changed(false) 00019 { 00020 _type = File; 00021 } 00022 00023 ListViewItemConf::~ListViewItemConf() 00024 { 00025 } 00026 00027 int ListViewItemConf::getType() 00028 { 00029 return _type; 00030 } 00031 00032 void ListViewItemConf::changed() 00033 { 00034 _changed=true; 00035 displayText(); 00036 } 00037 00038 void ListViewItemConf::unchanged() 00039 { 00040 _changed=false; 00041 for (QListViewItem *it = firstChild(); it!=0;it = it->nextSibling()) 00042 { 00043 ((ListViewItemConf*)it)->unchanged(); 00044 } 00045 displayText(); 00046 } 00047 00048 bool ListViewItemConf::revertable() 00049 { 00050 return _changed; 00051 } 00052 00053 00054
1.4.2