diff --git a/src/ui/PlayerInterface.cpp b/src/ui/PlayerInterface.cpp index 8f18f99d5fd19d718501543bf4a9e0153635e412..f608afc8080fc19721a1136bb5d1c282c1b93dd6 100644 --- a/src/ui/PlayerInterface.cpp +++ b/src/ui/PlayerInterface.cpp @@ -32,7 +32,6 @@ PlayerInterface::PlayerInterface(WebInterface* app) interfaceLayout = new Wt::WVBoxLayout(); this->setLayout(interfaceLayout); playControlLayout = new Wt::WHBoxLayout(); - voteControlLayout = new Wt::WVBoxLayout(); playControlWidget = new Wt::WContainerWidget(); skipControls = new Wt::WContainerWidget(); playControlWidget->setLayout(playControlLayout); @@ -67,16 +66,15 @@ PlayerInterface::PlayerInterface(WebInterface* app) skipControls->addWidget(skipDeny); mainDisplay = new Wt::WTabWidget(); + requestPane = new RequestInterface(app); voteMetaContainer = new Wt::WContainerWidget(); voteMetaLayout = new Wt::WVBoxLayout(); voteMetaContainer->setLayout(voteMetaLayout); voteControlContainer = new Wt::WContainerWidget(); voteControlContainer->setMaximumSize(Wt::WLength(75,Wt::WLength::Percentage),Wt::WLength::Auto); - voteControlContainer->decorationStyle().setBackgroundColor(Wt::WColor("lightsteelblue")); - voteControlContainer->addStyleClass("panel"); - voteHeader = new Wt::WText("Upcoming Tracks To Vote On"); - voteHeader->addStyleClass("panel-heading"); + votePanel = new Wt::WPanel(); + votePanel->addStyleClass("panel-primary"); voteTracksContainer = new Wt::WContainerWidget(); voteTracksContainer->addStyleClass("panel-body"); voteTracksLayout = new Wt::WVBoxLayout(); @@ -124,6 +122,7 @@ PlayerInterface::PlayerInterface(WebInterface* app) interfaceLayout->addWidget(currentTrackProgress); interfaceLayout->addWidget(mainDisplay); mainDisplay->addTab(voteMetaContainer,"Up Next",Wt::WTabWidget::PreLoading); + mainDisplay->addTab(requestPane, "Make Request", Wt::WTabWidget::LazyLoading); playControlWidget->addStyleClass("panel"); playControlWidget->addStyleClass("panel-default"); playControlWidget->decorationStyle().setBackgroundColor(Wt::WColor("gainsboro")); @@ -131,9 +130,10 @@ PlayerInterface::PlayerInterface(WebInterface* app) playControlLayout->addWidget(playpause,0,Wt::AlignmentFlag::AlignLeft | Wt::AlignmentFlag::AlignMiddle); playControlLayout->addWidget(currentTrackDetails,0,Wt::AlignmentFlag::AlignCenter | Wt::AlignmentFlag::AlignMiddle); playControlLayout->addWidget(skipControls,0,Wt::AlignmentFlag::AlignRight | Wt::AlignmentFlag::AlignMiddle); - voteControlContainer->setLayout(voteControlLayout); - voteControlLayout->addWidget(voteHeader,0,Wt::AlignmentFlag::AlignCenter); - voteControlLayout->addWidget(voteTracksContainer); + votePanel->setTitle("Upcoming Tracks To Vote On"); + votePanel->decorationStyle().setBackgroundColor(Wt::WColor("lightsteelblue")); + voteControlContainer->addWidget(votePanel); + votePanel->setCentralWidget(voteTracksContainer); voteTracksContainer->setLayout(voteTracksLayout); voteTracksLayout->addLayout(track1); voteTracksLayout->addSpacing(Wt::WLength(20,Wt::WLength::Pixel)); diff --git a/src/ui/PlayerInterface.h b/src/ui/PlayerInterface.h index ab9e38685f1e572d11c9e2178a794e81d7e2e235..1f299ea6e422735ec4377108184c1be2a8c9954f 100644 --- a/src/ui/PlayerInterface.h +++ b/src/ui/PlayerInterface.h @@ -30,6 +30,8 @@ #include #include #include "TrackDetails.h" +#include "RequestInterface.h" +#include class PlayerInterface : public Wt::WContainerWidget { @@ -40,7 +42,6 @@ public: Wt::WVBoxLayout* interfaceLayout; Wt::WHBoxLayout* playControlLayout; Wt::WContainerWidget* playControlWidget; - Wt::WVBoxLayout* voteControlLayout; //Play controls TrackDetails* currentTrackDetails; @@ -55,13 +56,14 @@ public: //TabView Wt::WTabWidget* mainDisplay; + RequestInterface* requestPane; //Vote Controls Wt::WContainerWidget* voteMetaContainer; Wt::WVBoxLayout* voteMetaLayout; + Wt::WPanel* votePanel; Wt::WContainerWidget* voteControlContainer; Wt::WContainerWidget* voteTracksContainer; - Wt::WText* voteHeader; Wt::WVBoxLayout* voteTracksLayout; Wt::WHBoxLayout* track1; Wt::WHBoxLayout* track2; diff --git a/src/ui/RequestInterface.cpp b/src/ui/RequestInterface.cpp index 32638852a324bf047b881416b71a878c92afafd1..8856ffe1ffe7bacece2b9d6dde75317f24bb8df7 100644 --- a/src/ui/RequestInterface.cpp +++ b/src/ui/RequestInterface.cpp @@ -18,3 +18,9 @@ */ #include "RequestInterface.h" + +RequestInterface::RequestInterface(WebInterface* app) +{ + this->app = app; + //TODO +} diff --git a/src/ui/RequestInterface.h b/src/ui/RequestInterface.h index 8febc1b74701358c52e6f9c0491d883540358e2b..75ed664babfb34c9a4039f6b22a1d5963ba3eb79 100644 --- a/src/ui/RequestInterface.h +++ b/src/ui/RequestInterface.h @@ -28,6 +28,9 @@ class RequestInterface : public Wt::WContainerWidget public: RequestInterface(WebInterface* app); WebInterface* app; + + Wt::WContainerWidget* searchHeader; + Wt::WContainerWidget* resultBody; }; #endif // REQUESTINTERFACE_H