From: Flavio Tordini Date: Mon, 3 Aug 2015 12:29:23 +0000 (+0200) Subject: Region action in status bar X-Git-Tag: 2.5~51 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=6daa479e7201325c3d18221408ce54a84d568703;p=minitube Region action in status bar --- diff --git a/src/standardfeedsview.cpp b/src/standardfeedsview.cpp index 7f62c32..94a5314 100644 --- a/src/standardfeedsview.cpp +++ b/src/standardfeedsview.cpp @@ -73,9 +73,9 @@ void StandardFeedsView::load() { addVideoSourceWidget(feed); YTRegion region = YTRegions::currentRegion(); - QToolButton *regionButton = MainWindow::instance()->getRegionButton(); - regionButton->setText(region.name); - regionButton->setIcon(YTRegions::iconForRegionId(region.id)); + QAction *regionAction = MainWindow::instance()->getRegionAction(); + regionAction->setText(region.name); + regionAction->setIcon(YTRegions::iconForRegionId(region.id)); } void StandardFeedsView::layoutCategories(const QList &categories) { @@ -131,12 +131,12 @@ void StandardFeedsView::appear() { load(); } QAction *regionAction = MainWindow::instance()->getRegionAction(); - regionAction->setVisible(true); + MainWindow::instance()->showActionInStatusBar(regionAction, true); } void StandardFeedsView::disappear() { QAction *regionAction = MainWindow::instance()->getRegionAction(); - regionAction->setVisible(false); + MainWindow::instance()->showActionInStatusBar(regionAction, false); } void StandardFeedsView::selectWorldwideRegion() { @@ -151,6 +151,5 @@ void StandardFeedsView::selectLocalRegion() { void StandardFeedsView::paintEvent(QPaintEvent *event) { QWidget::paintEvent(event); - // PainterUtils::topShadow(this); }