Home
last modified time | relevance | path

Searched refs:itemIndex (Results 1 - 25 of 81) sorted by relevance

1234

/foundation/arkui/ace_engine/frameworks/core/components/indexer/
H A Dindexer_item_component.cpp99 uint32_t itemIndex = 0; in AddIndexKey() local
103 return itemIndex; in AddIndexKey()
112 return itemIndex; in AddIndexKey()
117 return itemIndex; in AddIndexKey()
123 itemIndex++; in AddIndexKey()
127 itemIndex++; in AddIndexKey()
133 itemIndex++; in AddIndexKey()
137 itemIndex += static_cast<uint32_t>(sectionIndex_); in AddIndexKey()
139 itemIndex--; in AddIndexKey()
142 return itemIndex; in AddIndexKey()
147 uint32_t itemIndex = 0; AddIndexKeyForSharp() local
[all...]
H A Dindexer_component.cpp317 int32_t itemIndex = INDEXER_INVALID_INDEX; in AddItemIndexKey() local
320 return itemIndex; in AddItemIndexKey()
336 itemIndex = static_cast<int32_t>(item->AddIndexKey(indexKey)); in AddItemIndexKey()
342 if (itemIndex == INVALID_INDEX) { in AddItemIndexKey()
343 itemIndex = AddItemToSharp(indexKey, headStyle); in AddItemIndexKey()
348 return itemIndex; in AddItemIndexKey()
373 int32_t itemIndex = static_cast<int32_t>(itemPtr->AddIndexKey(indexKey)); in AddItemToSharp() local
377 return itemIndex; in AddItemToSharp()
H A Dindexer_list_component.cpp49 int32_t itemIndex = indexer_->AddItemIndexKey(listItem->GetIndexKey(), listItem->GetType()); in AppendChild() local
50 list_->InsertChild(itemIndex, child); in AppendChild()
/foundation/arkui/ace_engine/frameworks/core/components_ng/pattern/grid/grid_scroll/
H A Dgrid_scroll_with_options_layout_algorithm.cpp31 const RefPtr<LayoutWrapper>& itemLayoutWrapper, LayoutWrapper* layoutWrapper, int32_t itemIndex) in AdjustRowColSpan()
33 auto result = GetCrossStartAndSpan(layoutWrapper, itemIndex); in AdjustRowColSpan()
122 LayoutWrapper* layoutWrapper, int32_t itemIndex) in GetCrossStartAndSpan()
128 return std::make_pair(itemIndex % crossCount_, 1); in GetCrossStartAndSpan()
132 if (itemIndex < firstIrregularIndex) { in GetCrossStartAndSpan()
133 return std::make_pair(itemIndex % crossCount_, 1); in GetCrossStartAndSpan()
138 if (options.irregularIndexes.find(itemIndex) != options.irregularIndexes.end()) { in GetCrossStartAndSpan()
142 auto iter = options.irregularIndexes.upper_bound(itemIndex); in GetCrossStartAndSpan()
145 crossStart = (itemIndex - (*(options.irregularIndexes.rbegin()) + 1)) % crossCount; in GetCrossStartAndSpan()
148 crossStart = (itemIndex in GetCrossStartAndSpan()
30 AdjustRowColSpan( const RefPtr<LayoutWrapper>& itemLayoutWrapper, LayoutWrapper* layoutWrapper, int32_t itemIndex) AdjustRowColSpan() argument
121 GetCrossStartAndSpan( LayoutWrapper* layoutWrapper, int32_t itemIndex) GetCrossStartAndSpan() argument
206 GetCrossStartAndSpanWithUserFunction( int32_t itemIndex, const GridLayoutOptions& options, int32_t firstIrregularIndex) GetCrossStartAndSpanWithUserFunction() argument
[all...]
H A Dgrid_scroll_with_options_layout_algorithm.h40 const RefPtr<LayoutWrapper>& itemLayoutWrapper, LayoutWrapper* layoutWrapper, int32_t itemIndex) override;
42 std::pair<int32_t, int32_t> GetCrossStartAndSpan(LayoutWrapper* layoutWrapper, int32_t itemIndex);
45 int32_t itemIndex, const GridLayoutOptions& options, int32_t firstIrregularIndex);
H A Dgrid_scroll_layout_algorithm.h104 int32_t MeasureNewChild(const SizeF& frameSize, int32_t itemIndex, LayoutWrapper* layoutWrapper,
107 int32_t MeasureChildPlaced(const SizeF& frameSize, int32_t itemIndex, int32_t crossStart,
140 OffsetF currOffset, int32_t itemIndex, int32_t currLineIndex, int32_t currentCrossIndex);
143 const RefPtr<LayoutWrapper>& itemLayoutWrapper, LayoutWrapper* layoutWrapper, int32_t itemIndex);
159 int32_t MeasureCachedChild(const SizeF& frameSize, int32_t itemIndex, LayoutWrapper* layoutWrapper,
/foundation/arkui/ace_engine/frameworks/core/components_ng/pattern/list/
H A Dlist_event_hub.h125 RefPtr<UINode> FireOnItemDragStart(const ItemDragInfo& dragInfo, int32_t itemIndex) const in FireOnItemDragStart()
128 return AceType::DynamicCast<UINode>(onItemDragStartEvent_(dragInfo, itemIndex)); in FireOnItemDragStart()
140 void FireOnItemDragMove(const ItemDragInfo& dragInfo, int32_t itemIndex, int32_t insertIndex) const in FireOnItemDragMove() argument
143 onItemDragMoveEvent_(dragInfo, itemIndex, insertIndex); in FireOnItemDragMove()
147 void FireOnItemDragLeave(const ItemDragInfo& dragInfo, int32_t itemIndex) const in FireOnItemDragLeave()
150 onItemDragLeaveEvent_(dragInfo, itemIndex); in FireOnItemDragLeave()
154 bool FireOnItemDrop(const ItemDragInfo& dragInfo, int32_t itemIndex, int32_t insertIndex, bool isSuccess) const in FireOnItemDrop() argument
157 if (onItemMoveEvent_ && itemIndex >= 0 && insertIndex >= 0) { in FireOnItemDrop()
158 isSuccess = onItemMoveEvent_(itemIndex, insertIndex); in FireOnItemDrop()
160 onItemDropEvent_(dragInfo, itemIndex, insertInde in FireOnItemDrop()
[all...]
H A Dlist_position_controller.cpp38 auto itemIndex = listPattern->GetItemIndexInGroup(x, y); in GetItemIndexInGroup() local
40 itemGroupIndex.index = itemIndex.index; in GetItemIndexInGroup()
41 itemGroupIndex.area = itemIndex.area; in GetItemIndexInGroup()
42 itemGroupIndex.indexInGroup = itemIndex.indexInGroup; in GetItemIndexInGroup()
/foundation/arkui/ace_engine/frameworks/core/components/list/
H A Dlist_watch_layout_manager.cpp40 int32_t itemIndex = GetIndexByPosition(head_); in PerformLayout() local
41 renderList_.RecycleHead(itemIndex - 1); // Recycle head items. in PerformLayout()
42 double curMainSize = GetItemPosition(itemIndex); in PerformLayout()
44 auto itemChild = renderList_.GetChildByIndex(itemIndex); in PerformLayout()
45 int32_t firstIndex = itemIndex; in PerformLayout()
49 if (itemIndex == ZERO_INDEX) { in PerformLayout()
54 SetChildPosition(itemChild, itemIndex, curMainSize); in PerformLayout()
55 itemPosition_[itemIndex] = curMainSize; in PerformLayout()
61 itemChild = renderList_.GetChildByIndex(++itemIndex); in PerformLayout()
63 RequestMoreItemsIfNeeded(firstIndex, itemIndex); in PerformLayout()
[all...]
H A Dgrid_layout_manager.cpp279 int32_t itemIndex = GetIndexByPosition(head_); in PerformLayout() local
280 int32_t firstIndex = itemIndex; in PerformLayout()
281 renderList_.RecycleHead(itemIndex - 1); // Recycle head items. in PerformLayout()
282 double curMainSize = GetItemPosition(itemIndex); in PerformLayout()
283 auto itemChild = renderList_.GetChildByIndex(itemIndex); in PerformLayout()
284 while (!itemChild && curMainSize < tail_ && CheckItemPosition(itemIndex)) { in PerformLayout()
285 itemChild = renderList_.GetChildByIndex(itemIndex); in PerformLayout()
286 curMainSize = GetItemPosition(itemIndex); in PerformLayout()
287 ++itemIndex; in PerformLayout()
289 int32_t curGrid = GetItemGrid(itemIndex); in PerformLayout()
[all...]
H A Dlist_layout_manager.cpp409 int32_t itemIndex = GetIndexByPosition(head_ - chainOffset_); in PerformLayout() local
410 int32_t firstIndex = itemIndex; in PerformLayout()
411 renderList_.RecycleHead(itemIndex - 1); // Recycle head items. in PerformLayout()
412 double curMainSize = GetItemPosition(itemIndex); in PerformLayout()
413 double curAnimateMainSize = curMainSize + GetItemAnimationValue(itemIndex); in PerformLayout()
415 auto itemChild = renderList_.GetChildByIndex(itemIndex); in PerformLayout()
416 while (!itemChild && curAnimateMainSize < tail_ - chainOffset_ && CheckItemPosition(itemIndex)) { in PerformLayout()
417 itemChild = renderList_.GetChildByIndex(itemIndex); in PerformLayout()
418 curMainSize = GetItemPosition(itemIndex); in PerformLayout()
419 curAnimateMainSize = curMainSize + GetItemAnimationValue(itemIndex); in PerformLayout()
[all...]
H A Dlist_item_group_element.cpp66 int32_t itemIndex = 0; in PerformBuild() local
71 primary != *listItemIter ? itemElement->SetIndex(++itemIndex) : itemElement->SetIndex(0); in PerformBuild()
80 primary != *listItemIter ? itemElement->SetIndex(++itemIndex) : itemElement->SetIndex(0); in PerformBuild()
319 void ListItemGroupElement::ItemFocus(int32_t itemIndex) in ItemFocus() argument
322 if (focusIndex == itemIndex) { in ItemFocus()
331 AddItemGroupFocusIndex(itemIndex); in ItemFocus()
/foundation/arkui/ace_engine/frameworks/core/components_ng/pattern/grid/
H A Dgrid_event_hub.cpp281 void GridEventHub::FireOnItemDragLeave(const ItemDragInfo& dragInfo, int32_t itemIndex) in FireOnItemDragLeave() argument
283 if (itemIndex == -1) { in FireOnItemDragLeave()
289 MoveItems(itemIndex, insertIndex); in FireOnItemDragLeave()
293 onItemDragLeave_(dragInfo, itemIndex); in FireOnItemDragLeave()
297 bool GridEventHub::FireOnItemDrop(const ItemDragInfo& dragInfo, int32_t itemIndex, int32_t insertIndex, bool isSuccess) in FireOnItemDrop() argument
299 TAG_LOGI(AceLogTag::ACE_GRID, "itemIndex:%{public}d, insertIndex:%{public}d", itemIndex, insertIndex); in FireOnItemDrop()
305 insertIndex = (itemIndex == -1 || insertIndex == -1) ? insertIndex : pattern->GetOriginalIndex(); in FireOnItemDrop()
310 onItemDrop_(dragInfo, itemIndex, insertIndex, isSuccess); in FireOnItemDrop()
318 void GridEventHub::FireOnItemDragMove(const ItemDragInfo& dragInfo, int32_t itemIndex, int32_ argument
334 MoveItems(int32_t itemIndex, int32_t insertIndex) const MoveItems() argument
[all...]
H A Dgrid_event_hub.h110 RefPtr<UINode> FireOnItemDragStart(const ItemDragInfo& dragInfo, int32_t itemIndex) const in FireOnItemDragStart()
113 return onItemDragStart_(dragInfo, itemIndex); in FireOnItemDragStart()
120 void FireOnItemDragMove(const ItemDragInfo& dragInfo, int32_t itemIndex, int32_t insertIndex) const;
122 void FireOnItemDragLeave(const ItemDragInfo& dragInfo, int32_t itemIndex);
124 bool FireOnItemDrop(const ItemDragInfo& dragInfo, int32_t itemIndex, int32_t insertIndex, bool isSuccess);
148 void MoveItems(int32_t itemIndex, int32_t insertIndex) const;
H A Dgrid_layout_base_algorithm.cpp44 const int32_t itemIndex = iter->second; in AdjustChildrenHeight() local
45 auto child = layoutWrapper->GetChildByIndex(itemIndex); in AdjustChildrenHeight()
H A Dgrid_layout_info.cpp29 int32_t GridLayoutInfo::GetPositionByItemIndex(int32_t itemIndex) in GetPositionByItemIndex() argument
31 auto position = itemIndex; in GetPositionByItemIndex()
33 [itemIndex](const std::pair<int32_t, int32_t>& item) { return item.second == itemIndex; }); in GetPositionByItemIndex()
53 void GridLayoutInfo::MoveItemsBack(int32_t from, int32_t to, int32_t itemIndex) in MoveItemsBack() argument
55 auto lastItemIndex = itemIndex; in MoveItemsBack()
63 gridMatrix_[mainIndex][crossIndex] = itemIndex; in MoveItemsBack()
71 positionItemIndexMap_[from] = itemIndex; in MoveItemsBack()
76 void GridLayoutInfo::MoveItemsForward(int32_t from, int32_t to, int32_t itemIndex) in MoveItemsForward() argument
85 gridMatrix_[mainIndex][crossIndex] = itemIndex; in MoveItemsForward()
96 SwapItems(int32_t itemIndex, int32_t insertIndex) SwapItems() argument
[all...]
/foundation/arkui/ace_engine/frameworks/core/components_ng/pattern/waterflow/layout/top_down/
H A Dwater_flow_layout_info.cpp21 int32_t WaterFlowLayoutInfo::GetCrossIndex(int32_t itemIndex) const in GetCrossIndex()
23 if (static_cast<size_t>(itemIndex) < itemInfos_.size()) { in GetCrossIndex()
24 return itemInfos_[itemIndex].crossIdx; in GetCrossIndex()
26 for (const auto& crossItems : items_[GetSegment(itemIndex)]) { in GetCrossIndex()
27 auto iter = crossItems.second.find(itemIndex); in GetCrossIndex()
115 float WaterFlowLayoutInfo::GetMainHeight(int32_t crossIndex, int32_t itemIndex) const in GetMainHeight()
117 if (static_cast<size_t>(itemIndex) < itemInfos_.size() && itemInfos_[itemIndex].crossIdx == crossIndex) { in GetMainHeight()
118 return itemInfos_[itemIndex].mainOffset + itemInfos_[itemIndex] in GetMainHeight()
[all...]
H A Dwater_flow_layout_info.h58 int32_t GetCrossIndex(int32_t itemIndex) const override;
75 float GetMainHeight(int32_t crossIndex, int32_t itemIndex) const;
76 float GetStartMainPos(int32_t crossIndex, int32_t itemIndex) const;
/foundation/arkui/ace_engine/frameworks/core/components_ng/pattern/waterflow/layout/
H A Dwater_flow_layout_utils.cpp52 auto itemIndex = info->GetCrossIndexForNextItem(segment); in GetItemPosition() local
56 return { itemIndex.crossIndex, 0.0f }; in GetItemPosition()
58 if (itemIndex.lastItemIndex < 0) { in GetItemPosition()
59 return { itemIndex.crossIndex, info->segmentStartPos_[segment] }; in GetItemPosition()
61 auto mainHeight = info->GetMainHeight(itemIndex.crossIndex, itemIndex.lastItemIndex); in GetItemPosition()
62 return { itemIndex.crossIndex, mainHeight + mainGap }; in GetItemPosition()
/foundation/arkui/ace_engine/frameworks/core/components_ng/pattern/grid/grid_layout/
H A Dgrid_layout_algorithm.cpp268 int32_t itemIndex = 0; in Measure() local
294 CheckGridPlaced(itemIndex, itemRowStart, itemColStart, itemRowSpan, itemColSpan)) { in Measure()
300 while (!CheckGridPlaced(itemIndex, rowIndex, colIndex, itemRowSpan, itemColSpan)) { in Measure()
314 PrintConflictingPositionLog(itemIndex, rect, rowIndex, colIndex, itemRowSpan, itemColSpan); in Measure()
322 ++itemIndex; in Measure()
324 gridLayoutInfo_.endIndex_ = itemIndex - 1; in Measure()
354 int32_t itemIndex = -1; in Layout() local
357 if (itemIndex == crossLine.second) { in Layout()
360 itemIndex = crossLine.second; in Layout()
361 auto wrapper = layoutWrapper->GetOrCreateChildByIndex(itemIndex); in Layout()
376 PrintConflictingPositionLog( int32_t itemIndex, GridItemRect rect, int32_t rowIndex, int32_t colIndex, int32_t rowSpan, int32_t colSpan) PrintConflictingPositionLog() argument
[all...]
/foundation/arkui/ace_engine/frameworks/bridge/declarative_frontend/engine/functions/
H A Djs_drag_function.h34 JSRef<JSVal> ItemDragStartExecute(const ItemDragInfo& info, int32_t itemIndex);
36 void ItemDragMoveExecute(const ItemDragInfo& info, int32_t itemIndex, int32_t insertIndex);
37 void ItemDragLeaveExecute(const ItemDragInfo& info, int32_t itemIndex);
38 void ItemDropExecute(const ItemDragInfo& info, int32_t itemIndex, int32_t insertIndex, bool isSuccess);
H A Djs_drag_function.cpp426 JSRef<JSVal> JsDragFunction::ItemDragStartExecute(const ItemDragInfo& info, int32_t itemIndex) in ItemDragStartExecute() argument
429 JSRef<JSVal> itemIndexParam = JSRef<JSVal>::Make(ToJSValue(itemIndex)); in ItemDragStartExecute()
441 void JsDragFunction::ItemDragMoveExecute(const ItemDragInfo& info, int32_t itemIndex, int32_t insertIndex) in ItemDragMoveExecute() argument
444 JSRef<JSVal> itemIndexParam = JSRef<JSVal>::Make(ToJSValue(itemIndex)); in ItemDragMoveExecute()
450 void JsDragFunction::ItemDragLeaveExecute(const ItemDragInfo& info, int32_t itemIndex) in ItemDragLeaveExecute() argument
453 JSRef<JSVal> itemIndexParam = JSRef<JSVal>::Make(ToJSValue(itemIndex)); in ItemDragLeaveExecute()
458 void JsDragFunction::ItemDropExecute(const ItemDragInfo& info, int32_t itemIndex, int32_t insertIndex, bool isSuccess) in ItemDropExecute() argument
461 JSRef<JSVal> itemIndexParam = JSRef<JSVal>::Make(ToJSValue(itemIndex)); in ItemDropExecute()
/foundation/arkui/ace_engine/frameworks/core/components_v2/grid/
H A Drender_grid_scroll.cpp798 double RenderGridScroll::SupplyItems(int32_t mainIndex, int32_t itemIndex, bool needPosition) in SupplyItems() argument
805 Rank(mainIndex, itemIndex); in SupplyItems()
828 bool RenderGridScroll::Rank(int32_t mainIndex, int32_t itemIndex) in Rank() argument
834 if (itemIndex == -1) { in Rank()
840 itemIndex = iter->second + 1; in Rank()
846 if (itemIndex == -1) { in Rank()
847 LOGE("failed, itemIndex = -1, mainIndex = %d", mainIndex); in Rank()
859 auto item = items_.find(itemIndex); in Rank()
866 if (!getChildSpanByIndex_(itemIndex, useScrollable_ == SCROLLABLE::HORIZONTAL, itemMain, itemCross, in Rank()
873 itemIndex in Rank()
1410 auto itemIndex = startItemIdx; BuildItemsBackwardByRange() local
1470 auto itemIndex = startItemIdx; BuildItemsForwardByRange() local
1564 GetItemPropsByIndex( int32_t itemIndex, int32_t& itemMain, int32_t& itemCross, int32_t& itemMainSpan, int32_t& itemCrossSpan) GetItemPropsByIndex() argument
[all...]
/foundation/arkui/ace_engine/frameworks/core/components_v2/water_flow/
H A Drender_water_flow.cpp81 size_t itemIndex = GetNextSupplyedIndex(); in PerformLayout() local
83 SupplyItems(itemIndex, targetPos); in PerformLayout()
250 void RenderWaterFlow::SetChildPosition(const RefPtr<RenderNode>& child, size_t itemIndex) in SetChildPosition() argument
256 auto iter = flowMatrix_.find(itemIndex); in SetChildPosition()
413 LayoutParam RenderWaterFlow::MakeInnerLayoutParam(size_t itemIndex) in MakeInnerLayoutParam() argument
418 auto iter = flowMatrix_.find(itemIndex); in MakeInnerLayoutParam()
482 for (const auto& itemIndex : items) { in LayoutItems()
483 if (items_.find(itemIndex) == items_.end()) { in LayoutItems()
484 if (!buildChildByIndex_(itemIndex)) { in LayoutItems()
488 innerLayoutParam = MakeInnerLayoutParam(itemIndex); in LayoutItems()
813 size_t itemIndex = GetNextSupplyedIndex(); ScrollToIndex() local
858 size_t itemIndex = GetNextSupplyedIndex(); OnPredictLayout() local
[all...]
/foundation/arkui/ace_engine/frameworks/bridge/declarative_frontend/jsview/
H A Djs_grid.cpp123 JSRef<JSVal> itemIndex = JSRef<JSVal>::Make(ToJSValue(index)); in ParseGetGridItemSize()
124 auto result = func->ExecuteJS(1, &itemIndex); in ParseGetGridItemSize()
143 JSRef<JSVal> itemIndex = JSRef<JSVal>::Make(ToJSValue(index)); in ParseGetGridItemRect()
144 auto result = func->ExecuteJS(1, &itemIndex); in ParseGetGridItemRect()
316 JSRef<JSVal> itemIndex = JSRef<JSVal>::Make(ToJSValue(index)); in JsOnScrollBarUpdate()
318 JSRef<JSVal> params[2] = { itemIndex, itemOffset }; in JsOnScrollBarUpdate()
550 const ItemDragInfo& dragInfo, int32_t itemIndex, int32_t insertIndex) { in JsOnGridDragMove()
553 func->ItemDragMoveExecute(dragInfo, itemIndex, insertIndex); in JsOnGridDragMove()
566 const ItemDragInfo& dragInfo, int32_t itemIndex) { in JsOnGridDragLeave()
569 func->ItemDragLeaveExecute(dragInfo, itemIndex); in JsOnGridDragLeave()
[all...]

Completed in 17 milliseconds

1234