X-Git-Url: http://vcs.maemo.org/git/?a=blobdiff_plain;f=mainwindow.h;h=c42c5ec5449dd9863b2aa335fb5dc5205a5fc8bc;hb=HEAD;hp=ef6f19ab82a84ba5dc053dd928a166fce3d58bc4;hpb=d359576506dc27d7352e1feaa8c38412818db99c;p=pierogi diff --git a/mainwindow.h b/mainwindow.h index ef6f19a..c42c5ec 100644 --- a/mainwindow.h +++ b/mainwindow.h @@ -10,6 +10,9 @@ class QListWidget; class QListWidgetItem; class QDialog; +class QKeyEvent; + +//class PIRTabWidget; class PIRSelectKeysetForm; class PIRSelectDeviceForm; @@ -18,9 +21,11 @@ class PIRDocumentationForm; class PIRAboutForm; class PIRFavoritesDialog; class PIRKeysetWidgetItem; +class PIRMacroPack; class PIRKeysetManager; class PIRPanelManager; +class PIRMacroManager; namespace Ui { class MainWindow; @@ -45,10 +50,10 @@ public: void showExpanded(); - void startRepeating( + bool startRepeating( PIRKeyName name); - void startRepeating( + bool startRepeating( PIRKeyName name, unsigned int keysetID); @@ -69,12 +74,27 @@ public: QString getCurrentMake(); QString getCurrentName(); + QString getCurrentFullName(); + + 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(); @@ -84,6 +104,49 @@ public: 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( unsigned int keysetID, @@ -103,7 +166,7 @@ public slots: private slots: void on_actionSelectKeyset_triggered(); - void on_actionSelect_Device_By_Name_triggered(); + void on_actionBrowse_Device_List_triggered(); void on_actionPreferences_triggered(); void on_actionAbout_triggered(); void on_actionDocumentation_triggered(); @@ -112,10 +175,18 @@ private slots: void finalCleanup(); private: +// void keyPressEvent( +// QKeyEvent *event); + +// void keyReleaseEvent( +// QKeyEvent *event); + void populateFavorites(); Ui::MainWindow *ui; +// PIRTabWidget *myTabWidget; + PIRSelectKeysetForm *selectKeysetForm; PIRSelectDeviceForm *selectDeviceForm; PIRPreferencesForm *preferencesForm; @@ -125,6 +196,7 @@ private: PIRKeysetManager *myKeysets; PIRPanelManager *myPanels; + PIRMacroManager *myMacros; unsigned int currentKeyset;