ide: added feature open recently opened files / projects in another ide by holding...
authorRejean Loyer <rejean.loyer@gmail.com>
Fri, 30 Mar 2012 16:06:42 +0000 (12:06 -0400)
committerJerome St-Louis <jerome@ecere.com>
Wed, 24 Oct 2012 07:52:04 +0000 (03:52 -0400)
ide/src/ide.ec

index 050f25f..1cb196b 100644 (file)
@@ -715,7 +715,17 @@ class IDEWorkSpace : Window
          {
             if(id == selection.id)
             {
-               OpenFile(file, normal, true, null, no, normal);
+               if(mods.ctrl) // Menu::OnLeftButtonUp -> modifiers.ctrl == true, modifiers == 18
+                             // Menu::MenuItemSelection -> key.ctrl == false, key.modifiers.ctrl == false, key == 18
+                             // removing the (Key) cast from Modifiers when calling MenuItemSelection in OnLeftButtonUp didn't help
+               {
+                  // it never gets in here!!!
+                  char * command = PrintString("ide ", file);
+                  Execute(command);
+                  delete command;
+               }
+               else
+                  OpenFile(file, normal, true, null, no, normal);
                break;
             }
             id++;
@@ -730,7 +740,17 @@ class IDEWorkSpace : Window
          {
             if(id == selection.id)
             {
-               OpenFile(file, normal, true, null, no, normal);
+               if(mods.ctrl) // Menu::OnLeftButtonUp -> modifiers.ctrl == true, modifiers == 18
+                             // Menu::MenuItemSelection -> key.ctrl == false, key.modifiers.ctrl == false, key == 18
+                             // removing the (Key) cast from Modifiers when calling MenuItemSelection in OnLeftButtonUp didn't help
+               {
+                  // it never gets in here!!!
+                  char * command = PrintString("ide ", file);
+                  Execute(command);
+                  delete command;
+               }
+               else
+                  OpenFile(file, normal, true, null, no, normal);
                break;
             }
             id++;