1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-07-04 07:35:24 +02:00

[165680] - fix for "Show in Remote Shell View" does not work

This commit is contained in:
David McKnight 2007-06-29 14:15:54 +00:00
parent 4c9c5903b7
commit bf65ff0dec
3 changed files with 34 additions and 2 deletions

View file

@ -12,7 +12,7 @@
* Emily Bruner, Mazen Faraj, Adrian Storisteanu, Li Ding, and Kent Hawley.
*
* Contributors:
* {Name} (company) - description of contribution.
* David McKnight (IBM) - [165680] "Show in Remote Shell View" does not work
*******************************************************************************/
package org.eclipse.rse.internal.shells.ui.actions;
@ -53,6 +53,7 @@ public class SystemShowInShellViewAction extends SystemBaseShellAction
{
IRemoteCommandShell cmdShell = (IRemoteCommandShell)_selected.get(i);
viewPart.updateOutput(cmdShell);
viewPart.showPageFor(cmdShell); // for defect 165680
}
}
}

View file

@ -12,7 +12,7 @@
* Emily Bruner, Mazen Faraj, Adrian Storisteanu, Li Ding, and Kent Hawley.
*
* Contributors:
* {Name} (company) - description of contribution.
* David McKnight (IBM) - [165680] "Show in Remote Shell View" does not work
*******************************************************************************/
package org.eclipse.rse.internal.shells.ui.view;
@ -128,6 +128,24 @@ public class CommandsViewWorkbook extends Composite
{
_folder.setFocus();
}
/**
* For defect 165680, needed to change the active tab
* @param root the shell to show
*/
public void showPageFor(IRemoteCommandShell root)
{
for (int i = 0; i < _folder.getItemCount(); i++)
{
CTabItem item = _folder.getItem(i);
CommandsViewPage page = (CommandsViewPage) item.getData();
if (page != null && root == page.getInput())
{
_folder.setSelection(item);
}
}
}
public Object getInput()
{

View file

@ -16,6 +16,7 @@
* Martin Oberhuber (Wind River) - [186128] Move IProgressMonitor last in all API
* Martin Oberhuber (Wind River) - [174945] Remove obsolete icons from rse.shells.ui
* Martin Oberhuber (Wind River) - [186640] Add IRSESystemType.testProperty()
* David McKnight (IBM) - [165680] "Show in Remote Shell View" does not work
********************************************************************************/
package org.eclipse.rse.internal.shells.ui.view;
@ -627,6 +628,18 @@ public class SystemCommandsViewPart
updateActionStates();
}
}
/**
* For defect 165680, needed to change the active tab
* @param root the shell to show
*/
public void showPageFor(IRemoteCommandShell root)
{
if (root != null && _folder != null)
{
_folder.showPageFor(root);
}
}
public void setInput(IAdaptable object)
{