UI: Add function to get main window more easily
Adds OBSBasic::Get() to just quickly return the main window.
This commit is contained in:
parent
a0eab1a2ad
commit
b89c2b76d3
@ -6857,3 +6857,8 @@ void OBSBasic::ResizeOutputSizeOfSource()
|
||||
ResetVideo();
|
||||
on_actionFitToScreen_triggered();
|
||||
}
|
||||
|
||||
OBSBasic *OBSBasic::Get()
|
||||
{
|
||||
return reinterpret_cast<OBSBasic*>(App()->GetMainWindow());
|
||||
}
|
||||
|
@ -617,6 +617,8 @@ public:
|
||||
void CreatePropertiesWindow(obs_source_t *source);
|
||||
void CreateFiltersWindow(obs_source_t *source);
|
||||
|
||||
static OBSBasic *Get();
|
||||
|
||||
protected:
|
||||
virtual void closeEvent(QCloseEvent *event) override;
|
||||
virtual void changeEvent(QEvent *event) override;
|
||||
|
Loading…
x
Reference in New Issue
Block a user