source: src-qt4/pc-softwaremanager/mainUI.h @ 2b9aed7

releng/10.0.1releng/10.0.2
Last change on this file since 2b9aed7 was 2b9aed7, checked in by Ken Moore <ken@…>, 5 months ago

Get the shortcuts button working on the application details page (just for that one application)

  • Property mode set to 100644
File size: 3.5 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#include <QDesktopServices>
24#include <QUrl>
25
26/* Local Includes */
27#include "pbiBackend.h"
28#include "extras.h"
29#include "largeItemWidget.h"
30#include "smallItemWidget.h"
31
32namespace Ui {
33    class MainUI;
34}
35
36class MainUI : public QMainWindow
37{
38        Q_OBJECT
39
40public:
41   explicit MainUI(QWidget* parent = 0);
42   void ProgramInit();
43   void setWardenMode(QString dir,QString ip); //call before ProgramInit
44
45public slots:
46    void slotSingleInstance();
47   
48protected:
49    void closeEvent(QCloseEvent *event);
50
51private slots:
52  //MENU OPTIONS
53  void on_actionImport_PBI_List_triggered();
54  void on_actionExport_PBI_List_triggered();
55  void on_actionQuit_triggered();
56  void on_actionAppCafe_Settings_triggered();
57  void on_actionInstall_From_File_triggered();
58  //INSTALLED TAB
59  void slotRefreshInstallTab();
60  void slotCheckSelectedItems();
61  void slotPBIStatusUpdate(QString);
62  void on_tool_install_details_clicked();
63  void on_tool_install_back_clicked();
64  void on_tool_install_gotobrowserpage_clicked();
65  void on_tool_install_toggleall_clicked();
66  void on_tree_install_apps_itemSelectionChanged();
67  void on_tree_install_apps_itemDoubleClicked(QTreeWidgetItem *item);
68  void on_check_install_autoupdate_clicked();
69  void on_tool_install_update_clicked();
70  void on_tool_install_remove_clicked();
71  void on_tool_install_cancel_clicked();
72  void on_tool_install_maintainer_clicked();
73  void slotActionAddDesktop();
74  void slotActionRemoveDesktop();
75  void slotActionAddPath();
76  void slotActionRemovePath();
77  void slotActionAddPathAll();
78  void slotActionAddMenu();
79  void slotActionRemoveMenu();
80  void slotActionAddMenuAll();
81  void slotActionAddMime();
82  void slotActionRemoveMime();
83  void slotActionAddMimeAll();
84  void slotActionUpdate();
85  void slotActionRemove();
86  void slotActionCancel();
87  void slotStartApp(QAction*);
88  void slotUpdateSelectedPBI();
89  void updateInstallDetails(QString appID);
90  //BROWSER TAB
91  void slotDisableBrowser(bool shownotification = TRUE);
92  void slotEnableBrowser();
93  void slotUpdateBrowserHome();
94  void slotGoToHome();
95  void slotGoToCategory(QString);
96  void slotGoToApp(QString);
97  void slotUpdateAppDownloadButton();
98  void slotGoToSearch();
99  void slotShowSimilarApps(QStringList);
100  void slotShowSearchResults(QStringList, QStringList);
101  void on_tabWidget_currentChanged();
102  void on_tool_browse_home_clicked();
103  void on_tool_browse_cat_clicked();
104  void on_tool_browse_app_clicked();
105  void on_line_browse_searchbar_textChanged();
106  void on_tool_bapp_download_clicked();
107  void on_group_br_home_newapps_toggled(bool);
108  void on_group_bapp_similar_toggled(bool);
109  //OTHER
110  void slotDisplayError(QString,QString,QStringList);
111 
112private:
113  Ui::MainUI *ui;
114  QString wardenDir, wardenIP, defaultIcon;
115  PBIBackend *PBI;
116  //INSTALLED TAB
117  QMenu *actionMenu, *appBinMenu, *shortcutMenu, *sDeskMenu, *sMenuMenu;
118  QString cDetails;
119  void initializeInstalledTab();
120  void formatInstalledItemDisplay(QTreeWidgetItem *item);
121  QStringList getCheckedItems();
122  //BROWSER TAB
123  QTimer *searchTimer;
124  QString cCat, cApp;
125  void initializeBrowserTab();
126  //OTHER
127  QLabel *statusLabel;
128  void clearScrollArea(QScrollArea*);
129  void slotDisplayStats();
130   
131} ;
132
133#endif
134
Note: See TracBrowser for help on using the repository browser.