mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-06-06 09:16:02 +02:00
Disable the association controls in the 'Attach Source Location" dialog if path is not absolute.
This commit is contained in:
parent
0f09d718fc
commit
0cd54d6a88
3 changed files with 12 additions and 2 deletions
|
@ -1,3 +1,8 @@
|
||||||
|
2002-12-17 Mikhail Khodjaiants
|
||||||
|
Disable the association controls in the 'Attach Source Location" dialog if path is not absolute.
|
||||||
|
* AttachSourceLocationBlock.java
|
||||||
|
* CUISourceLocator.java
|
||||||
|
|
||||||
2002-12-17 Mikhail Khodjaiants
|
2002-12-17 Mikhail Khodjaiants
|
||||||
Formatting 'char' types.
|
Formatting 'char' types.
|
||||||
* VariableFormatActionDelegate.java
|
* VariableFormatActionDelegate.java
|
||||||
|
|
|
@ -68,9 +68,11 @@ public class AttachSourceLocationBlock
|
||||||
|
|
||||||
public void setInitialAssociationPath( IPath path )
|
public void setInitialAssociationPath( IPath path )
|
||||||
{
|
{
|
||||||
|
fAssociationText.setEnabled( ( path != null ) );
|
||||||
|
fAssocitedCheckButton.setEnabled( ( path != null ) );
|
||||||
|
fAssocitedCheckButton.setSelection( ( path != null ) );
|
||||||
if ( path != null )
|
if ( path != null )
|
||||||
{
|
{
|
||||||
fAssocitedCheckButton.setSelection( true );
|
|
||||||
fAssociationText.setText( path.toOSString() );
|
fAssociationText.setText( path.toOSString() );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -246,7 +246,10 @@ public class CUISourceLocator implements IAdaptable
|
||||||
{
|
{
|
||||||
AttachSourceLocationDialog dialog = new AttachSourceLocationDialog( CDebugUIPlugin.getActiveWorkbenchShell() );
|
AttachSourceLocationDialog dialog = new AttachSourceLocationDialog( CDebugUIPlugin.getActiveWorkbenchShell() );
|
||||||
Path path = new Path( fileName );
|
Path path = new Path( fileName );
|
||||||
dialog.setInitialPath( path.removeLastSegments( 1 ) );
|
if ( path.isAbsolute() )
|
||||||
|
{
|
||||||
|
dialog.setInitialPath( path.removeLastSegments( 1 ) );
|
||||||
|
}
|
||||||
if ( dialog.open() == Dialog.OK )
|
if ( dialog.open() == Dialog.OK )
|
||||||
{
|
{
|
||||||
if ( dialog.getLocation() != null )
|
if ( dialog.getLocation() != null )
|
||||||
|
|
Loading…
Add table
Reference in a new issue