[glibmm] Gio::ListStore::find() docs: Small changes
- From: Kjell Ahlstedt <kjellahl src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [glibmm] Gio::ListStore::find() docs: Small changes
- Date: Thu, 1 Sep 2022 13:02:49 +0000 (UTC)
commit 300f4dadc6be845024f15bafb527baa2905cb859
Author: Kjell Ahlstedt <kjellahlstedt gmail com>
Date: Thu Sep 1 14:57:31 2022 +0200
Gio::ListStore::find() docs: Small changes
gio/src/liststore.hg | 8 ++++----
tests/giomm_listmodel/main.cc | 6 +++---
2 files changed, 7 insertions(+), 7 deletions(-)
---
diff --git a/gio/src/liststore.hg b/gio/src/liststore.hg
index 3a28b944..58b51997 100644
--- a/gio/src/liststore.hg
+++ b/gio/src/liststore.hg
@@ -109,7 +109,7 @@ public:
* @newin{2,74}
*
* @param item An item.
- * @return std::pair{item_found, position} Whether the %ListStoreBase contains @a item.
+ * @return {item_found, position} Whether the %ListStoreBase contains @a item.
* If it was found, @a position will be set to the position where @a item
* occurred for the first time, else @a position = std::numeric_limits<unsigned int>::max().
*/
@@ -138,7 +138,7 @@ public:
*
* @param item An item.
* @param slot A comparison function.
- * @return std::pair{item_found, position} Whether the %ListStoreBase contains @a item.
+ * @return {item_found, position} Whether the %ListStoreBase contains @a item.
* If it was found, @a position will be set to the position where @a item
* occurred for the first time, else @a position = std::numeric_limits<unsigned int>::max().
*/
@@ -288,7 +288,7 @@ public:
* @newin{2,74}
*
* @param item An item.
- * @return std::pair{item_found, position} Whether the %ListStore contains @a item.
+ * @return {item_found, position} Whether the %ListStore contains @a item.
* If it was found, @a position will be set to the position where @a item
* occurred for the first time, else @a position = std::numeric_limits<unsigned int>::max().
*/
@@ -316,7 +316,7 @@ public:
*
* @param item An item.
* @param slot A comparison function.
- * @return std::pair{item_found, position} Whether the %ListStore contains @a item.
+ * @return {item_found, position} Whether the %ListStore contains @a item.
* If it was found, @a position will be set to the position where @a item
* occurred for the first time, else @a position = std::numeric_limits<unsigned int>::max().
*/
diff --git a/tests/giomm_listmodel/main.cc b/tests/giomm_listmodel/main.cc
index f92fc5c7..a93300f1 100644
--- a/tests/giomm_listmodel/main.cc
+++ b/tests/giomm_listmodel/main.cc
@@ -356,7 +356,7 @@ void test_store_find()
items.push_back(Gio::SimpleAction::create(item_string));
auto store = Gio::ListStore<Gio::SimpleAction>::create();
- // Shouldn't crash on an empty list, or change the position pointer.
+ // Shouldn't crash on an empty list.
auto [found_item, position] = store->find(items[0]);
check_found_item_position(1, found_item, position,
false, std::numeric_limits<unsigned int>::max());
@@ -364,11 +364,11 @@ void test_store_find()
for (auto& item : items)
store->append(item);
- // Check whether it could still find the the elements.
+ // Check whether it can find the elements.
for (unsigned int i = 0; i < item_strings.size(); ++i)
{
std::tie(found_item, position) = store->find(items[i]);
- check_found_item_position(1+i, found_item, position, true, i);
+ check_found_item_position(2+i, found_item, position, true, i);
}
// Try to find element not part of the list.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]