[GH-ISSUE #260] The dropdown doesn't call the selected function when programatically selecting an option #199

Closed
opened 2026-03-04 01:02:55 +03:00 by kerem · 0 comments
Owner

Originally created by @urandom on GitHub (Apr 4, 2019).
Original GitHub issue: https://github.com/rivo/tview/issues/260

Hi,
The dropdown currently only calls the selected function when a user interacts with a dropdown. When calling the SetCurrentOption method to programatically select an option, that function is ignored. This effectively leads to code duplication as it is necessary to mimic that functionality right after calling SetCurrentOption. I've prepared a simple change to address this: https://github.com/rivo/tview/pull/256

Originally created by @urandom on GitHub (Apr 4, 2019). Original GitHub issue: https://github.com/rivo/tview/issues/260 Hi, The dropdown currently only calls the selected function when a user interacts with a dropdown. When calling the SetCurrentOption method to programatically select an option, that function is ignored. This effectively leads to code duplication as it is necessary to mimic that functionality right after calling SetCurrentOption. I've prepared a simple change to address this: https://github.com/rivo/tview/pull/256
kerem closed this issue 2026-03-04 01:02:56 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/tview#199
No description provided.