MCPcopy Create free account
hub / github.com/PCSX2/pcsx2 / SetInt

Method SetInt

3rdparty/imgui/src/imgui.cpp:3002–3009  ·  view source on GitHub ↗

FIXME-OPT: Need a way to reuse the result of lower_bound when doing GetInt()/SetInt() - not too bad because it only happens on explicit interaction (maximum one a frame)

Source from the content-addressed store, hash-verified

3000
3001// FIXME-OPT: Need a way to reuse the result of lower_bound when doing GetInt()/SetInt() - not too bad because it only happens on explicit interaction (maximum one a frame)
3002void ImGuiStorage::SetInt(ImGuiID key, int val)
3003{
3004 ImGuiStoragePair* it = ImLowerBound(Data.Data, Data.Data + Data.Size, key);
3005 if (it == Data.Data + Data.Size || it->key != key)
3006 Data.insert(it, ImGuiStoragePair(key, val));
3007 else
3008 it->val_i = val;
3009}
3010
3011void ImGuiStorage::SetBool(ImGuiID key, bool val)
3012{

Callers 6

AddRemapCharMethod · 0.45
TreeNodeSetOpenMethod · 0.45
TreeNodeBehaviorMethod · 0.45
RemoveMethod · 0.45

Calls 3

ImGuiStoragePairClass · 0.85
ImLowerBoundFunction · 0.70
insertMethod · 0.45

Tested by

no test coverage detected