00001 /*************************************************************************** 00002 * * 00003 * This program is free software; you can redistribute it and/or modify * 00004 * it under the terms of the GNU General Public License as published by * 00005 * the Free Software Foundation; either version 2 of the License, or * 00006 * (at your option) any later version. * 00007 * * 00008 ***************************************************************************/ 00009 // Copyright (C) 2000 Trolltech AS. 00010 // adadpted form qpe/qipkg 00011 // (c) 2002 Patrick S. Vogt <tille@handhelds.org> 00012 00013 #ifndef MAINWINDOW_H 00014 #define MAINWINDOW_H 00015 00016 #include <qmainwindow.h> 00017 #include <qaction.h> 00018 #include <qtimer.h> 00019 #include <qpopupmenu.h> 00020 00021 #include "package.h" 00022 #include "packagelist.h" 00023 #include "packagelistremote.h" 00024 #include "packagelistlocal.h" 00025 #include "packagelistdoclnk.h" 00026 #include "pmipkg.h" 00027 #include "pksettings.h" 00028 #include "packagelistview.h" 00029 00030 class QComboBox; 00031 class QToolBar; 00032 class QLineEdit; 00033 class PackageListItem; 00034 class QCopChannel; 00035 class QMessageBox; 00036 class QCheckBox; 00037 00038 class MainWindow : public QMainWindow 00039 { 00040 Q_OBJECT 00041 00042 00043 public: 00044 MainWindow( QWidget *parent = 0, const char *name = 0, WFlags f = 0 ); 00045 ~MainWindow(); 00046 00047 QCopChannel *channel; 00048 00049 protected slots: 00050 void runIpkg(); 00051 void updateList(); 00052 void displayList(); 00053 void subSectionChanged(); 00054 void sectionChanged(); 00055 void showSettings(int); 00056 void showSettingsSetup(); 00057 void showSettingsSrv(); 00058 void showSettingsDst(); 00059 00060 public slots: 00061 void sectionClose(); 00062 void sectionShow(bool); 00063 void findClose(); 00064 void findShow(bool); 00065 void searchClose(); 00066 void searchShow(bool); 00067 void destClose(); 00068 void destShow(bool); 00069 void filterList(); 00070 void createLinks(); 00071 void removeLinks(); 00072 void receive (const QCString &, const QByteArray &); 00073 void setDocument (const QString &); 00074 void remotePackageQuery(); 00075 00076 private: 00077 void makeMenu(); 00078 void makeChannel(); 00079 void setSections(); 00080 void setSubSections(); 00081 bool updateIcon; 00082 00083 PmIpkg* ipkg; 00084 PackageManagerSettings *settings; 00085 PackageListLocal packageListServers; 00086 PackageListRemote packageListSearch; 00087 PackageListDocLnk packageListDocLnk; 00088 PackageListView *listViewPackages; 00089 QAction *runAction; 00090 QAction *updateAction; 00091 QAction *findAction; 00092 QToolBar *findBar; 00093 QLineEdit *findEdit; 00094 QAction *searchAction; 00095 QAction *searchCommit; 00096 QToolBar *searchBar; 00097 QLineEdit *searchEdit; 00098 QAction *sectionAction; 00099 QToolBar *sectionBar; 00100 QComboBox *section; 00101 QComboBox *subsection; 00102 QAction *destAction; 00103 QToolBar *destBar; 00104 QComboBox *destination; 00105 QCheckBox* CheckBoxLink; 00106 }; 00107 00108 #endif
1.4.2