mirror of
https://github.com/n00mkrad/flowframes.git
synced 2026-07-10 04:21:49 +02:00
Update AI Model ComboBox after fetching models.txt
This commit is contained in:
@@ -318,12 +318,19 @@ namespace Flowframes
|
||||
{
|
||||
if (string.IsNullOrWhiteSpace(aiCombox.Text) || aiCombox.Text == lastAiComboxStr) return;
|
||||
lastAiComboxStr = aiCombox.Text;
|
||||
aiModel = UIUtils.FillAiModelsCombox(aiModel, GetAi());
|
||||
UpdateAiModelCombox();
|
||||
|
||||
if(initialized)
|
||||
ConfigParser.SaveComboxIndex(aiCombox);
|
||||
|
||||
interpFactorCombox_SelectedIndexChanged(null, null);
|
||||
}
|
||||
|
||||
public void UpdateAiModelCombox ()
|
||||
{
|
||||
aiModel = UIUtils.FillAiModelsCombox(aiModel, GetAi());
|
||||
}
|
||||
|
||||
private void Form1_FormClosing(object sender, FormClosingEventArgs e)
|
||||
{
|
||||
Logger.Log("Closing main form.", true);
|
||||
|
||||
@@ -142,6 +142,7 @@ namespace Flowframes.OS
|
||||
string savePath = Path.Combine(Paths.GetPkgPath(), aiName, "models.txt");
|
||||
if(File.Exists(savePath)) File.Delete(savePath);
|
||||
client.DownloadFile(url, savePath);
|
||||
Program.mainForm.UpdateAiModelCombox();
|
||||
});
|
||||
}
|
||||
catch (Exception e)
|
||||
|
||||
Reference in New Issue
Block a user