C++: use size_t everywhere as index in our models

cc #2024
This commit is contained in:
Olivier Goffart 2023-02-07 12:06:01 +01:00 committed by Olivier Goffart
parent 1370bd771f
commit eaa9db4911
9 changed files with 91 additions and 72 deletions

View file

@ -445,15 +445,15 @@ inline Value::Value(const std::shared_ptr<slint::Model<Value>> &model)
std::shared_ptr<ModelChangeListener> self;
~ModelWrapper() { cbindgen_private::slint_interpreter_model_notify_destructor(&notify); }
void row_added(int index, int count) override
void row_added(size_t index, size_t count) override
{
cbindgen_private::slint_interpreter_model_notify_row_added(&notify, index, count);
}
void row_changed(int index) override
void row_changed(size_t index) override
{
cbindgen_private::slint_interpreter_model_notify_row_changed(&notify, index);
}
void row_removed(int index, int count) override
void row_removed(size_t index, size_t count) override
{
cbindgen_private::slint_interpreter_model_notify_row_removed(&notify, index, count);
}