summaryrefslogtreecommitdiff
path: root/noncore/graphics/opie-eye/gui/viewmodebutton.cpp
Side-by-side diff
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.cpp24
1 files changed, 24 insertions, 0 deletions
diff --git a/noncore/graphics/opie-eye/gui/viewmodebutton.cpp b/noncore/graphics/opie-eye/gui/viewmodebutton.cpp
new file mode 100644
index 0000000..fdf4e77
--- a/dev/null
+++ b/noncore/graphics/opie-eye/gui/viewmodebutton.cpp
@@ -0,0 +1,24 @@
+#include "viewmodebutton.h"
+
+#include <qtoolbar.h>
+#include <qpopupmenu.h>
+
+ViewModeButton::ViewModeButton( QToolBar* bar )
+ : QToolButton( bar )
+{
+ setIconSet( Resource::loadIconSet( "toys" ) );
+ QPopupMenu *pop= new QPopupMenu( this );
+ pop->setCheckable( true );
+ pop->insertItem( tr("Thumbnail and Imageinfo"), 0 );
+ pop->insertItem( tr("Thumbnail and Name" ), 1 );
+ pop->insertItem( tr("Name Only" ), 2 );
+ connect(pop, SIGNAL(activated(int)),
+ this, SIGNAL(changeMode(int)) );
+
+
+ setPopup( pop );
+}
+
+ViewModeButton::~ViewModeButton() {
+
+}