mirror of
https://github.com/ocornut/imgui.git
synced 2026-01-20 01:34:20 +00:00
Misc tidying up (zero-clear structures, more unused default in ClipRetFullscreen, NavApplyItemToResult() coding style fix)
Zero-clearing more structures Remove arbitrary default ClipRetFullscreen value in ImDrawListSharedData. Nav extracted NavApplyItemToResult() function. Coding style fixes in OSX Backends.
This commit is contained in:
parent
046057cebb
commit
5f97809cab
6 changed files with 62 additions and 75 deletions
|
|
@ -344,21 +344,12 @@ void ImGui::StyleColorsLight(ImGuiStyle* dst)
|
|||
|
||||
ImDrawListSharedData::ImDrawListSharedData()
|
||||
{
|
||||
Font = NULL;
|
||||
FontSize = 0.0f;
|
||||
CurveTessellationTol = 0.0f;
|
||||
CircleSegmentMaxError = 0.0f;
|
||||
ClipRectFullscreen = ImVec4(-8192.0f, -8192.0f, +8192.0f, +8192.0f);
|
||||
InitialFlags = ImDrawListFlags_None;
|
||||
|
||||
// Lookup tables
|
||||
memset(this, 0, sizeof(*this));
|
||||
for (int i = 0; i < IM_ARRAYSIZE(ArcFastVtx); i++)
|
||||
{
|
||||
const float a = ((float)i * 2 * IM_PI) / (float)IM_ARRAYSIZE(ArcFastVtx);
|
||||
ArcFastVtx[i] = ImVec2(ImCos(a), ImSin(a));
|
||||
}
|
||||
memset(CircleSegmentCounts, 0, sizeof(CircleSegmentCounts)); // This will be set by SetCircleSegmentMaxError()
|
||||
TexUvLines = NULL;
|
||||
}
|
||||
|
||||
void ImDrawListSharedData::SetCircleSegmentMaxError(float max_error)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue