mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-23 06:09:50 -06:00
CheatSearch: Use index range for ClonePartial
Specify the begin and end indices instead of filling a vector with all the indices which are continuous anyway.
This commit is contained in:
@ -165,11 +165,11 @@ public:
|
||||
// Create a complete copy of this search session.
|
||||
virtual std::unique_ptr<CheatSearchSessionBase> Clone() const = 0;
|
||||
|
||||
// Create a partial copy of this search session. Only the results with the passed indices are
|
||||
// copied. This is useful if you want to run a next search on only partial result data of a
|
||||
// Create a partial copy of this search session. Only the results with indices in the given range
|
||||
// are copied. This is useful if you want to run a next search on only partial result data of a
|
||||
// previous search.
|
||||
virtual std::unique_ptr<CheatSearchSessionBase>
|
||||
ClonePartial(const std::vector<size_t>& result_indices) const = 0;
|
||||
virtual std::unique_ptr<CheatSearchSessionBase> ClonePartial(size_t begin_index,
|
||||
size_t end_index) const = 0;
|
||||
};
|
||||
|
||||
template <typename T>
|
||||
@ -210,8 +210,8 @@ public:
|
||||
bool WasFirstSearchDone() const override;
|
||||
|
||||
std::unique_ptr<CheatSearchSessionBase> Clone() const override;
|
||||
std::unique_ptr<CheatSearchSessionBase>
|
||||
ClonePartial(const std::vector<size_t>& result_indices) const override;
|
||||
std::unique_ptr<CheatSearchSessionBase> ClonePartial(size_t begin_index,
|
||||
size_t end_index) const override;
|
||||
|
||||
private:
|
||||
std::vector<SearchResult<T>> m_search_results;
|
||||
|
Reference in New Issue
Block a user