source: src-qt4/pc-softwaremanager/mainUI.h @ 0314e57

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

Minor modifications to the new AppCafe?: make the list icons 22x22, fix a bug with opening the browser page for an installed application, add two direct action buttons to an installed app info - update (shown when necessary) and remove.

  • Property mode set to 100644
File size: 3.0 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 slotActionAddDesktop();
66  void slotActionRemoveDesktop();
67  void slotActionAddPath();
68  void slotActionRemovePath();
69  void slotActionAddPathAll();
70  void slotActionAddMenu();
71  void slotActionRemoveMenu();
72  void slotActionAddMenuAll();
73  void slotActionAddMime();
74  void slotActionRemoveMime();
75  void slotActionAddMimeAll();
76  void slotActionUpdate();
77  void slotActionRemove();
78  void slotActionCancel();
79 
80  //BROWSER TAB
81  void slotDisableBrowser(bool shownotification = TRUE);
82  void slotEnableBrowser();
83  void slotUpdateBrowserHome();
84  void slotGoToHome();
85  void slotGoToCategory(QString);
86  void slotGoToApp(QString);
87  void slotGoToSearch();
88  void slotShowSimilarApps(QStringList);
89  void slotShowSearchResults(QStringList, QStringList);
90  void on_tabWidget_currentChanged();
91  void on_tool_browse_home_clicked();
92  void on_tool_browse_cat_clicked();
93  void on_tool_browse_app_clicked();
94  void on_line_browse_searchbar_textChanged();
95  void on_tool_bapp_download_clicked();
96  void on_group_br_home_newapps_toggled(bool);
97  void on_group_bapp_similar_toggled(bool);
98  //OTHER
99  void slotDisplayError(QString,QString);
100
101private:
102  Ui::MainUI *ui;
103  QString wardenDir, wardenIP, defaultIcon;
104  PBIBackend *PBI;
105  //INSTALLED TAB
106  QMenu *actionMenu;
107  void initializeInstalledTab();
108  void formatInstalledItemDisplay(QTreeWidgetItem *item);
109  QStringList getCheckedItems();
110  //BROWSER TAB
111  QTimer *searchTimer;
112  QString cCat;
113  void initializeBrowserTab();
114  //OTHER
115  QLabel *statusLabel;
116  void clearScrollArea(QScrollArea*);
117  void slotDisplayStats();
118   
119   
120signals:
121   
122} ;
123
124#endif
125
Note: See TracBrowser for help on using the repository browser.