diff options
author | Jaakko Keränen <jaakko.keranen@iki.fi> | 2021-07-22 08:16:33 +0300 |
---|---|---|
committer | Jaakko Keränen <jaakko.keranen@iki.fi> | 2021-07-22 08:16:33 +0300 |
commit | 6a5bf6357269694294ff79845c46190f3ce2b53d (patch) | |
tree | 268c4ac696062fa774ab4c59c0abd25342d52302 /src/ui/inputwidget.c | |
parent | 7877d2adb715724593fc49c92d82b8e750e8b65c (diff) |
InputWidget: Showing the hint text
Diffstat (limited to 'src/ui/inputwidget.c')
-rw-r--r-- | src/ui/inputwidget.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/ui/inputwidget.c b/src/ui/inputwidget.c index 3a774b89..3a979b20 100644 --- a/src/ui/inputwidget.c +++ b/src/ui/inputwidget.c | |||
@@ -769,9 +769,12 @@ void setContentPadding_InputWidget(iInputWidget *d, int left, int right) { | |||
769 | refresh_Widget(d); | 769 | refresh_Widget(d); |
770 | } | 770 | } |
771 | 771 | ||
772 | iLocalDef iBool isEmpty_InputWidget_(const iInputWidget *d) { | ||
773 | return size_Array(&d->lines) == 1 && isEmpty_String(&line_InputWidget_(d, 0)->text); | ||
774 | } | ||
775 | |||
772 | static iBool isHintVisible_InputWidget_(const iInputWidget *d) { | 776 | static iBool isHintVisible_InputWidget_(const iInputWidget *d) { |
773 | return !isEmpty_String(&d->hint) && isEmpty_Array(&d->lines);/* size_Array(&d->lines) <= 1 && | 777 | return !isEmpty_String(&d->hint) && isEmpty_InputWidget_(d); |
774 | isEmpty_String(&line_InputWidget_(d, 0)->text);*/ | ||
775 | } | 778 | } |
776 | 779 | ||
777 | static void updateBuffered_InputWidget_(iInputWidget *d) { | 780 | static void updateBuffered_InputWidget_(iInputWidget *d) { |