Minor bits.

This commit is contained in:
ocornut 2016-07-16 10:46:51 +02:00
parent bbd3b75609
commit 91e1c56da6
3 changed files with 3 additions and 5 deletions

View File

@ -4488,10 +4488,8 @@ void ImGui::FocusWindow(ImGuiWindow* window)
{
ImGuiContext& g = *GImGui;
// Always mark the window we passed as focused. This is used for keyboard interactions such as tabbing.
g.FocusedWindow = window;
// Passing NULL allow to disable keyboard focus
g.FocusedWindow = window;
if (!window)
return;

View File

@ -784,7 +784,7 @@ void ImGui::ShowTestWindow(bool* p_open)
struct Funcs
{
static float Sin(void*, int i) { return sinf(i * 0.1f); }
static float Saw(void*, int i) { return (i & 1) ? 1.0f : 0.0f; }
static float Saw(void*, int i) { return (i & 1) ? 1.0f : -1.0f; }
};
static int func_type = 0, display_count = 70;
ImGui::Separator();

View File

@ -482,7 +482,7 @@ struct ImGuiContext
DragCurrentValue = 0.0f;
DragLastMouseDelta = ImVec2(0.0f, 0.0f);
DragSpeedDefaultRatio = 1.0f / 100.0f;
DragSpeedScaleSlow = 0.01f;
DragSpeedScaleSlow = 1.0f / 100.0f;
DragSpeedScaleFast = 10.0f;
ScrollbarClickDeltaToGrabCenter = ImVec2(0.0f, 0.0f);
memset(Tooltip, 0, sizeof(Tooltip));