Skip to content

Commit

Permalink
Do not use hard-coded doubl-click-time, request it from settings.
Browse files Browse the repository at this point in the history
  • Loading branch information
TurboGit committed Oct 2, 2024
1 parent e1006d0 commit 638121c
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion src/dtgtk/thumbtable.c
Original file line number Diff line number Diff line change
Expand Up @@ -1572,8 +1572,16 @@ static gboolean _event_button_release(GtkWidget *widget,
}
else
{
GtkSettings *settings = gtk_widget_get_settings(GTK_WIDGET (widget));
guint double_click_time = 400;

if(settings)
{
g_object_get(settings, "gtk-double-click-time", &double_click_time, NULL);
}

table->to_selid = id;
table->sel_single_cb = g_timeout_add(300, _do_select_single, table);
table->sel_single_cb = g_timeout_add(double_click_time, _do_select_single, table);
}
}
}
Expand Down

0 comments on commit 638121c

Please sign in to comment.