• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /netgear-R7000-V1.0.7.12_1.2.5/ap/gpl/amule/wxWidgets-2.8.12/src/msw/

Lines Matching refs:item

82                                   const wxListItem& item,
115 void Init(LV_ITEM_NATIVE& item)
119 m_pItem = &item;
123 void Init(const LV_ITEM_OTHER& item)
132 memcpy(&m_item, &item, sizeof(LV_ITEM_NATIVE));
135 if ( (item.mask & LVIF_TEXT) && item.pszText )
137 m_buf = new LV_CONV_BUF(wxConvLocal.LV_CONV_TO_WX(item.pszText));
143 wxLV_ITEM(LV_ITEM_NATIVE& item) : m_buf(NULL), m_pItem(&item) { }
146 wxLV_ITEM(LV_ITEM_OTHER& item) : m_buf(NULL)
148 Init(item);
169 // item index. If a item was inserted anywhere but the end
175 // item independent of its position in the list is to
586 bool wxListCtrl::GetColumn(int col, wxListItem& item) const
593 if ( item.m_mask & wxLIST_MASK_TEXT )
600 if ( item.m_mask & wxLIST_MASK_FORMAT )
605 if ( item.m_mask & wxLIST_MASK_IMAGE )
612 // item.m_subItem = lvCol.iSubItem;
613 item.m_width = lvCol.cx;
615 if ( (item.m_mask & wxLIST_MASK_TEXT) && lvCol.pszText )
617 item.m_text = lvCol.pszText;
621 if ( item.m_mask & wxLIST_MASK_FORMAT )
625 item.m_format = wxLIST_FORMAT_LEFT;
628 item.m_format = wxLIST_FORMAT_RIGHT;
631 item.m_format = wxLIST_FORMAT_CENTRE;
634 item.m_format = -1; // Unknown?
644 if ( item.m_mask & wxLIST_MASK_IMAGE )
646 item.m_image = lvCol.iImage;
654 bool wxListCtrl::SetColumn(int col, const wxListItem& item)
657 wxConvertToMSWListCol(GetHwnd(), col, item, lvCol);
716 // Gets information about the item
751 wxLogError(_("Couldn't retrieve information about list control item %d."),
766 // Sets information about the item
771 _T("invalid item index in SetItem") );
773 LV_ITEM item;
774 wxConvertToMSWListItem(this, info, item);
778 item.mask &= ~LVIF_PARAM;
783 // get internal item data
792 item.lParam = (LPARAM) data;
793 item.mask |= LVIF_PARAM;
817 if ( item.mask )
819 item.cchTextMax = 0;
820 if ( !ListView_SetItem(GetHwnd(), &item) )
828 // we need to update the item immediately to show the new image
836 // if the colour has changed, we must redraw the item
843 RefreshItem(item.iItem);
865 // Gets the item state
866 int wxListCtrl::GetItemState(long item, long stateMask) const
872 info.m_itemId = item;
880 // Sets the item state
881 bool wxListCtrl::SetItemState(long item, long state, long stateMask)
891 // item manually when changing focus without changing selection
907 (WPARAM)item, (LPARAM)&lvItem) )
916 // no need to refresh the item if it was previously selected, it would
928 // Sets the item image
929 bool wxListCtrl::SetItemImage(long item, int image, int WXUNUSED(selImage))
931 return SetItemColumnImage(item, 0, image);
934 // Sets the item image
935 bool wxListCtrl::SetItemColumnImage(long item, long column, int image)
941 info.m_itemId = item;
947 // Gets the item text
948 wxString wxListCtrl::GetItemText(long item) const
953 info.m_itemId = item;
960 // Sets the item text
961 void wxListCtrl::SetItemText(long item, const wxString& str)
966 info.m_itemId = item;
972 // Gets the item data
973 wxUIntPtr wxListCtrl::GetItemData(long item) const
978 info.m_itemId = item;
985 // Sets the item data
986 bool wxListCtrl::SetItemPtrData(long item, wxUIntPtr data)
991 info.m_itemId = item;
997 bool wxListCtrl::SetItemData(long item, long data)
999 return SetItemPtrData(item, data);
1021 // Gets the item rectangle
1022 bool wxListCtrl::GetItemRect(long item, wxRect& rect, int code) const
1024 return GetSubItemRect( item, wxLIST_GETSUBITEMRECT_WHOLEITEM, rect, code) ;
1031 * @param item : Item number
1040 bool wxListCtrl::GetSubItemRect(long item, long subItem, wxRect& rect, int code) const
1060 success = ListView_GetItemRect(GetHwnd(), (int) item, &rectWin, codeWin) != 0;
1064 success = ListView_GetSubItemRect( GetHwnd(), (int) item, (int) subItem, codeWin, &rectWin) != 0;
1083 // Gets the item position
1084 bool wxListCtrl::GetItemPosition(long item, wxPoint& pos) const
1088 bool success = (ListView_GetItemPosition(GetHwnd(), (int) item, &pt) != 0);
1094 // Sets the item position.
1095 bool wxListCtrl::SetItemPosition(long item, const wxPoint& pos)
1097 return (ListView_SetItemPosition(GetHwnd(), (int) item, pos.x, pos.y) != 0);
1122 void wxListCtrl::SetItemTextColour( long item, const wxColour &col )
1125 info.m_itemId = item;
1130 wxColour wxListCtrl::GetItemTextColour( long item ) const
1133 wxListItemInternalData *data = wxGetInternalData(this, item);
1140 void wxListCtrl::SetItemBackgroundColour( long item, const wxColour &col )
1143 info.m_itemId = item;
1148 wxColour wxListCtrl::GetItemBackgroundColour( long item ) const
1151 wxListItemInternalData *data = wxGetInternalData(this, item);
1158 void wxListCtrl::SetItemFont( long item, const wxFont &f )
1161 info.m_itemId = item;
1166 wxFont wxListCtrl::GetItemFont( long item ) const
1169 wxListItemInternalData *data = wxGetInternalData(this, item);
1196 // Gets the index of the topmost visible item when in
1203 // Searches for an item, starting from 'item'.
1208 // item can be -1 to find the first item that matches the
1210 // Returns the item or -1 if unsuccessful.
1211 long wxListCtrl::GetNextItem(long item, int geom, int state) const
1235 return (long) ListView_GetNextItem(GetHwnd(), item, flags);
1314 // Deletes an item
1315 bool wxListCtrl::DeleteItem(long item)
1317 if ( !ListView_DeleteItem(GetHwnd(), (int) item) )
1332 if ( item > 0 && GetItemCount() )
1334 GetItemRect(item - 1, rectItem);
1404 // this line and then pressing TAB while editing an item in listctrl
1409 wxTextCtrl* wxListCtrl::EditLabel(long item, wxClassInfo* textControlClass)
1425 WXHWND hWnd = (WXHWND) ListView_EditLabel(GetHwnd(), item);
1463 // Ensures this item is visible
1464 bool wxListCtrl::EnsureVisible(long item)
1466 return ListView_EnsureVisible(GetHwnd(), (int) item, FALSE) != FALSE;
1469 // Find an item whose label matches this string, starting from the item after 'start'
1480 // ListView_FindItem() excludes the first item from search and to look
1488 // Find an item whose data matches this data, starting from the item after 'start'
1508 // Find an item nearest this position in the specified direction, starting from
1509 // the item after 'start' or the beginning if 'start' is -1.
1531 // Determines which item (if any) is at the specified point,
1540 long item;
1544 item = ListView_SubItemHitTest(GetHwnd(), &hitTestInfo);
1550 item = ListView_HitTest(GetHwnd(), &hitTestInfo);
1569 // the right of the item label, ListView_HitTest() returns a combination of
1586 return item;
1590 // Inserts an item, returning the index of the new item if successful,
1596 LV_ITEM item;
1597 wxConvertToMSWListItem(this, info, item);
1598 item.mask &= ~LVIF_PARAM;
1605 item.mask |= LVIF_PARAM;
1609 item.lParam = (LPARAM) data;
1625 long rv = ListView_InsertItem(GetHwnd(), & item);
1643 // Inserts an image item
1653 // Inserts an image/string item
1665 long wxListCtrl::InsertColumn(long col, const wxListItem& item)
1668 wxConvertToMSWListCol(GetHwnd(), col, item, lvCol);
1697 wxListItem item;
1698 item.m_mask = wxLIST_MASK_TEXT | wxLIST_MASK_FORMAT;
1699 item.m_text = heading;
1702 item.m_mask |= wxLIST_MASK_WIDTH;
1703 item.m_width = width;
1705 item.m_format = format;
1707 return InsertColumn(col, item);
1727 // item1 is the long data associated with a first item (NOT the index).
1728 // item2 is the long data associated with a second item (NOT the index).
1730 // The return value is a negative number if the first item should precede the second
1731 // item, a positive number of the second item should precede the first,
1863 // something other than the item width changes so we'd have to
1982 // If we have a valid item then check if there is a data value
2017 wxLV_ITEM item;
2020 item.Init(((LV_DISPINFOA *)lParam)->item);
2024 item.Init(((LV_DISPINFOW *)lParam)->item);
2028 wxConvertFromMSWListItem(GetHwnd(), event.m_item, item);
2036 wxLV_ITEM item;
2039 item.Init(((LV_DISPINFOA *)lParam)->item);
2043 item.Init(((LV_DISPINFOW *)lParam)->item);
2047 const LV_ITEM& lvi = (LV_ITEM)item;
2065 wxConvertFromMSWListItem(NULL, event.m_item, item);
2100 wxConvertFromMSWListItem(GetHwnd(), event.m_item, info->item);
2115 // only for valid items (item == -1 for the virtual list
2177 // <Enter> or <Space> activate the selected item if any (but
2218 // if it happened on an item (and not on empty place)
2221 // not on item
2280 // deleting an item, for items in invalid range -- filter
2318 // this is the first item we should examine, search from it
2336 // does this item begin with searchstr?
2370 LV_ITEM& lvi = info->item;
2371 long item = lvi.iItem;
2375 wxString text = OnGetItemText(item, lvi.iSubItem);
2384 lvi.iImage = OnGetItemColumnImage(item, lvi.iSubItem);
2506 const DWORD item = nmcd.dwItemSpec;
2508 // the font must be valid, otherwise we wouldn't be painting the item at all
2513 ListView_GetSubItemRect(hwndList, item, col, LVIR_BOUNDS, &rc);
2516 // broken ListView_GetSubItemRect() returns the entire item rect for
2519 ListView_GetSubItemRect(hwndList, item, 1, LVIR_BOUNDS, &rc2);
2534 it.iItem = item;
2550 // notice that even if this item doesn't have any image, the list
2616 const int item = nmcd.dwItemSpec;
2619 // the item is not at all selected for some reason (comctl32 6), but we
2621 // item status if we're called just after the (de)selection, so remember
2622 // the last item to gain selection and also check for it here
2632 if ( i == item )
2641 ListView_GetNextItem(hwndList, (WPARAM)-1, LVNI_FOCUSED) == item )
2696 // nothing to do for this item
2717 // 4.something) so we have to draw the item entirely ourselves in
2739 // notify us before painting each item
2748 const int item = nmcd.dwItemSpec;
2750 // we get this message with item == 0 for an empty control, we
2752 if ( item < 0 || item >= GetItemCount() )
2755 return HandleItemPrepaint(this, pLVCD, DoGetItemAttr(item));
2872 wxString wxListCtrl::OnGetItemText(long WXUNUSED(item), long WXUNUSED(col)) const
2881 int wxListCtrl::OnGetItemImage(long WXUNUSED(item)) const
2889 int wxListCtrl::OnGetItemColumnImage(long item, long column) const
2892 return OnGetItemImage(item);
2897 wxListItemAttr *wxListCtrl::OnGetItemAttr(long WXUNUSED_UNLESS_DEBUG(item)) const
2899 wxASSERT_MSG( item >= 0 && item < GetItemCount(),
2900 _T("invalid item index in OnGetItemAttr()") );
2906 wxListItemAttr *wxListCtrl::DoGetItemAttr(long item) const
2908 return IsVirtual() ? OnGetItemAttr(item)
2909 : wxGetInternalDataAttr(this, item);
2926 void wxListCtrl::RefreshItem(long item)
2931 if ( !ListView_Update(GetHwnd(), item) )
2937 GetItemRect(item, rect);
2989 LV_ITEM item;
2990 memset(&item, 0, sizeof(item));
2991 item.iItem = itemId;
2992 item.mask = LVIF_PARAM;
2993 item.lParam = (LPARAM) 0;
2994 ListView_SetItem((HWND)ctl->GetHWND(), &item);
3161 const wxListItem& item,
3166 if ( item.m_mask & wxLIST_MASK_TEXT )
3169 lvCol.pszText = (wxChar *)item.m_text.c_str(); // cast is safe
3172 if ( item.m_mask & wxLIST_MASK_FORMAT )
3176 if ( item.m_format == wxLIST_FORMAT_LEFT )
3178 else if ( item.m_format == wxLIST_FORMAT_RIGHT )
3180 else if ( item.m_format == wxLIST_FORMAT_CENTRE )
3184 if ( item.m_mask & wxLIST_MASK_WIDTH )
3187 if ( item.m_width == wxLIST_AUTOSIZE)
3189 else if ( item.m_width == wxLIST_AUTOSIZE_USEHEADER)
3192 lvCol.cx = item.m_width;
3197 if ( item.m_mask & wxLIST_MASK_IMAGE )
3210 if ( item.m_image != -1 )
3230 lvCol.iImage = item.m_image;
3232 //else: it doesn't support item images anyhow