class QListWidget;
class QListWidgetItem;
+class QDialog;
+class QKeyEvent;
+
+//class PIRTabWidget;
+
class PIRSelectKeysetForm;
class PIRSelectDeviceForm;
-class PIRPanelSelectionForm;
+class PIRPreferencesForm;
class PIRDocumentationForm;
class PIRAboutForm;
+class PIRFavoritesDialog;
+class PIRKeysetWidgetItem;
+class PIRMacroPack;
+
class PIRKeysetManager;
class PIRPanelManager;
+class PIRMacroManager;
namespace Ui {
class MainWindow;
void showExpanded();
- void startRepeating(
+ bool startRepeating(
PIRKeyName name);
+ bool startRepeating(
+ PIRKeyName name,
+ unsigned int keysetID);
+
void stopRepeating();
- void managePanel(
- PIRPanelName name,
- int state);
+ // Favorites panel actions:
+ void addToFavorites(
+ PIRKeysetWidgetItem *kwi);
- void insertPanel(
- int index,
- QWidget *panel,
- const QString &displayName);
+ void removeFromFavorites(
+ unsigned int keysetID);
- void removePanel(
- int index,
- QWidget *panel);
+ void enableButtons();
- // Favorites panel actions:
- void addCurrentKeyset(
- QListWidget *qlw);
+ // Preferences actions:
+ void useMainPanel();
+ void useAltMainPanel();
- void removeFavoriteKeyset(
- QListWidget *qlw);
+ QString getCurrentMake();
+ QString getCurrentName();
+ QString getCurrentFullName();
- void enableButtons();
+ QString getKeysetMake(
+ unsigned int id);
+
+ QString getKeysetName(
+ unsigned int id);
+
+ QString getFullKeysetName(
+ unsigned int id);
+
+ unsigned int getCurrentKeyset()
+ {
+ return currentKeyset;
+ }
+
+ bool findKeysetID(
+ QString make,
+ QString name,
+ unsigned int &id);
+
+ void insertCornerButtons();
+ void disableUpdates();
+ void enableUpdates();
+ void clearTabs();
+ void addTab(
+ QWidget *page,
+ QString label);
+ void setupTabs(PIRTabBarName name);
+
+ bool selectNextKeyset();
+ bool selectPrevKeyset();
+ bool selectFirstKeyset();
+ void openCurrentKeysetDialog();
+
+ void updateKeysetSelection(
+ unsigned int targetID);
+
+ PIRMacroPack *getUserPack();
+ PIRMacroPack *getMultitapPack();
+
+ bool hasMacroButton(
+ unsigned int buttonID);
+
+ QString getMacroButtonText(
+ unsigned int buttonID);
+
+ void executeMacroButton(
+ unsigned int buttonID);
+
+ void updateUserButtons(); // Should this be a slot?
+
+ void storeMacros();
+
+ void setMacroKbdFocus(
+ int index);
+
+ void setMacroBtnFocus(
+ int index);
+
+ void switchToTab(
+ int tabNumber);
+
+ void handleKeypress(
+ char key);
+
+// void handleKeyRelease(
+// char Key);
+
+ void gotoPreviousTabs();
+
+ void gotoNextTabs();
signals:
void buttonPressed(
private slots:
void on_actionSelectKeyset_triggered();
- void on_actionSelect_Device_By_Name_triggered();
- void on_actionArrange_Button_Panels_triggered();
+ void on_actionBrowse_Device_List_triggered();
+ void on_actionPreferences_triggered();
void on_actionAbout_triggered();
void on_actionDocumentation_triggered();
- void on_prevPanelButton_clicked();
- void on_nextPanelButton_clicked();
- void on_selectPanelComboBox_currentIndexChanged(int index);
-
// Internal actions:
void finalCleanup();
private:
+// void keyPressEvent(
+// QKeyEvent *event);
+
+// void keyReleaseEvent(
+// QKeyEvent *event);
+
void populateFavorites();
-// void setupTabs();
Ui::MainWindow *ui;
+// PIRTabWidget *myTabWidget;
+
PIRSelectKeysetForm *selectKeysetForm;
PIRSelectDeviceForm *selectDeviceForm;
- PIRPanelSelectionForm *panelSelectionForm;
+ PIRPreferencesForm *preferencesForm;
PIRDocumentationForm *documentationForm;
PIRAboutForm *aboutForm;
+ PIRFavoritesDialog *favoritesDialog;
PIRKeysetManager *myKeysets;
PIRPanelManager *myPanels;
+ PIRMacroManager *myMacros;
unsigned int currentKeyset;