OSSP CVS Repository

ossp - Check-in [2854]
Not logged in
[Honeypot]  [Browse]  [Home]  [Login]  [Reports
[Search]  [Ticket]  [Timeline
  [Patchset]  [Tagging/Branching

Check-in Number: 2854
Date: 2002-Nov-19 21:29:08 (local)
2002-Nov-19 20:29:08 (UTC)
User:ms
Branch:
Comment: Added edit and view drop down menus, enhanced existing ones.
Tickets:
Inspections:
Files:
ossp-pkg/as/as-gui/as_assist.cpp      1.4 -> 1.5     28 inserted, 4 deleted
ossp-pkg/as/as-gui/as_gui.h      1.13 -> 1.14     8 inserted, 0 deleted
ossp-pkg/as/as-gui/as_slot.cpp      1.3 -> 1.4     72 inserted, 0 deleted
ossp-pkg/titraq/titassist.cpp      1.4 -> 1.5     28 inserted, 4 deleted
ossp-pkg/titraq/titraq.h      1.13 -> 1.14     8 inserted, 0 deleted
ossp-pkg/titraq/titslot.cpp      1.3 -> 1.4     72 inserted, 0 deleted

ossp-pkg/as/as-gui/as_assist.cpp 1.4 -> 1.5

--- as_assist.cpp        2002/11/19 19:42:14     1.4
+++ as_assist.cpp        2002/11/19 20:29:08     1.5
@@ -69,6 +69,30 @@
     pFilepopup->insertSeparator();
     m_pFilequitact->addTo(pFilepopup);
 
+    // Construct and populate the edit menu with subitems
+    QPopupMenu *pEditpopup = new QPopupMenu(this);
+    if (pEditpopup == NULL) // Sanity check
+        throw Genexcept("Main window edit popup creation failed.");
+    m_pMenubar->insertItem(trUtf8("&Edit"), pEditpopup);
+    pEditpopup->insertItem("Cu&t", this, SLOT(cut()), CTRL+Key_X);
+    pEditpopup->insertItem("&Copy", this, SLOT(copy()), CTRL+Key_C);
+    pEditpopup->insertItem("&Paste", this, SLOT(paste()), CTRL+Key_V);
+    pEditpopup->insertSeparator();
+    pEditpopup->insertItem("&Add", this, SLOT(addEntry()), CTRL+Key_A);
+    pEditpopup->insertItem("&Delete", this, SLOT(delEntry()), Key_Delete);
+    pEditpopup->insertItem("Select &All", this, SLOT(selAll()), CTRL+Key_A);
+    pEditpopup->insertSeparator();
+    pEditpopup->insertItem("Preferences...", this, SLOT(configPrefs()));
+
+    // Construct and populate the view menu with subitems
+    QPopupMenu *pViewpopup = new QPopupMenu(this);
+    if (pViewpopup == NULL) // Sanity check
+        throw Genexcept("Main window view popup creation failed.");
+    m_pMenubar->insertItem(trUtf8("&View"), pViewpopup);
+    pViewpopup->insertItem(trUtf8("&Normal"), this, SLOT(normalView()));
+    pViewpopup->insertItem(trUtf8("&Editing"), this, SLOT(editingView()));
+    pViewpopup->insertItem(trUtf8("&Timing"), this, SLOT(timingView()));
+
     // Pad spacing to force help menu to appear far right
     m_pMenubar->insertSeparator();
 
@@ -91,7 +115,7 @@
 void Titraqform::setupActions(void)
 {
     // File new action
-    m_pFilenewact = new QAction(trUtf8("New File"), QPixmap(s_kpcFilenew_xpm), trUtf8("&New"), CTRL+Key_N, this, "New");
+    m_pFilenewact = new QAction(trUtf8("New File"), QPixmap(s_kpcFilenew_xpm), trUtf8("&New..."), CTRL+Key_N, this, "New");
     if (m_pFilenewact == NULL) // Sanity check
         throw Genexcept("Main window file new action creation failed.");
     connect(m_pFilenewact, SIGNAL(activated()), this, SLOT(newDoc()));
@@ -103,7 +127,7 @@
     m_pFilenewact->setWhatsThis(kszFilenewtext);
 
     // File open action
-    m_pFileopenact = new QAction(trUtf8("Open File"), QPixmap(s_kpcFileopen_xpm), trUtf8("&Open"), CTRL+Key_O, this, "Open");
+    m_pFileopenact = new QAction(trUtf8("Open File"), QPixmap(s_kpcFileopen_xpm), trUtf8("&Open..."), CTRL+Key_O, this, "Open");
     if (m_pFileopenact == NULL) // Sanity check
         throw Genexcept("Main window file open action creation failed.");
     connect(m_pFileopenact, SIGNAL(activated()), this, SLOT(choose()));
@@ -128,7 +152,7 @@
     m_pFilesaveact->setWhatsThis(kszFilesavetext);
 
     // File save selected action
-    m_pFilesaveasact = new QAction(trUtf8("Save File As"), trUtf8("Save &as"), 0, this, "SaveAs");
+    m_pFilesaveasact = new QAction(trUtf8("Save File As"), trUtf8("Save &As..."), 0, this, "SaveAs");
     if (m_pFilesaveasact == NULL) // Sanity check
         throw Genexcept("Main window file save as action creation failed.");
     connect(m_pFilesaveasact, SIGNAL(activated()), this, SLOT(saveAs()));
@@ -141,7 +165,7 @@
     connect(m_pFilecloseact, SIGNAL(activated()), this, SLOT(close()));
 
     // File quit action
-    m_pFilequitact = new QAction(trUtf8("Exit"), trUtf8("&Exit"), CTRL+Key_Q, this, "Exit");
+    m_pFilequitact = new QAction(trUtf8("Exit"), trUtf8("E&xit"), CTRL+Key_Q, this, "Exit");
     if (m_pFilequitact == NULL) // Sanity check
         throw Genexcept("Main window file quit action creation failed.");
     connect(m_pFilequitact, SIGNAL(activated()), qApp, SLOT(quit()));


ossp-pkg/as/as-gui/as_gui.h 1.13 -> 1.14

--- as_gui.h     2002/11/19 19:42:14     1.13
+++ as_gui.h     2002/11/19 20:29:08     1.14
@@ -81,6 +81,14 @@
     void about(void);                   // Learn more about this program itself
     void aboutOSSP(void);               // Learn more about the OSSP
     void aboutQt(void);                 // Learn more about Qt
+    void cut(void);                     // Edit menu cut
+    void copy(void);                    // Edit menu copy
+    void paste(void);                   // Edit menu paste
+    void selAll(void);                  // Edit menu select all
+    void configPrefs(void);             // Edit menu configure preferences
+    void normalView(void);              // View menu normal
+    void editingView(void);             // View menu editing
+    void timingView(void);              // View menu timing
 
 protected:
     // Application main events


ossp-pkg/as/as-gui/as_slot.cpp 1.3 -> 1.4

--- as_slot.cpp  2002/11/19 19:42:14     1.3
+++ as_slot.cpp  2002/11/19 20:29:08     1.4
@@ -168,6 +168,78 @@
 }
 
 //
+// Edit menu cut
+//
+void Titraqform::cut(void)
+{
+    Prototype Unimp;
+    Unimp.doMbox();
+}
+
+//
+// Edit menu copy
+//
+void Titraqform::copy(void)
+{
+    Prototype Unimp;
+    Unimp.doMbox();
+}
+
+//
+// Edit menu paste
+//
+void Titraqform::paste(void)
+{
+    Prototype Unimp;
+    Unimp.doMbox();
+}
+
+//
+// Edit menu select all entries
+//
+void Titraqform::selAll(void)
+{
+    Prototype Unimp;
+    Unimp.doMbox();
+}
+
+//
+// Edit menu configure preferences
+//
+void Titraqform::configPrefs(void)
+{
+    Prototype Unimp;
+    Unimp.doMbox();
+}
+
+//
+// View menu normal
+//
+void Titraqform::normalView(void)
+{
+    Prototype Unimp;
+    Unimp.doMbox();
+}
+
+//
+// View menu editing
+//
+void Titraqform::editingView(void)
+{
+    Prototype Unimp;
+    Unimp.doMbox();
+}
+
+//
+// View menu timing
+//
+void Titraqform::timingView(void)
+{
+    Prototype Unimp;
+    Unimp.doMbox();
+}
+
+//
 // Learn more about this program itself
 //
 void Titraqform::about(void)




CVSTrac 2.0.1