Platform/PlatformWindow: pass owner in constructor instead of setting the variable directly on the object. it is cleaner.
This commit is contained in:
parent
5a7a5e3f7c
commit
1288ef88b8
6 changed files with 14 additions and 10 deletions
|
|
@ -16,12 +16,11 @@ namespace sp {
|
|||
|
||||
PlatformWindow* PlatformWindow::make(Window* owner)
|
||||
{
|
||||
WindowType* disp = new WindowType();
|
||||
disp->m_owner = owner;
|
||||
return disp;
|
||||
return new WindowType(owner);
|
||||
}
|
||||
|
||||
PlatformWindow::PlatformWindow()
|
||||
PlatformWindow::PlatformWindow(Window* owner) :
|
||||
m_owner (owner)
|
||||
{
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue