mirror of
https://github.com/chylex/TweetDuck.git
synced 2025-05-05 02:34:07 +02:00
Fix combo box issues (closing while opening, minor browser selection bug)
This commit is contained in:
parent
296d0c6199
commit
aa7a29af0c
Core/Other
@ -156,6 +156,10 @@ private void SelectTab(SettingsTab tab){
|
||||
}
|
||||
|
||||
private void control_MouseLeave(object sender, EventArgs e){
|
||||
if (sender is ComboBox cb && cb.DroppedDown){
|
||||
return; // prevents comboboxes from closing when MouseLeave event triggers during opening animation
|
||||
}
|
||||
|
||||
panelContents.Focus();
|
||||
}
|
||||
|
||||
|
@ -135,12 +135,11 @@ private void comboBoxBrowserPath_SelectedIndexChanged(object sender, EventArgs e
|
||||
if (dialog.ShowDialog() == DialogResult.OK){
|
||||
Config.BrowserPath = dialog.FileName;
|
||||
}
|
||||
else{
|
||||
comboBoxBrowserPath.SelectedIndexChanged -= comboBoxBrowserPath_SelectedIndexChanged;
|
||||
UpdateBrowserPathSelection();
|
||||
comboBoxBrowserPath.SelectedIndexChanged += comboBoxBrowserPath_SelectedIndexChanged;
|
||||
}
|
||||
}
|
||||
|
||||
comboBoxBrowserPath.SelectedIndexChanged -= comboBoxBrowserPath_SelectedIndexChanged;
|
||||
UpdateBrowserPathSelection();
|
||||
comboBoxBrowserPath.SelectedIndexChanged += comboBoxBrowserPath_SelectedIndexChanged;
|
||||
}
|
||||
else{
|
||||
Config.BrowserPath = (comboBoxBrowserPath.SelectedItem as WindowsUtils.Browser)?.Path; // default browser item is a string and casts to null
|
||||
|
Loading…
Reference in New Issue
Block a user