[ExecString] combine SplitParameters with identical function of CUtil
[xbmc.git] / xbmc / guilib / GUIWrappingListContainer.h
blobda1e10680c5804c315a4e1e92dd905ba8cc0eb04
1 /*
2 * Copyright (C) 2005-2018 Team Kodi
3 * This file is part of Kodi - https://kodi.tv
5 * SPDX-License-Identifier: GPL-2.0-or-later
6 * See LICENSES/README.md for more information.
7 */
9 #pragma once
11 /*!
12 \file GUIListContainer.h
13 \brief
16 #include "GUIBaseContainer.h"
17 /*!
18 \ingroup controls
19 \brief
21 class CGUIWrappingListContainer : public CGUIBaseContainer
23 public:
24 CGUIWrappingListContainer(int parentID, int controlID, float posX, float posY, float width, float height, ORIENTATION orientation, const CScroller& scroller, int preloadItems, int fixedPosition);
25 ~CGUIWrappingListContainer(void) override;
26 CGUIWrappingListContainer* Clone() const override { return new CGUIWrappingListContainer(*this); }
28 bool OnAction(const CAction &action) override;
29 bool OnMessage(CGUIMessage& message) override;
30 int GetSelectedItem() const override;
32 protected:
33 void Scroll(int amount) override;
34 bool MoveDown(bool wrapAround) override;
35 bool MoveUp(bool wrapAround) override;
36 bool GetOffsetRange(int &minOffset, int &maxOffset) const override;
37 void ValidateOffset() override;
38 int CorrectOffset(int offset, int cursor) const override;
39 bool SelectItemFromPoint(const CPoint &point) override;
40 void SelectItem(int item) override;
41 void Reset() override;
42 size_t GetNumItems() const override { return m_items.size() - m_extraItems; }
43 int GetCurrentPage() const override;
44 void SetPageControlRange() override;
45 void UpdatePageControl(int offset) override;
47 void ResetExtraItems();
48 unsigned int m_extraItems;