mirror of
https://github.com/obsproject/obs-studio.git
synced 2026-03-27 10:52:16 -04:00
frontend: Use OBSBasic::Get() in all places
This reduces duplicated code when getting the OBSBasic context.
This commit is contained in:
@@ -9,7 +9,7 @@
|
||||
|
||||
static inline OBSScene GetCurrentScene()
|
||||
{
|
||||
OBSBasic *main = reinterpret_cast<OBSBasic *>(App()->GetMainWindow());
|
||||
OBSBasic *main = OBSBasic::Get();
|
||||
return main->GetCurrentScene();
|
||||
}
|
||||
|
||||
@@ -560,7 +560,7 @@ bool SourceTree::GroupedItemsSelected() const
|
||||
|
||||
void SourceTree::Remove(OBSSceneItem item, OBSScene scene)
|
||||
{
|
||||
OBSBasic *main = reinterpret_cast<OBSBasic *>(App()->GetMainWindow());
|
||||
OBSBasic *main = OBSBasic::Get();
|
||||
GetStm()->Remove(item);
|
||||
main->SaveProject();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user