Correctly toggle the playlist open button

This commit is contained in:
Tobias Rundstrom 2006-03-04 22:29:11 -03:00
parent 651558d6c4
commit 0498d4d44a
2 changed files with 7 additions and 1 deletions

View file

@ -4,6 +4,7 @@
#include "TextBar.h" #include "TextBar.h"
#include <QFileDialog> #include <QFileDialog>
#include <QSettings>
MainDisplay::MainDisplay (QWidget *parent) : SkinDisplay(parent) MainDisplay::MainDisplay (QWidget *parent) : SkinDisplay(parent)
{ {
@ -117,9 +118,14 @@ MainDisplay::setMediainfo (QHash<QString, QString> h)
void void
MainDisplay::SetupToggleButtons (void) MainDisplay::SetupToggleButtons (void)
{ {
QSettings s;
m_pls = new ToggleButton (this, Skin::PLS_ON_0, Skin::PLS_ON_1, m_pls = new ToggleButton (this, Skin::PLS_ON_0, Skin::PLS_ON_1,
Skin::PLS_OFF_0, Skin::PLS_OFF_1); Skin::PLS_OFF_0, Skin::PLS_OFF_1);
m_pls->move(242, 58); m_pls->move(242, 58);
if (!s.value ("playlist/hidden").toBool ())
m_pls->toggleOn ();
connect (m_pls, SIGNAL(clicked()), window(), SLOT(togglePL())); connect (m_pls, SIGNAL(clicked()), window(), SLOT(togglePL()));
m_eq = new ToggleButton (this, Skin::EQ_ON_0, Skin::EQ_ON_1, m_eq = new ToggleButton (this, Skin::EQ_ON_0, Skin::EQ_ON_1,

View file

@ -90,7 +90,7 @@ PlaylistWindow::PlaylistWindow (QWidget *parent) : QMainWindow (parent)
s.beginGroup ("playlist"); s.beginGroup ("playlist");
if (!s.contains ("size")) { if (!s.contains ("size")) {
s.setValue ("size", QSize (280, 350)); s.setValue ("size", QSize (275, 350));
} }
resize (s.value("size").toSize ()); resize (s.value("size").toSize ());