提交 b4f34568 编写于 作者: J jp9000

UI: Allow copying/pasting of groups

Allows copying and pasting of groups.  The user can fully duplicate the
group, or create a reference of the group.  The user cannot paste a
reference of the group if it already exists within the same scene
however.
上级 5dfab20a
......@@ -6106,8 +6106,6 @@ void OBSBasic::on_actionCopySource_triggered()
OBSSceneItem item = GetCurrentSceneItem();
if (!item)
return;
if (!!obs_sceneitem_is_group(item))
return;
on_actionCopyTransform_triggered();
......@@ -6127,6 +6125,11 @@ void OBSBasic::on_actionCopySource_triggered()
void OBSBasic::on_actionPasteRef_triggered()
{
/* do not allow duplicate refs of the same group in the same scene */
OBSScene scene = GetCurrentScene();
if (!!obs_scene_get_group(scene, copyString))
return;
OBSBasicSourceSelect::SourcePaste(copyString, copyVisible, false);
on_actionPasteTransform_triggered();
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册