defuze.me  Client
mainplayerwidget.cpp
00001 /**************************************************************************
00002 ** defuze.me Epitech Innovative Project
00003 **
00004 ** Copyright 2010-2011
00005 **   Athena Calmettes - Jocelyn De La Rosa - Francois Gaillard
00006 **   Adrien Jarthon - Alexandre Moore - Luc Peres - Arnaud Sellier
00007 **
00008 ** All rights reserved.
00009 **************************************************************************/
00010 
00011 #include "mainplayerwidget.hpp"
00012 #include "mainplayer.hpp"
00013 
00014 using namespace Player;
00015 
00016 MainPlayerWidget::MainPlayerWidget(MainPlayer *player, QWidget *parent) :
00017     Gui::ModuleWidget(parent)
00018 {
00019     setupUi(this);
00020 
00021     nextButton->setIcon(this->style()->standardIcon(QStyle::SP_MediaSkipForward));
00022     labelB->setRight();
00023     labelA->setCurrent();
00024     labelB->setNext();
00025     player->setPlayers(playerA, playerB);
00026 }
00027 
00028 
00029 void Player::MainPlayerWidget::on_nextButton_clicked()
00030 {
00031     emit nextButton_clicked();
00032 }
00033 
00034 void MainPlayerWidget::setNextButtonIcon(const QIcon &icon)
00035 {
00036     nextButton->setIcon(icon);
00037 }
00038 
00039 void MainPlayerWidget::setACurrent()
00040 {
00041     labelA->setCurrent();
00042 }
00043 
00044 void MainPlayerWidget::setBCurrent()
00045 {
00046     labelB->setCurrent();
00047 }
00048 void MainPlayerWidget::setANext()
00049 {
00050     labelA->setNext();
00051 }
00052 void MainPlayerWidget::setBNext()
00053 {
00054     labelB->setNext();
00055 }