Diffstat (limited to 'noncore/apps/opie-reader/ToolbarPrefs.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/apps/opie-reader/ToolbarPrefs.cpp | 76 |
1 files changed, 66 insertions, 10 deletions
diff --git a/noncore/apps/opie-reader/ToolbarPrefs.cpp b/noncore/apps/opie-reader/ToolbarPrefs.cpp index 0347736..5cf220a 100644 --- a/noncore/apps/opie-reader/ToolbarPrefs.cpp +++ b/noncore/apps/opie-reader/ToolbarPrefs.cpp @@ -7,12 +7,21 @@ ** WARNING! All changes made in this file will be lost! ****************************************************************************/ +#include "useqpe.h" #include "ToolbarPrefs.h" +#include <qcheckbox.h> +#include <qlabel.h> +#include <qpushbutton.h> +#include <qspinbox.h> #include <qlayout.h> +#include <qvariant.h> +#include <qtooltip.h> +#include <qwhatsthis.h> +#include <qcombobox.h> #include <qbuttongroup.h> +#include <qlineedit.h> #ifdef USEQPE #include <qpe/menubutton.h> #endif -#include <qpe/qpeapplication.h> CBarPrefs::CBarPrefs(const QString& appdir, bool fs, QWidget* parent, const char* name) : QDialog(parent, name, true), config( appdir ) @@ -35,6 +44,5 @@ CBarPrefs::CBarPrefs(const QString& appdir, bool fs, QWidget* parent, const char v->addWidget(td); - if (fs) - QPEApplication::showDialog( this ); + if (fs) showMaximized(); } @@ -122,4 +130,12 @@ CBarPrefs2::CBarPrefs2( Config& _config, QWidget* parent, const char* name, WFl fullscreen->setChecked(config.readBoolEntry( "Fullscreen", false )); connect(fullscreen, SIGNAL(stateChanged(int)), this, SLOT( isChanged(int) ) ); + rotate = new QCheckBox( tr("Rotate"), bg ); + rotate->setChecked(config.readBoolEntry( "Rotate", false )); + connect(rotate, SIGNAL(stateChanged(int)), this, SLOT( isChanged(int) ) ); + + invert = new QCheckBox( tr("Invert"), bg ); + invert->setChecked(config.readBoolEntry( "Invert Action", false )); + connect(invert, SIGNAL(stateChanged(int)), this, SLOT( isChanged(int) ) ); + zoom = new QCheckBox( tr("Zoom"), bg ); zoom->setChecked(config.readBoolEntry( "Zoom In/Out", false )); @@ -178,4 +194,6 @@ void CBarPrefs2::saveall() config.setGroup( "Toolbar" ); config.writeEntry( "Fullscreen", fullscreen->isChecked()); + config.writeEntry( "Rotate", rotate->isChecked()); + config.writeEntry( "Invert Action", invert->isChecked()); config.writeEntry( "Zoom In/Out", zoom->isChecked()); config.writeEntry( "Set Font", setfont->isChecked()); @@ -316,4 +334,12 @@ CViewBarPrefs::CViewBarPrefs( Config& _config, QWidget* parent, const char* nam fullscreen->setChecked(config.readBoolEntry( "Fullscreen", false )); connect(fullscreen, SIGNAL(stateChanged(int)), this, SLOT( isChanged(int) ) ); + rotate = new QCheckBox( tr("Rotate"), bg ); + rotate->setChecked(config.readBoolEntry( "Rotate", false )); + connect(rotate, SIGNAL(stateChanged(int)), this, SLOT( isChanged(int) ) ); + + invert = new QCheckBox( tr("Invert"), bg ); + invert->setChecked(config.readBoolEntry( "Invert Action", false )); + connect(invert, SIGNAL(stateChanged(int)), this, SLOT( isChanged(int) ) ); + zoomin = new QCheckBox( tr("Zoom In"), bg ); zoomin->setChecked(config.readBoolEntry( "Zoom In", false )); @@ -339,4 +365,6 @@ void CViewBarPrefs::saveall() config.setGroup( "Toolbar" ); config.writeEntry( "Fullscreen", fullscreen->isChecked()); + config.writeEntry( "Rotate", rotate->isChecked()); + config.writeEntry( "Invert Action", invert->isChecked()); config.writeEntry( "Zoom In", zoomin->isChecked()); config.writeEntry( "Zoom Out", zoomout->isChecked()); @@ -413,5 +441,5 @@ CMiscBarPrefs::CMiscBarPrefs( QWidget* parent, const char* name, WFlags fl ) { - QGridLayout* hl = new QGridLayout(this,1,2); + QGridLayout* hl = new QGridLayout(this,2,2); hl->setMargin( 0 ); @@ -420,9 +448,4 @@ CMiscBarPrefs::CMiscBarPrefs( QWidget* parent, const char* name, WFlags fl ) floating = new QCheckBox(gb); floating->setText(tr("Floating")); - -// QLabel* TextLabel = new QLabel( gb ); -// TextLabel->setText( tr( "Select Button" ) ); - - hl->addWidget( gb, 0, 0 ); @@ -440,7 +463,12 @@ CMiscBarPrefs::CMiscBarPrefs( QWidget* parent, const char* name, WFlags fl ) #endif tbpolicy->setSizePolicy(QSizePolicy(QSizePolicy::Fixed, QSizePolicy::Fixed)); +#ifdef USEQPE tbpolicy->insertItem(tr("Single bar")); tbpolicy->insertItem(tr("Menu/tool bar")); tbpolicy->insertItem(tr("Multiple bars")); +#else + tbpolicy->insertItem(tr("Single bar")); + tbpolicy->insertItem(tr("Multiple bars")); +#endif #ifdef USECOMBO @@ -456,8 +484,36 @@ CMiscBarPrefs::CMiscBarPrefs( QWidget* parent, const char* name, WFlags fl ) tbmovable = new QCheckBox( tr("Movable"), gb ); -// ch->setChecked(config.readBoolEntry( "Movable", false )); hl->addWidget(gb, 0, 1); + gb = new QGroupBox(1, Qt::Horizontal, "QT Scroll Bar", this); + +#ifdef USECOMBO + qtscroll = new QComboBox(gb); +#else + qtscroll = new MenuButton(gb); +#endif + qtscroll->insertItem(tr("None")); + qtscroll->insertItem(tr("Right")); + qtscroll->insertItem(tr("Left")); + + hl->addWidget(gb, 1, 0); + gb = new QGroupBox(1, Qt::Horizontal, "Miniscroll", this); + +#ifdef USECOMBO + localscroll = new QComboBox(gb); +#else + localscroll = new MenuButton(gb); +#endif + localscroll->insertItem(tr("None")); + localscroll->insertItem(tr("Bottom")); + localscroll->insertItem(tr("Right")); + localscroll->insertItem(tr("Left")); + + //scrollonleft = new QCheckBox( tr("... on Left"), gb ); + // ch->setChecked(config.readBoolEntry( "Movable", false )); + + hl->addWidget(gb, 1, 1); + } |