Sfoglia il codice sorgente

UI: Add new scene at current row

Instead of having a new scene at the bottom of the list, have
it added after the current item.
cg2121 3 anni fa
parent
commit
5e198db647
1 ha cambiato i file con 1 aggiunte e 1 eliminazioni
  1. 1 1
      UI/window-basic-main.cpp

+ 1 - 1
UI/window-basic-main.cpp

@@ -3130,7 +3130,7 @@ void OBSBasic::AddScene(OBSSource source)
 
 
 	QListWidgetItem *item = new QListWidgetItem(QT_UTF8(name));
 	QListWidgetItem *item = new QListWidgetItem(QT_UTF8(name));
 	SetOBSRef(item, OBSScene(scene));
 	SetOBSRef(item, OBSScene(scene));
-	ui->scenes->addItem(item);
+	ui->scenes->insertItem(ui->scenes->currentRow() + 1, item);
 
 
 	obs_hotkey_register_source(
 	obs_hotkey_register_source(
 		source, "OBSBasic.SelectScene",
 		source, "OBSBasic.SelectScene",