本文整理汇总了C++中QListViewItem::repaint方法的典型用法代码示例。如果您正苦于以下问题:C++ QListViewItem::repaint方法的具体用法?C++ QListViewItem::repaint怎么用?C++ QListViewItem::repaint使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类QListViewItem
的用法示例。
在下文中一共展示了QListViewItem::repaint方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: update
void Workspace::update( FormFile* ff )
{
QListViewItem* i = findItem( ff );
if ( i ) {
i->repaint();
if ( (i = i->firstChild()) )
i->repaint();
}
}
示例2: selectViewItem
void TeQtViewsListView::selectViewItem(TeView *view)
{
if (view == 0)
return;
QListViewItem *child = firstChild();
while (child)
{
TeQtViewItem *viewItem = (TeQtViewItem*)child;
if (viewItem->getView() == view)
{
if (viewItem == currentViewItem_)
break;
else
{
unselectAllItems();
child->setSelected(true);
child->repaint();
currentViewItem_ = viewItem;
currentThemeItem_ = 0;
emit itemChanged(child);
return;
}
}
child = child->nextSibling();
}
}
示例3: slotOpen
void BaseTreeView::slotOpen()
{
QListViewItem *item = currentItem();
if (item)
{
emit open(item);
item->repaint();
}
}
示例4: getContacts
ContactDragObject::~ContactDragObject()
{
ListView *view = static_cast<ListView*>(parent());
if (view->m_pressedItem){
QListViewItem *item = view->m_pressedItem;
view->m_pressedItem = NULL;
item->repaint();
}
Contact *contact = getContacts()->contact(m_id);
if (contact && (contact->getTemporary() & CONTACT_DRAG))
delete contact;
}
示例5: unselectAllItems
void TeQtViewsListView::unselectAllItems()
{
QListViewItem *item;
QListViewItemIterator it(this);
item = it.current();
while(item)
{
setSelected(item,false);
item->repaint();
it++;
item = it.current();
}
}
示例6: contentsMouseReleaseEvent
void ListView::contentsMouseReleaseEvent(QMouseEvent *e)
{
#if QT_VERSION < 300
m_mousePressPos = QPoint(0, 0);
#endif
QListView::contentsMouseReleaseEvent(e);
if (m_pressedItem){
QListViewItem *item = m_pressedItem;
m_pressedItem = NULL;
item->repaint();
QListViewItem *citem = itemAt(contentsToViewport(e->pos()));
if (item == citem)
emit clickItem(item);
}
}