summaryrefslogtreecommitdiff
path: root/noncore/graphics/opie-eye/gui/viewmodebutton.cpp
Unidiff
Diffstat (limited to 'noncore/graphics/opie-eye/gui/viewmodebutton.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/graphics/opie-eye/gui/viewmodebutton.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/noncore/graphics/opie-eye/gui/viewmodebutton.cpp b/noncore/graphics/opie-eye/gui/viewmodebutton.cpp
index 0e4a7cb..36e5dcf 100644
--- a/noncore/graphics/opie-eye/gui/viewmodebutton.cpp
+++ b/noncore/graphics/opie-eye/gui/viewmodebutton.cpp
@@ -1,35 +1,35 @@
1#include "viewmodebutton.h" 1#include "viewmodebutton.h"
2 2
3#include <opie2/odebug.h> 3#include <opie2/odebug.h>
4 4
5#include <qtoolbar.h> 5#include <qtoolbar.h>
6#include <qpopupmenu.h> 6#include <qpopupmenu.h>
7 7
8ViewModeButton::ViewModeButton( QToolBar* bar ) 8ViewModeButton::ViewModeButton( QToolBar* bar,int def )
9 : QToolButton( bar ) 9 : QToolButton( bar )
10{ 10{
11 slotChange( 1 ); 11 slotChange( def );
12 QPopupMenu *pop= new QPopupMenu( this ); 12 QPopupMenu *pop= new QPopupMenu( this );
13 pop->setCheckable( true ); 13 pop->setCheckable( true );
14 pop->insertItem( tr("Thumbnail and Imageinfo"), 1 ); 14 pop->insertItem( tr("Thumbnail and Imageinfo"), 1 );
15 pop->insertItem( tr("Thumbnail and Name" ), 2 ); 15 pop->insertItem( tr("Thumbnail and Name" ), 2 );
16 pop->insertItem( tr("Name Only" ), 3 ); 16 pop->insertItem( tr("Name Only" ), 3 );
17 connect(pop, SIGNAL(activated(int)), 17 connect(pop, SIGNAL(activated(int)),
18 this, SIGNAL(changeMode(int)) ); 18 this, SIGNAL(changeMode(int)) );
19 connect(pop, SIGNAL(activated(int)), 19 connect(pop, SIGNAL(activated(int)),
20 this, SLOT(slotChange(int)) ); 20 this, SLOT(slotChange(int)) );
21 21
22 22
23 setPopup( pop ); 23 setPopup( pop );
24} 24}
25 25
26ViewModeButton::~ViewModeButton() { 26ViewModeButton::~ViewModeButton() {
27} 27}
28 28
29void ViewModeButton::slotChange( int i ) { 29void ViewModeButton::slotChange( int i ) {
30 QString name; 30 QString name;
31 switch( i ) { 31 switch( i ) {
32 case 1: 32 case 1:
33 name = "opie-eye/opie-eye-thumb"; 33 name = "opie-eye/opie-eye-thumb";
34 break; 34 break;
35 case 2: 35 case 2: