Fix merge bugs

This commit is contained in:
baydam
2015-12-24 19:17:10 +00:00
parent 5854c2f5a3
commit 61528b3701
+3 -8
View File
@@ -2734,7 +2734,7 @@ bool MainWindow::setTextureRate(int texture_id, double rate)
bool MainWindow::setTextureVolume(int texture_id, double volume)
{
Paint::ptr paint = this->mappingManager->getPaintById(texture_id);
if (paint.get() == NULL)
if (paint.isNull())
{
std::cout << "No such texture paint id " << texture_id << std::endl;
return false;
@@ -2743,7 +2743,7 @@ bool MainWindow::setTextureVolume(int texture_id, double volume)
{
if (paint->getType() == "media")
{
Media *media = (Media *) paint.get(); // FIXME: use sharedptr cast
Media *media = static_cast<Media*>(paint.data()); // FIXME: use sharedptr cast
videoTimer->stop();
media->setVolume(volume);
videoTimer->start();
@@ -2760,7 +2760,7 @@ bool MainWindow::setTextureVolume(int texture_id, double volume)
void MainWindow::setTexturePlayState(int texture_id, bool played)
{
Paint::ptr paint = this->mappingManager->getPaintById(texture_id);
if (paint.get() == NULL)
if (paint.isNull())
{
std::cout << "No such texture paint id " << texture_id << std::endl;
}
@@ -2788,8 +2788,3 @@ void MainWindow::setTexturePlayState(int texture_id, bool played)
}
}
}
void MainWindow::quitMapMap()
{
close();
}