1 /* This file is part of KDevelop
2 Copyright 2007-2008 Hamish Rodda <rodda@kde.org>
4 This library is free software; you can redistribute it and/or
5 modify it under the terms of the GNU Library General Public
6 License as published by the Free Software Foundation; either
7 version 2 of the License, or (at your option) any later version.
9 This library is distributed in the hope that it will be useful,
10 but WITHOUT ANY WARRANTY; without even the implied warranty of
11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 Library General Public License for more details.
14 You should have received a copy of the GNU Library General Public License
15 along with this library; see the file COPYING.LIB. If not, write to
16 the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
17 Boston, MA 02110-1301, USA.
25 #include <interfaces/irun.h>
26 #include <interfaces/irunprovider.h>
27 #include <interfaces/iruncontroller.h>
29 #include <outputview/ioutputview.h>
30 #include <outputview/outputviewexport.h>
32 class QStandardItemModel
;
38 class KDEVPLATFORMOUTPUTVIEW_EXPORT OutputJob
: public KJob
43 OutputJob(QObject
* parent
= 0);
47 void setRaiseOnCreation(bool raise
);
50 void setStandardToolView(IOutputView::StandardToolView standard
);
51 void setToolTitle(const QString
& title
);
52 void setToolIcon(const KIcon
& icon
);
53 /// Set the \a title for this job's output tab. If not set, will default to the job's objectName().
54 void setTitle(const QString
& title
);
55 void setViewType(IOutputView::ViewType type
);
56 void setBehaviours(IOutputView::Behaviours behaviours
);
57 void setKillJobOnOutputClose(bool killJobOnOutputClose
);
59 QAbstractItemModel
* model() const;
60 void setModel(QAbstractItemModel
* model
, IOutputView::Ownership takeOwnership
= IOutputView::KeepOwnership
);
61 void setDelegate(QAbstractItemDelegate
* delegate
, IOutputView::Ownership takeOwnership
= IOutputView::KeepOwnership
);
66 void outputViewRemoved(int , int id
);
69 int m_standardToolView
;
70 QString m_title
, m_toolTitle
;
72 IOutputView::ViewType m_type
;
73 IOutputView::Behaviours m_behaviours
;
74 bool m_killJobOnOutputClose
;
75 bool m_raiseOnCreation
;
77 QAbstractItemModel
* m_outputModel
;
78 IOutputView::Ownership m_modelOwnership
;
79 QAbstractItemDelegate
* m_outputDelegate
;
80 IOutputView::Ownership m_delegateOwnership
;