2 |
// |
// |
3 |
/**************************************************************************** |
/**************************************************************************** |
4 |
Copyright (C) 2003-2007, rncbc aka Rui Nuno Capela. All rights reserved. |
Copyright (C) 2003-2007, rncbc aka Rui Nuno Capela. All rights reserved. |
5 |
|
Copyright (C) 2007, Christian Schoenebeck |
6 |
|
|
7 |
This program is free software; you can redistribute it and/or |
This program is free software; you can redistribute it and/or |
8 |
modify it under the terms of the GNU General Public License |
modify it under the terms of the GNU General Public License |
66 |
{ |
{ |
67 |
QListViewItem::setRenameEnabled(0, true); |
QListViewItem::setRenameEnabled(0, true); |
68 |
|
|
69 |
QListViewItem::setPixmap(0, QPixmap::fromMimeSource("itemGroup.png")); |
QListViewItem::setPixmap(0, QPixmap(":/icons/itemGroup.png")); |
70 |
QListViewItem::setText(0, sName); |
QListViewItem::setText(0, sName); |
71 |
} |
} |
72 |
|
|
77 |
{ |
{ |
78 |
QListViewItem::setRenameEnabled(0, true); |
QListViewItem::setRenameEnabled(0, true); |
79 |
|
|
80 |
QListViewItem::setPixmap(0, QPixmap::fromMimeSource("itemGroup.png")); |
QListViewItem::setPixmap(0, QPixmap(":/icons/itemGroup.png")); |
81 |
} |
} |
82 |
|
|
83 |
|
|
120 |
{ |
{ |
121 |
// Set the proper pixmap of this... |
// Set the proper pixmap of this... |
122 |
if (rtti() == qsamplerInstrumentList::Group) { |
if (rtti() == qsamplerInstrumentList::Group) { |
123 |
QListViewItem::setPixmap(0, QPixmap::fromMimeSource( |
QListViewItem::setPixmap(0, QPixmap(bOpen ? |
124 |
bOpen ? "itemGroupOpen.png" : "itemGroup.png")); |
":/icons/itemGroupOpen.png" : ":/icons/itemGroup.png")); |
125 |
} |
} |
126 |
// Open it up... |
// Open it up... |
127 |
QListViewItem::setOpen(bOpen); |
QListViewItem::setOpen(bOpen); |
191 |
// Item refreshment. |
// Item refreshment. |
192 |
void qsamplerInstrumentItem::update (void) |
void qsamplerInstrumentItem::update (void) |
193 |
{ |
{ |
194 |
QListViewItem::setPixmap(0, QPixmap::fromMimeSource("itemFile.png")); |
QListViewItem::setPixmap(0, QPixmap(":/icons/itemFile.png")); |
195 |
|
|
196 |
const QString s = "-"; |
const QString s = "-"; |
197 |
if (m_pInstrument) { |
if (m_pInstrument) { |
264 |
QListView::setColumnWidth(5, 240); // File |
QListView::setColumnWidth(5, 240); // File |
265 |
|
|
266 |
m_pNewGroupAction = new QAction( |
m_pNewGroupAction = new QAction( |
267 |
QIconSet(QPixmap::fromMimeSource("itemGroupNew.png")), |
QIcon(":/icons/itemGroupNew.png"), |
268 |
tr("New &Group"), tr("Ctrl+G"), this); |
tr("New &Group"), tr("Ctrl+G"), this); |
269 |
m_pNewItemAction = new QAction( |
m_pNewItemAction = new QAction( |
270 |
QIconSet(QPixmap::fromMimeSource("itemNew.png")), |
QIcon(":/icons/itemNew.png"), |
271 |
tr("New &Instrument..."), tr("Ins"), this); |
tr("New &Instrument..."), tr("Ins"), this); |
272 |
m_pEditItemAction = new QAction( |
m_pEditItemAction = new QAction( |
273 |
QIconSet(QPixmap::fromMimeSource("formEdit.png")), |
QIcon(":/icons/formEdit.png"), |
274 |
tr("&Edit..."), tr("Enter"), this); |
tr("&Edit..."), tr("Enter"), this); |
275 |
m_pRenameAction = new QAction(tr("&Rename"), tr("F2"), this); |
m_pRenameAction = new QAction(tr("&Rename"), tr("F2"), this); |
276 |
m_pDeleteAction = new QAction( |
m_pDeleteAction = new QAction( |
277 |
QIconSet(QPixmap::fromMimeSource("formRemove.png")), |
QIcon(":/icons/formRemove.png"), |
278 |
tr("&Delete"), tr("Del"), this); |
tr("&Delete"), tr("Del"), this); |
279 |
m_pRefreshAction = new QAction( |
m_pRefreshAction = new QAction( |
280 |
QIconSet(QPixmap::fromMimeSource("formRefresh.png")), |
QIcon(":/icons/formRefresh.png"), |
281 |
tr("Re&fresh"), tr("F5"), this); |
tr("Re&fresh"), tr("F5"), this); |
282 |
|
|
283 |
m_pNewGroupAction->setToolTip(tr("New Group")); |
m_pNewGroupAction->setToolTip(tr("New Group")); |
880 |
if (editor) editor->setGeometry(option.rect); |
if (editor) editor->setGeometry(option.rect); |
881 |
} |
} |
882 |
|
|
|
// end of qsamplerInstrumentList.cpp |
|
883 |
|
|
884 |
|
// end of qsamplerInstrumentList.cpp |