diff options
author | Sebastian Schmelzer | 2011-11-03 15:53:13 +0100 |
---|---|---|
committer | Sebastian Schmelzer | 2011-11-03 15:53:13 +0100 |
commit | 7b4db583fe0ae4cccb483a0d56c4559d3a2f1961 (patch) | |
tree | 7e798252cbb0e9d5462ef17b4a5ca9d6fd73e489 /src/SessionTreeItem.cpp | |
parent | some doku (diff) | |
download | libChooser-7b4db583fe0ae4cccb483a0d56c4559d3a2f1961.tar.gz libChooser-7b4db583fe0ae4cccb483a0d56c4559d3a2f1961.tar.xz libChooser-7b4db583fe0ae4cccb483a0d56c4559d3a2f1961.zip |
remove sessiontree
Diffstat (limited to 'src/SessionTreeItem.cpp')
-rw-r--r-- | src/SessionTreeItem.cpp | 65 |
1 files changed, 0 insertions, 65 deletions
diff --git a/src/SessionTreeItem.cpp b/src/SessionTreeItem.cpp deleted file mode 100644 index ed7ead7..0000000 --- a/src/SessionTreeItem.cpp +++ /dev/null @@ -1,65 +0,0 @@ -/* - * Copyright (c) 2010,2011 - RZ Uni Freiburg - * Copyright (c) 2010,2011 - OpenSLX Project - * - * This program/file is free software distributed under the GPL version 2. - * See http://gpl.openslx.org/ - * - * If you have any feedback please consult http://feedback.openslx.org/ and - * send your feedback to feedback@openslx.org - * - * General information about OpenSLX - libChooser can be found under - * http://openslx.org - * - */ - -#include "SessionTreeItem.h" - -SessionTreeItem::SessionTreeItem(const Session* session, - SessionTreeItem *parent) - : parent_(parent), session_(session) { -} - -SessionTreeItem::SessionTreeItem(const QString& text, SessionTreeItem *parent) - : parent_(parent), session_(NULL), text_(text) { -} - -SessionTreeItem::~SessionTreeItem() { - qDeleteAll(children_); -} - -void SessionTreeItem::appendChild(SessionTreeItem *item) { - children_.append(item); -} - -SessionTreeItem *SessionTreeItem::child(int row) { - return children_.value(row); -} - -int SessionTreeItem::childCount() const { - return children_.count(); -} - -int SessionTreeItem::columnCount() const { - return 1; -} - -SessionTreeItem *SessionTreeItem::parent() { - return parent_; -} - -int SessionTreeItem::row() const { - if (parent_) { - return parent_->children_.indexOf(const_cast<SessionTreeItem*>(this)); - } - - return 0; -} - -const Session* SessionTreeItem::session() const { - return session_; -} - -const QString SessionTreeItem::text() const { - return text_; -} |