Commit bb233086 authored by Ken Martin's avatar Ken Martin
Browse files

added a set position method

parent 20fc8622
......@@ -92,6 +92,11 @@ public:
// Get the position in screen coordinates of the rendering window.
virtual int *GetPosition() = 0;
// Description:
// Set the position of the window in screen coordinates.
virtual void SetPosition(int,int);
virtual void SetPosition(int a[2]);
// Description:
// Get the size of the window in screen coordinates.
virtual int *GetSize() = 0;
......
......@@ -459,6 +459,28 @@ void vlRenderWindow::SetSize(int a[2])
this->SetSize(a[0],a[1]);
}
// Description:
// Set the size of the window in screen coordinates.
void vlRenderWindow::SetPosition(int a[2])
{
this->SetPosition(a[0],a[1]);
}
// Description:
// Set the size of the window in screen coordinates.
void vlRenderWindow::SetPosition(int x, int y)
{
// if we arent mappen then just set the ivars
if (!this->Mapped)
{
if ((this->Position[0] != x)||(this->Position[1] != y))
{
this->Modified();
}
this->Position[0] = x;
this->Position[1] = y;
}
}
void vlRenderWindow::PrintSelf(ostream& os, vlIndent indent)
{
int *temp;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment