Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[cdt-patch] Changes in the 'Attach Source Location' dialog

Disable the association controls in the 'Attach Source Location" dialog if path is not absolute.

Index: ChangeLog
===================================================================
RCS file: /home/tools/org.eclipse.cdt.debug.ui/ChangeLog,v
retrieving revision 1.57
diff -u -r1.57 ChangeLog
--- ChangeLog 17 Dec 2002 21:54:18 -0000 1.57
+++ ChangeLog 17 Dec 2002 23:08:44 -0000
@@ -1,4 +1,9 @@
 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
  Formatting 'char' types.
  * VariableFormatActionDelegate.java
 
Index: src/org/eclipse/cdt/debug/ui/sourcelookup/AttachSourceLocationBlock.java
===================================================================
RCS file: /home/tools/org.eclipse.cdt.debug.ui/src/org/eclipse/cdt/debug/ui/sourcelookup/AttachSourceLocationBlock.java,v
retrieving revision 1.1
diff -u -r1.1 AttachSourceLocationBlock.java
--- src/org/eclipse/cdt/debug/ui/sourcelookup/AttachSourceLocationBlock.java 17 Dec 2002 20:00:40 -0000 1.1
+++ src/org/eclipse/cdt/debug/ui/sourcelookup/AttachSourceLocationBlock.java 17 Dec 2002 23:08:44 -0000
@@ -68,9 +68,11 @@
 
  public void setInitialAssociationPath( IPath path )
  {
+  fAssociationText.setEnabled( ( path != null ) );
+  fAssocitedCheckButton.setEnabled( ( path != null ) );
+  fAssocitedCheckButton.setSelection( ( path != null ) );
   if ( path != null )
   {
-   fAssocitedCheckButton.setSelection( true );
    fAssociationText.setText( path.toOSString() );
   }
  }
Index: src/org/eclipse/cdt/debug/ui/sourcelookup/CUISourceLocator.java
===================================================================
RCS file: /home/tools/org.eclipse.cdt.debug.ui/src/org/eclipse/cdt/debug/ui/sourcelookup/CUISourceLocator.java,v
retrieving revision 1.1
diff -u -r1.1 CUISourceLocator.java
--- src/org/eclipse/cdt/debug/ui/sourcelookup/CUISourceLocator.java 17 Dec 2002 20:00:40 -0000 1.1
+++ src/org/eclipse/cdt/debug/ui/sourcelookup/CUISourceLocator.java 17 Dec 2002 23:08:44 -0000
@@ -246,7 +246,10 @@
  {
   AttachSourceLocationDialog dialog = new AttachSourceLocationDialog( CDebugUIPlugin.getActiveWorkbenchShell() );
   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.getLocation() != null )


Back to the top