From 71f3f34782aa6050ede4bf143fa6028653adae6d Mon Sep 17 00:00:00 2001 From: Jaakko Keränen Date: Fri, 5 Mar 2021 13:14:02 +0200 Subject: Restructuring dialogs for mobile On a phone, dialogs are restructured to be more vertical and full-width. --- src/ui/inputwidget.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src/ui/inputwidget.c') diff --git a/src/ui/inputwidget.c b/src/ui/inputwidget.c index 4b5cd623..11ea0674 100644 --- a/src/ui/inputwidget.c +++ b/src/ui/inputwidget.c @@ -193,7 +193,10 @@ void setMode_InputWidget(iInputWidget *d, enum iInputMode mode) { } const iString *text_InputWidget(const iInputWidget *d) { - return collect_String(newUnicodeN_String(constData_Array(&d->text), size_Array(&d->text))); + if (d) { + return collect_String(newUnicodeN_String(constData_Array(&d->text), size_Array(&d->text))); + } + return collectNew_String(); } void setMaxLen_InputWidget(iInputWidget *d, size_t maxLen) { -- cgit v1.2.3