Add CANCEL to InputRequester

Got an idea for enhancing PureBasic? New command(s) you'd like to see?
User avatar
tikidays
User
User
Posts: 46
Joined: Tue Oct 24, 2023 6:47 am
Location: New Zealand
Contact:

Add CANCEL to InputRequester

Post by tikidays »

Can a #PB_InputRequester_Cancel option be added to the InputRequester?

Code: Select all

Text$ = InputRequester(Title$, Message$, DefaultText$ [, Flags [, ParendID]])
Quin
Addict
Addict
Posts: 1127
Joined: Thu Mar 31, 2022 7:03 pm
Location: Colorado, United States
Contact:

Re: Add CANCEL to InputRequester

Post by Quin »

Huge +1 on this. Also, a way to detect specifically escaping/canceling out of an input requester would be incredibly helpful, instead of just always giving a blank string :)
BarryG
Addict
Addict
Posts: 4128
Joined: Thu Apr 18, 2019 8:17 am

Re: Add CANCEL to InputRequester

Post by BarryG »

+1

This has been asked before, with one of the earliest 22 years ago:

https://www.purebasic.fr/english/viewtopic.php?p=6160

Other times:

https://www.purebasic.fr/english/viewtopic.php?p=362219
https://www.purebasic.fr/english/viewtopic.php?p=475585
https://www.purebasic.fr/english/viewto ... 17#p350917

I don't understand why it's been ignored for so long. How hard can it be? And returning an empty string is NOT the same thing as canceling, because sometimes you want the user to be able to specify an empty string (such as for an optional piece of text). So when canceling, it could return something that the user can't easily type, such as Chr(1), which is actually what I use for my own custom requester.
Post Reply