summaryrefslogtreecommitdiff
path: root/library/fileselector.cpp
Unidiff
Diffstat (limited to 'library/fileselector.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--library/fileselector.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/library/fileselector.cpp b/library/fileselector.cpp
index 7ff09b4..052a29e 100644
--- a/library/fileselector.cpp
+++ b/library/fileselector.cpp
@@ -1,90 +1,90 @@
1/********************************************************************** 1/**********************************************************************
2** Copyright (C) 2000-2002 Trolltech AS. All rights reserved. 2** Copyright (C) 2000-2002 Trolltech AS. All rights reserved.
3** 3**
4** This file is part of the Qtopia Environment. 4** This file is part of the Qtopia Environment.
5** 5**
6** This file may be distributed and/or modified under the terms of the 6** This file may be distributed and/or modified under the terms of the
7** GNU General Public License version 2 as published by the Free Software 7** GNU General Public License version 2 as published by the Free Software
8** Foundation and appearing in the file LICENSE.GPL included in the 8** Foundation and appearing in the file LICENSE.GPL included in the
9** packaging of this file. 9** packaging of this file.
10** 10**
11** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE 11** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
12** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. 12** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
13** 13**
14** See http://www.trolltech.com/gpl/ for GPL licensing information. 14** See http://www.trolltech.com/gpl/ for GPL licensing information.
15** 15**
16** Contact info@trolltech.com if any conditions of this licensing are 16** Contact info@trolltech.com if any conditions of this licensing are
17** not clear to you. 17** not clear to you.
18** 18**
19**********************************************************************/ 19**********************************************************************/
20 20
21// WARNING: Do *NOT* define this yourself. The SL5xxx from SHARP does NOT 21// WARNING: Do *NOT* define this yourself. The SL5xxx from SHARP does NOT
22// have this class. 22// have this class.
23#define QTOPIA_INTERNAL_FSLP 23#define QTOPIA_INTERNAL_FSLP
24 24
25#include "fileselector.h" 25#include "fileselector.h"
26#include "fileselector_p.h" 26#include "fileselector_p.h"
27#include "global.h" 27#include "global.h"
28#include "resource.h" 28#include "resource.h"
29#include "config.h" 29#include "config.h"
30#include "applnk.h" 30#include "applnk.h"
31#include "storage.h" 31#include "storage.h"
32#include "qpemenubar.h" 32#include "qpemenubar.h"
33#ifdef QWS 33#ifdef QWS
34#include "qcopchannel_qws.h" 34#include <qcopchannel_qws.h>
35#endif 35#endif
36#include "lnkproperties.h" 36#include "lnkproperties.h"
37#include "applnk.h" 37#include "applnk.h"
38#include "qpeapplication.h" 38#include <qpe/qpeapplication.h>
39#include "categorymenu.h" 39#include "categorymenu.h"
40#include "categoryselect.h" 40#include "categoryselect.h"
41#include "mimetype.h" 41#include "mimetype.h"
42#include "categories.h" 42#include <qpe/categories.h>
43 43
44#include <stdlib.h> 44#include <stdlib.h>
45 45
46#include <qdir.h> 46#include <qdir.h>
47#include <qwidget.h> 47#include <qwidget.h>
48#include <qpopupmenu.h> 48#include <qpopupmenu.h>
49#include <qtoolbutton.h> 49#include <qtoolbutton.h>
50#include <qpushbutton.h> 50#include <qpushbutton.h>
51#include <qheader.h> 51#include <qheader.h>
52#include <qtooltip.h> 52#include <qtooltip.h>
53#include <qwhatsthis.h> 53#include <qwhatsthis.h>
54 54
55class TypeCombo : public QComboBox 55class TypeCombo : public QComboBox
56{ 56{
57 Q_OBJECT 57 Q_OBJECT
58public: 58public:
59 TypeCombo( QWidget *parent, const char *name=0 ) 59 TypeCombo( QWidget *parent, const char *name=0 )
60 : QComboBox( parent, name ) 60 : QComboBox( parent, name )
61 { 61 {
62 connect( this, SIGNAL(activated(int)), this, SLOT(selectType(int)) ); 62 connect( this, SIGNAL(activated(int)), this, SLOT(selectType(int)) );
63 } 63 }
64 64
65 void reread( DocLnkSet &files, const QString &filter ); 65 void reread( DocLnkSet &files, const QString &filter );
66 66
67signals: 67signals:
68 void selected( const QString & ); 68 void selected( const QString & );
69 69
70protected slots: 70protected slots:
71 void selectType( int idx ) { 71 void selectType( int idx ) {
72 emit selected( typelist[idx] ); 72 emit selected( typelist[idx] );
73 } 73 }
74 74
75protected: 75protected:
76 QStringList typelist; 76 QStringList typelist;
77 QString prev; 77 QString prev;
78}; 78};
79 79
80void TypeCombo::reread( DocLnkSet &files, const QString &filter ) 80void TypeCombo::reread( DocLnkSet &files, const QString &filter )
81{ 81{
82 typelist.clear(); 82 typelist.clear();
83 QStringList filters = QStringList::split( ';', filter ); 83 QStringList filters = QStringList::split( ';', filter );
84 int pos = filter.find( '/' ); 84 int pos = filter.find( '/' );
85 //### do for each filter 85 //### do for each filter
86 if ( filters.count() == 1 && pos >= 0 && filter[pos+1] != '*' ) { 86 if ( filters.count() == 1 && pos >= 0 && filter[pos+1] != '*' ) {
87 typelist.append( filter ); 87 typelist.append( filter );
88 clear(); 88 clear();
89 QString minor = filter.mid( pos+1 ); 89 QString minor = filter.mid( pos+1 );
90 minor[0] = minor[0].upper(); 90 minor[0] = minor[0].upper();