forked from AuroraMiddleware/gtk
EntryBuffer: Don't generate changed events when input is truncated
This commit is contained in:
parent
16e23bebe3
commit
4d1c0317cc
@ -661,6 +661,9 @@ gtk_entry_buffer_insert_text (GtkEntryBuffer *buffer,
|
|||||||
n_chars -= (length + n_chars) - pv->max_length;
|
n_chars -= (length + n_chars) - pv->max_length;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (n_chars == 0)
|
||||||
|
return 0;
|
||||||
|
|
||||||
klass = GTK_ENTRY_BUFFER_GET_CLASS (buffer);
|
klass = GTK_ENTRY_BUFFER_GET_CLASS (buffer);
|
||||||
g_return_val_if_fail (klass->insert_text != NULL, 0);
|
g_return_val_if_fail (klass->insert_text != NULL, 0);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user