Commits

Matthew Smith  committed fa3a364

Uses 0 rather than 1 for hotkey for recent file 10

catkin.cc, SysTrayIcon.cc - In the recent file menu, for entry 9 (which shows as 10), uses 0 rather than 1 for its hotkey (to make sure 1 is reserved for the first entry)

  • Participants
  • Parent commits 76825ea

Comments (0)

Files changed (2)

File SysTrayIcon.cc

       t = recentFiles.value( j ).title.section( ' ', 0, 5 );
       if( t != recentFiles.value( j ).title )
 	t.append( tr( " ..." ) );
-      text = tr( "&%1 %2" )
-	.arg( j + 1 )
+      if( j == 9 )
+         text = tr( "1&0 %1" )
 	.arg( recentFiles.value( j ).title.isEmpty() ?
 	      recentFiles.value( j ).filename.section( "/", -1, -1 ) : t );
+      else
+        text = tr( "&%1 %2" )
+	  .arg( j + 1 )
+	  .arg( recentFiles.value( j ).title.isEmpty() ?
+	        recentFiles.value( j ).filename.section( "/", -1, -1 ) : t );
       recentFileActions[j]->setText( text );
       recentFileActions[j]->setData( recentFiles.value( j ).filename );
       recentFileActions[j]->setVisible( true );
       t = recentFiles.value( j ).title.section( ' ', 0, 5 );
       if( t != recentFiles.value( j ).title )
 	t.append( tr( " ..." ) );
-      text = tr( "&%1 %2" )
-	.arg( j + 1 )
-	.arg( recentFiles.value( j ).title.isEmpty() ?
+      if( j == 9 )
+        text = tr( "1&0 %1" )
+ 	.arg( recentFiles.value( j ).title.isEmpty() ?
 	      recentFiles.value( j ).filename.section( "/", -1, -1 ) : t );
+      else
+        text  = tr("&%1 %2" )
+	  .arg( j + 1 )
+	  .arg( recentFiles.value( j ).title.isEmpty() ?
+	        recentFiles.value( j ).filename.section( "/", -1, -1 ) : t );
       recentFileActions[j]->setText( text );
       recentFileActions[j]->setData( recentFiles.value( j ).filename );
       recentFileActions[j]->setVisible( true );