libyui-mga-qt  1.0.3
YMGA_QCBTable Class Reference
Inheritance diagram for YMGA_QCBTable:
Collaboration diagram for YMGA_QCBTable:

Classes

struct  Private
 

Public Member Functions

 YMGA_QCBTable (YWidget *parent, YTableHeader *header, YCBTableMode checkboxMode)
 Constructor.
 
virtual ~YMGA_QCBTable ()
 Destructor.
 
virtual void setKeepSorting (bool keepSorting)
 Switch between sorting by item insertion order (keepSorting: true) or allowing the user to sort by an arbitrary column (by clicking on the column header). More...
 
virtual void addItem (YItem *item)
 Add an item. More...
 
virtual void addItems (const YItemCollection &itemCollection)
 Add multiple items. More...
 
virtual void selectItem (YItem *item, bool selected=true)
 Select or deselect an item. More...
 
virtual void deselectAllItems ()
 Deselect all items. More...
 
virtual void deleteAllItems ()
 Delete all items. More...
 
virtual void cellChanged (const YTableCell *cell)
 Notification that a cell (its text and/or its icon) was changed from the outside. More...
 
void checkItem (YItem *item, bool checked=true)
 check/uncheck Item from application. More...
 
virtual void setEnabled (bool enabled)
 Set enabled/disabled state. More...
 
virtual int preferredWidth ()
 Preferred width of the widget. More...
 
virtual int preferredHeight ()
 Preferred height of the widget. More...
 
virtual void setSize (int newWidth, int newHeight)
 Set the new size of the widget. More...
 
virtual bool setKeyboardFocus ()
 Accept the keyboard focus. More...
 
int checkboxItemColumn ()
 returns which column is managed by checkboxes, if any -1 otherwise
 

Protected Slots

void slotSelected (QTreeWidgetItem *)
 Notification that an item is selected (single click or keyboard).
 
void slotActivated (QTreeWidgetItem *listViewItem, int column)
 Notification that an item is activated (double click or keyboard).
 
void slotContextMenu (const QPoint &pos)
 Propagate a context menu selection. More...
 
void slotcolumnClicked (QTreeWidgetItem *item, int col)
 

Protected Member Functions

void selectOrigItem (QTreeWidgetItem *listViewItem)
 Select the original item (the YCBTableItem) that corresponds to the specified listViewItem.
 
void addItem (YItem *item, bool batchMode, bool resizeColumnsToContent)
 Internal addItem() method that will not do expensive operations in batch mode.
 

Protected Attributes

QY2ListView * _qt_listView
 

Detailed Description

Definition at line 38 of file YMGA_QCBTable.h.

Member Function Documentation

§ addItem()

void YMGA_QCBTable::addItem ( YItem *  item)
virtual

Add an item.

Reimplemented from YSelectionWidget.

Definition at line 143 of file YMGA_QCBTable.cc.

§ addItems()

void YMGA_QCBTable::addItems ( const YItemCollection &  itemCollection)
virtual

Add multiple items.

Reimplemented for efficiency from YSelectionWidget.

Definition at line 207 of file YMGA_QCBTable.cc.

Here is the call graph for this function:

§ cellChanged()

void YMGA_QCBTable::cellChanged ( const YTableCell *  cell)
virtual

Notification that a cell (its text and/or its icon) was changed from the outside.

Applications are required to call this whenever a table cell is changed after adding the corresponding table item (the row) to the table widget.

Reimplemented from YTable.

Definition at line 291 of file YMGA_QCBTable.cc.

Here is the call graph for this function:

§ checkItem()

void YMGA_QCBTable::checkItem ( YItem *  item,
bool  checked = true 
)

check/uncheck Item from application.

Note that item->check(true) does not update the table

Definition at line 257 of file YMGA_QCBTable.cc.

Here is the call graph for this function:

§ deleteAllItems()

void YMGA_QCBTable::deleteAllItems ( )
virtual

Delete all items.

Reimplemented from YSelectionWidget.

Definition at line 283 of file YMGA_QCBTable.cc.

§ deselectAllItems()

void YMGA_QCBTable::deselectAllItems ( )
virtual

Deselect all items.

Reimplemented from YSelectionWidget.

Definition at line 273 of file YMGA_QCBTable.cc.

§ preferredHeight()

int YMGA_QCBTable::preferredHeight ( )
virtual

Preferred height of the widget.

Reimplemented from YWidget.

Definition at line 399 of file YMGA_QCBTable.cc.

§ preferredWidth()

int YMGA_QCBTable::preferredWidth ( )
virtual

Preferred width of the widget.

Reimplemented from YWidget.

Definition at line 389 of file YMGA_QCBTable.cc.

§ selectItem()

void YMGA_QCBTable::selectItem ( YItem *  item,
bool  selected = true 
)
virtual

Select or deselect an item.

Reimplemented from YSelectionWidget.

Definition at line 233 of file YMGA_QCBTable.cc.

Here is the call graph for this function:

§ setEnabled()

void YMGA_QCBTable::setEnabled ( bool  enabled)
virtual

Set enabled/disabled state.

Reimplemented from YWidget.

Definition at line 379 of file YMGA_QCBTable.cc.

§ setKeepSorting()

void YMGA_QCBTable::setKeepSorting ( bool  keepSorting)
virtual

Switch between sorting by item insertion order (keepSorting: true) or allowing the user to sort by an arbitrary column (by clicking on the column header).

Reimplemented from YTable.

Definition at line 134 of file YMGA_QCBTable.cc.

§ setKeyboardFocus()

bool YMGA_QCBTable::setKeyboardFocus ( )
virtual

Accept the keyboard focus.

Reimplemented from YWidget.

Definition at line 416 of file YMGA_QCBTable.cc.

§ setSize()

void YMGA_QCBTable::setSize ( int  newWidth,
int  newHeight 
)
virtual

Set the new size of the widget.

Reimplemented from YWidget.

Definition at line 409 of file YMGA_QCBTable.cc.

§ slotContextMenu

void YMGA_QCBTable::slotContextMenu ( const QPoint &  pos)
protectedslot

Propagate a context menu selection.

This will trigger an 'ContextMenuActivated' event if 'notifyContextMenu' is set.

Definition at line 425 of file YMGA_QCBTable.cc.


The documentation for this class was generated from the following files: