summaryrefslogtreecommitdiffabout
path: root/korganizer
Unidiff
Diffstat (limited to 'korganizer') (more/less context) (ignore whitespace changes)
-rw-r--r--korganizer/calendarview.cpp4
-rw-r--r--korganizer/kofilterview.cpp2
-rw-r--r--korganizer/kofilterview.h50
3 files changed, 54 insertions, 2 deletions
diff --git a/korganizer/calendarview.cpp b/korganizer/calendarview.cpp
index ea100d1..8d992b9 100644
--- a/korganizer/calendarview.cpp
+++ b/korganizer/calendarview.cpp
@@ -470,8 +470,9 @@ void CalendarView::init()
470 leftFrameLayout->addWidget(mFilterView ); 470 leftFrameLayout->addWidget(mFilterView );
471 } 471 }
472#endif 472#endif
473 mFilterView->hide(); 473 mFilterView->hide();
474 mCalEditView->hide();
474 QWidget *rightBox = new QWidget( mMainFrame ); 475 QWidget *rightBox = new QWidget( mMainFrame );
475 //mainBoxLayout->addWidget ( rightBox, 10 ); 476 //mainBoxLayout->addWidget ( rightBox, 10 );
476 QBoxLayout *rightLayout = new QVBoxLayout( rightBox ); 477 QBoxLayout *rightLayout = new QVBoxLayout( rightBox );
477 mRightFrame = new QWidgetStack( rightBox ); 478 mRightFrame = new QWidgetStack( rightBox );
@@ -3908,11 +3909,12 @@ void CalendarView::selectFilter( int fil )
3908 mFilterView->setSelectedFilter( fil ); 3909 mFilterView->setSelectedFilter( fil );
3909} 3910}
3910void CalendarView::showFilter(bool visible) 3911void CalendarView::showFilter(bool visible)
3911{ 3912{
3913#if 0
3912 if (visible) mCalEditView->show(); 3914 if (visible) mCalEditView->show();
3913 else mCalEditView->hide(); 3915 else mCalEditView->hide();
3914#if 0 3916#else
3915 if (visible) mFilterView->show(); 3917 if (visible) mFilterView->show();
3916 else mFilterView->hide(); 3918 else mFilterView->hide();
3917#endif 3919#endif
3918} 3920}
diff --git a/korganizer/kofilterview.cpp b/korganizer/kofilterview.cpp
index 1bfe4dd..dc6237b 100644
--- a/korganizer/kofilterview.cpp
+++ b/korganizer/kofilterview.cpp
@@ -137,9 +137,9 @@ KOCalEditView::KOCalEditView(QWidget* parent,
137 addBut->setMaximumWidth( addBut->sizeHint().height() ); 137 addBut->setMaximumWidth( addBut->sizeHint().height() );
138 138
139 addBut = new QPushButton ( this ); 139 addBut = new QPushButton ( this );
140 mainLayout->addWidget( addBut,0,5 ); 140 mainLayout->addWidget( addBut,0,5 );
141 addBut->setPixmap ( SmallIcon("trash")); 141 addBut->setPixmap ( SmallIcon("minus"));
142 connect(addBut,SIGNAL(clicked()),SLOT(deleteAll())); 142 connect(addBut,SIGNAL(clicked()),SLOT(deleteAll()));
143 addBut->setMaximumWidth( addBut->sizeHint().height() ); 143 addBut->setMaximumWidth( addBut->sizeHint().height() );
144 144
145 145
diff --git a/korganizer/kofilterview.h b/korganizer/kofilterview.h
index d434c52..060108f 100644
--- a/korganizer/kofilterview.h
+++ b/korganizer/kofilterview.h
@@ -23,8 +23,10 @@
23#ifndef KOFILTERVIEW_H 23#ifndef KOFILTERVIEW_H
24#define KOFILTERVIEW_H 24#define KOFILTERVIEW_H
25 25
26#include <qstring.h> 26#include <qstring.h>
27#include <qcheckbox.h>
28#include <qpushbutton.h>
27#include <kconfig.h> 29#include <kconfig.h>
28#include "kofilterview_base.h" 30#include "kofilterview_base.h"
29 31
30#include <libkcal/calfilter.h> 32#include <libkcal/calfilter.h>
@@ -77,7 +79,55 @@ class KOCalEditView : public QWidget
77 79
78 private: 80 private:
79}; 81};
80 82
83class KOCalButton : public QPushButton
84{
85 Q_OBJECT
86 public:
87 KOCalButton( QWidget *parent=0, const char *name=0 ) :
88 QPushButton( parent, name)
89 {
90 connect( this, SIGNAL( clicked() ),
91 SLOT( bottonClicked() ));
92 mNumber = -1;
93 }
94 void setNum ( int num ) {mNumber = num; }
95 signals:
96 void selectNum ( int );
97private:
98 int mNumber;
99 void keyPressEvent ( QKeyEvent * e )
100 {
101 e->ignore();
102 }
103
104private slots :
105 void bottonClicked() { if ( mNumber > 0 ) emit selectNum ( mNumber ); }
106};
107class KOCalCheckButton : public QCheckBox
108{
109 Q_OBJECT
110 public:
111 KOCalCheckButton( QWidget *parent=0, const char *name=0 ) :
112 QCheckBox( parent, name)
113 {
114 connect( this, SIGNAL( toggled ( bool ) ),
115 SLOT( bottonClicked( bool ) ));
116 mNumber = -1;
117 }
118 void setNum ( int num ) {mNumber = num; }
119 signals:
120 void selectNum ( int, bool );
121private:
122 int mNumber;
123 void keyPressEvent ( QKeyEvent * e )
124 {
125 e->ignore();
126 }
127
128private slots :
129 void bottonClicked( bool b) { if ( mNumber > 0 ) emit selectNum ( mNumber , b); }
130};
81 131
82 132
83#endif // KOFILTERVIEW_H 133#endif // KOFILTERVIEW_H