1.1 --- a/mainwindow.cpp Wed Jun 14 10:28:01 2006 +0000
1.2 +++ b/mainwindow.cpp Wed Jun 14 14:43:18 2006 +0000
1.3 @@ -502,28 +502,29 @@
1.4 actionEditPaste=a;
1.5
1.6 // Shortcuts to modify heading:
1.7 - /*
1.8 a = new QAction(tr( "Edit heading" ),this);
1.9 a->setStatusTip ( tr( "edit Heading" ));
1.10 a->setShortcut ( Qt::Key_Enter);
1.11 + a->setShortcutContext (Qt::ApplicationShortcut);
1.12 + addAction (a);
1.13 connect( a, SIGNAL( triggered() ), this, SLOT( editHeading() ) );
1.14 actionListBranches.append(a);
1.15 - */
1.16 a = new QAction( tr( "Edit heading" ), this);
1.17 a->setStatusTip (tr( "edit Heading" ));
1.18 a->setShortcut (Qt::Key_Return );
1.19 connect( a, SIGNAL( activated() ), this, SLOT( editHeading() ) );
1.20 - //actionListBranches.append(a);
1.21 + actionListBranches.append(a);
1.22 editMenu->addAction (a);
1.23 + a->setShortcutContext (Qt::ApplicationShortcut);
1.24 + addAction (a);
1.25 actionEditHeading=a;
1.26 - /*
1.27 - a = new QAction( tr( "Edit heading" ),this);
1.28 + a = new QAction( tr( "Edit heading" ), this);
1.29 a->setStatusTip (tr( "edit Heading" ));
1.30 a->setShortcut ( Qt::Key_F2 );
1.31 + a->setShortcutContext (Qt::ApplicationShortcut);
1.32 + addAction (a);
1.33 connect( a, SIGNAL( activated() ), this, SLOT( editHeading() ) );
1.34 - a->setEnabled (false);
1.35 actionListBranches.append(a);
1.36 - */
1.37
1.38 // Shortcut to delete selection
1.39 a = new QAction( tr( "Delete Selection" ),this);
1.40 @@ -2683,19 +2684,12 @@
1.41
1.42 void Main::editHeading()
1.43 {
1.44 - qWarning ("Main::editHeading called");
1.45 if (currentMapEditor())
1.46 currentMapEditor()->editHeading();
1.47 }
1.48
1.49 void Main::editNewBranch()
1.50 {
1.51 - //FIXME
1.52 - // tried to see if maybe currentMapEditor is not set, but
1.53 - // ME does not seem to send a key event anyway...:q
1.54 - //here i was last time...
1.55 -
1.56 - cout << "Main::editNewBranch\n";
1.57 if (currentMapEditor())
1.58 currentMapEditor()->addNewBranch(0);
1.59 }