source: src-qt4/pc-softwaremanager/mainUI.h @ 867747a

9.2-releasereleng/10.0releng/10.0.1releng/10.0.2releng/10.0.3releng/10.1
Last change on this file since 867747a was 867747a, checked in by Ken Moore <ken@…>, 17 months ago

Clean up the Appcafe error dialog. Just use the built in Qmessagebox functionality for displaying detailed (but optional) info instead of the custom class I wrote before.

  • Property mode set to 100644
File size: 3.1 KB
Line 
1#ifndef _APPCAFE_MAINUI_H
2#define _APPCAFE_MAINUI_H
3
4
5#ifndef PREFIX
6#define PREFIX QString("/usr/local")
7#endif
8
9/* QT4 */
10#include <QDebug>
11#include <QDialog>
12#include <QMenu>
13#include <QMainWindow>
14#include <QMessageBox>
15#include <QTimer>
16#include <QHBoxLayout>
17#include <QVBoxLayout>
18#include <QTreeWidgetItem>
19#include <QScrollArea>
20#include <QScrollBar>
21#include <QFileDialog>
22#include <QCloseEvent>
23
24/* Local Includes */
25#include "pbiBackend.h"
26#include "extras.h"
27#include "largeItemWidget.h"
28#include "smallItemWidget.h"
29
30namespace Ui {
31    class MainUI;
32}
33
34class MainUI : public QMainWindow
35{
36        Q_OBJECT
37
38public:
39   explicit MainUI(QWidget* parent = 0);
40   void ProgramInit();
41   void setWardenMode(QString dir,QString ip); //call before ProgramInit
42
43public slots:
44    void slotSingleInstance();
45   
46protected:
47    void closeEvent(QCloseEvent *event);
48
49private slots:
50  //MENU OPTIONS
51  void on_actionImport_PBI_List_triggered();
52  void on_actionExport_PBI_List_triggered();
53  void on_actionQuit_triggered();
54  void on_actionAppCafe_Settings_triggered();
55  //INSTALLED TAB
56  void slotRefreshInstallTab();
57  void slotPBIStatusUpdate(QString);
58  void on_group_install_showinfo_toggled(bool);
59  void on_tool_install_gotobrowserpage_clicked();
60  void on_tool_install_toggleall_clicked();
61  void on_tree_install_apps_itemSelectionChanged();
62  void on_check_install_autoupdate_clicked();
63  void on_tool_install_update_clicked();
64  void on_tool_install_remove_clicked();
65  void on_tool_install_cancel_clicked();
66  void slotActionAddDesktop();
67  void slotActionRemoveDesktop();
68  void slotActionAddPath();
69  void slotActionRemovePath();
70  void slotActionAddPathAll();
71  void slotActionAddMenu();
72  void slotActionRemoveMenu();
73  void slotActionAddMenuAll();
74  void slotActionAddMime();
75  void slotActionRemoveMime();
76  void slotActionAddMimeAll();
77  void slotActionUpdate();
78  void slotActionRemove();
79  void slotActionCancel();
80 
81  //BROWSER TAB
82  void slotDisableBrowser(bool shownotification = TRUE);
83  void slotEnableBrowser();
84  void slotUpdateBrowserHome();
85  void slotGoToHome();
86  void slotGoToCategory(QString);
87  void slotGoToApp(QString);
88  void slotGoToSearch();
89  void slotShowSimilarApps(QStringList);
90  void slotShowSearchResults(QStringList, QStringList);
91  void on_tabWidget_currentChanged();
92  void on_tool_browse_home_clicked();
93  void on_tool_browse_cat_clicked();
94  void on_tool_browse_app_clicked();
95  void on_line_browse_searchbar_textChanged();
96  void on_tool_bapp_download_clicked();
97  void on_group_br_home_newapps_toggled(bool);
98  void on_group_bapp_similar_toggled(bool);
99  //OTHER
100  void slotDisplayError(QString,QString,QStringList);
101
102private:
103  Ui::MainUI *ui;
104  QString wardenDir, wardenIP, defaultIcon;
105  PBIBackend *PBI;
106  //INSTALLED TAB
107  QMenu *actionMenu;
108  void initializeInstalledTab();
109  void formatInstalledItemDisplay(QTreeWidgetItem *item);
110  QStringList getCheckedItems();
111  //BROWSER TAB
112  QTimer *searchTimer;
113  QString cCat;
114  void initializeBrowserTab();
115  //OTHER
116  QLabel *statusLabel;
117  void clearScrollArea(QScrollArea*);
118  void slotDisplayStats();
119   
120   
121signals:
122   
123} ;
124
125#endif
126
Note: See TracBrowser for help on using the repository browser.