1 #ifndef DALI_TOOLKIT_WEB_BACK_FORWARD_LIST_H
2 #define DALI_TOOLKIT_WEB_BACK_FORWARD_LIST_H
5 * Copyright (c) 2021 Samsung Electronics Co., Ltd.
7 * Licensed under the Apache License, Version 2.0 (the "License");
8 * you may not use this file except in compliance with the License.
9 * You may obtain a copy of the License at
11 * http://www.apache.org/licenses/LICENSE-2.0
13 * Unless required by applicable law or agreed to in writing, software
14 * distributed under the License is distributed on an "AS IS" BASIS,
15 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16 * See the License for the specific language governing permissions and
17 * limitations under the License.
22 #include <dali-toolkit/devel-api/controls/web-view/web-back-forward-list-item.h>
23 #include <dali-toolkit/public-api/dali-toolkit-common.h>
27 class WebEngineBackForwardList;
31 class WebBackForwardListItem;
34 * @addtogroup dali_toolkit_controls_web_view
39 * @brief WebBackForwardList is a class for back-forward list item of WebView.
42 * For working WebBackForwardList, a Dali::WebBackForwardList should be provided.
45 class DALI_TOOLKIT_API WebBackForwardList
49 * @brief Creates a WebBackForwardList.
51 WebBackForwardList(const Dali::WebEngineBackForwardList& list);
56 virtual ~WebBackForwardList() final;
59 * @brief Returns the current item in the @a list.
60 * @return The current item in list.
62 WebBackForwardListItem* GetCurrentItem();
65 * @brief Returns the item at a given @a index relative to the current item.
66 * @param[in] index The index of the item
67 * @return The current item in list.
69 WebBackForwardListItem* GetItemAtIndex(uint32_t index);
72 * @brief Returns the length of the back-forward list including the current
74 * @return The length of the back-forward list including the current item,
75 * otherwise 0 in case of an error
77 uint32_t GetItemCount() const;
80 const Dali::WebEngineBackForwardList& mWebEngineBackForwardList;
81 Dali::Toolkit::WebBackForwardListItem mWebBackForwardListItem;
88 } // namespace Toolkit
92 #endif // DALI_TOOLKIT_WEB_BACK_FORWARD_LIST_H