diff options
author | Jaakko Keränen <jaakko.keranen@iki.fi> | 2021-08-01 20:37:00 +0300 |
---|---|---|
committer | Jaakko Keränen <jaakko.keranen@iki.fi> | 2021-08-01 20:37:00 +0300 |
commit | cdc63088603169874b1e98aaf4196cc252a1eee9 (patch) | |
tree | 18bb186068653865f4fd91bcb385b33a384c8a1f /src/ui/inputwidget.c | |
parent | 395cb3a996482c9e9fc27e00b4259219f85ec663 (diff) |
UploadWidget: Allow expanding to full window height
Diffstat (limited to 'src/ui/inputwidget.c')
-rw-r--r-- | src/ui/inputwidget.c | 17 |
1 files changed, 13 insertions, 4 deletions
diff --git a/src/ui/inputwidget.c b/src/ui/inputwidget.c index 2ca9bd55..6246078e 100644 --- a/src/ui/inputwidget.c +++ b/src/ui/inputwidget.c | |||
@@ -709,10 +709,19 @@ void setMaxLen_InputWidget(iInputWidget *d, size_t maxLen) { | |||
709 | } | 709 | } |
710 | 710 | ||
711 | void setLineLimits_InputWidget(iInputWidget *d, int minLines, int maxLines) { | 711 | void setLineLimits_InputWidget(iInputWidget *d, int minLines, int maxLines) { |
712 | d->minWrapLines = minLines; | 712 | if (d->minWrapLines != minLines || d->maxWrapLines != maxLines) { |
713 | d->maxWrapLines = maxLines; | 713 | d->minWrapLines = minLines; |
714 | updateVisible_InputWidget_(d); | 714 | d->maxWrapLines = maxLines; |
715 | updateMetrics_InputWidget_(d); | 715 | updateVisible_InputWidget_(d); |
716 | updateMetrics_InputWidget_(d); | ||
717 | } | ||
718 | } | ||
719 | |||
720 | int minLines_InputWidget(const iInputWidget *d) { | ||
721 | return d->minWrapLines; | ||
722 | } | ||
723 | int maxLines_InputWidget(const iInputWidget *d) { | ||
724 | return d->maxWrapLines; | ||
716 | } | 725 | } |
717 | 726 | ||
718 | void setValidator_InputWidget(iInputWidget *d, iInputWidgetValidatorFunc validator, void *context) { | 727 | void setValidator_InputWidget(iInputWidget *d, iInputWidgetValidatorFunc validator, void *context) { |