Ticket #3494 (closed task: fixed)
Use INPUT_LAST_TEXT for input_dialog() instead of static vars
Reported by: | mooffie | Owned by: | |
---|---|---|---|
Priority: | trivial | Milestone: | 4.8.15 |
Component: | mcedit | Version: | master |
Keywords: | Cc: | ||
Blocked By: | Blocking: | ||
Branch state: | no branch | Votes for changeset: | committed-master |
Description
input_dialog() already supports showing the last input, by using INPUT_LAST_TEXT, so there's no reason to re-implement this feature.
(1) This patch fixes this for the "Run sort" dialog.
(2) It also fixes this for the two "Goto line" dialogs. But for these two we assume the user won't want to see the previous input when he first uses the dialog in the current session (because the line number of yesterday isn't very important today) so we use a static variable to detect "first run".
(3) The diff's "Goto line" command was invoked "incorrectly" by dview_goto_cmd (dview, TRUE) instead of dview_goto_cmd (dview, DIFF_RIGHT).
Attachments
Change History
Changed 9 years ago by mooffie
- Attachment 3494-Use-INPUT_LAST_TEXT-for-input_dialog-instead-of-stat.patch added
Note: See
TracTickets for help on using
tickets.
I see that I forgot to fix the "Mail" dialog. (I missed it because it was using the QUICK_LABELED_INPUT macro whereas previously I scanned only for calls to input_dialog().) I'll add it to the patch soon.