vrplayer: change to get screen position

This commit is contained in:
Jay Sorg 2013-01-13 20:13:27 -08:00
parent b2c242f50e
commit 13327df86f

View File

@ -175,15 +175,21 @@ void MainWindow::openMediaFile()
void MainWindow::getVdoGeometry(QRect *rect) void MainWindow::getVdoGeometry(QRect *rect)
{ {
int x = geometry().x() + lblVideo->geometry().x(); int x;
int y;
int y = pos().y() + lblVideo->geometry().y() + int width;
ui->mainToolBar->geometry().height() * 4 + 10; int height;
QPoint pt;
pt = lblVideo->mapToGlobal(QPoint(0, 0));
x = pt.x();
y = pt.y();
width = lblVideo->width();
height = lblVideo->height();
rect->setX(x); rect->setX(x);
rect->setY(y); rect->setY(y);
rect->setWidth(lblVideo->geometry().width()); rect->setWidth(width);
rect->setHeight(lblVideo->geometry().height()); rect->setHeight(height);
} }
void MainWindow::clearDisplay() void MainWindow::clearDisplay()