diff --git a/src/WebInterface.cpp b/src/WebInterface.cpp index ecbb734428e2fcf4f52a1de3c06b3f0fb3da04e1..4c807d40510f477e3d4f59f57324242a2dabcf6f 100644 --- a/src/WebInterface.cpp +++ b/src/WebInterface.cpp @@ -35,6 +35,7 @@ WebInterface::WebInterface(const Wt::WEnvironment& env) : Wt::WApplication(env) priv_int = new internal; this->useStyleSheet(Wt::WLink("/resources/font-awesome/css/font-awesome.min.css")); setTheme(new Wt::WBootstrapTheme()); + ((Wt::WBootstrapTheme*)theme())->setVersion(Wt::WBootstrapTheme::Version3); setTitle("Arbitrateor - Audio Jukebox"); enableUpdates(true); priv_int->playerUI = new PlayerInterface(this); diff --git a/src/ui/PlayerInterface.cpp b/src/ui/PlayerInterface.cpp index b04abe29d8255ff568cac7224ce3d24dc35977b3..8673f43fbfe68b99f9595ba9a4b1090d87fa1bc7 100644 --- a/src/ui/PlayerInterface.cpp +++ b/src/ui/PlayerInterface.cpp @@ -43,6 +43,7 @@ PlayerInterface::PlayerInterface(WebInterface* app) trackProgress->setInterval(1000); trackProgress->timeout().connect(this,&PlayerInterface::updateProgressFromTimer); currentTrackDetails = new TrackDetails(); + currentTrackDetails->setMinimumSize(Wt::WLength(100,Wt::WLength::Pixel),Wt::WLength(100,Wt::WLength::Pixel)); playpause = new Wt::WPushButton(); playpause->setTextFormat(Wt::XHTMLText); playpause->decorationStyle().font().setFamily(Wt::WFont::Default,"FontAwesome"); @@ -67,10 +68,11 @@ PlayerInterface::PlayerInterface(WebInterface* app) interfaceLayout->addWidget(playControlWidget); interfaceLayout->addWidget(currentTrackProgress); interfaceLayout->addLayout(voteControlLayout); - playControlWidget->decorationStyle().setBorder(Wt::WBorder::Outset); - playControlWidget->decorationStyle().setBackgroundColor(Wt::WColor("#00B200")); + playControlWidget->addStyleClass("panel"); + playControlWidget->addStyleClass("panel-default"); + playControlWidget->decorationStyle().setBackgroundColor(Wt::WColor("gainsboro")); playControlLayout->addWidget(playpause,0,Wt::AlignmentFlag::AlignLeft | Wt::AlignmentFlag::AlignMiddle); - playControlLayout->addWidget(currentTrackDetails); + playControlLayout->addWidget(currentTrackDetails,0,Wt::AlignmentFlag::AlignCenter | Wt::AlignmentFlag::AlignMiddle); playControlLayout->addWidget(skipControls,0,Wt::AlignmentFlag::AlignRight | Wt::AlignmentFlag::AlignMiddle); } @@ -170,4 +172,5 @@ void PlayerInterface::updateDetailsFromServer(AudioTrack track) updateSkipDeniedFromServer(); } currentTrackDetails->updateWithTrackDetails(track); + } diff --git a/src/ui/TrackDetails.cpp b/src/ui/TrackDetails.cpp index 6c25d0b56ded9dfb9d58699510e1ecc70139e9ee..86e14a02f28e3deb9efa456deb87027e8f7e24a9 100644 --- a/src/ui/TrackDetails.cpp +++ b/src/ui/TrackDetails.cpp @@ -24,8 +24,10 @@ TrackDetails::TrackDetails() { this->setMaximumSize(Wt::WLength::Auto,Wt::WLength(200, Wt::WLength::Pixel)); - this->decorationStyle().setBorder(Wt::WBorder::Ridge); + //this->decorationStyle().setBorder(Wt::WBorder::Ridge); this->decorationStyle().setBackgroundColor(Wt::WColor("#6FFF6F")); + this->addStyleClass("panel"); + this->addStyleClass("panel-default"); mainLayout = new Wt::WHBoxLayout(); this->setLayout(mainLayout); metaLayout = new Wt::WVBoxLayout(); @@ -33,6 +35,7 @@ TrackDetails::TrackDetails() albumCover = new Wt::WImage(); albumCover->setMinimumSize(Wt::WLength(75,Wt::WLength::Pixel),Wt::WLength(75,Wt::WLength::Pixel)); albumCover->setMaximumSize(Wt::WLength(200,Wt::WLength::Pixel),Wt::WLength(200,Wt::WLength::Pixel)); + albumCover->addStyleClass("img-rounded"); mainLayout->addWidget(albumCover); mainLayout->addSpacing(Wt::WLength(10, Wt::WLength::Pixel)); mainLayout->addLayout(metaLayout);