Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMike Rennie2013-07-16 12:57:17 -0400
committerMike Rennie2013-07-16 12:57:17 -0400
commit44c60018da2e1e14ec6b2d0b0f2b01a71df104fc (patch)
tree45b05cd32d2c68aec0046b2204d81a0d40e5645a /org.eclipse.debug.ui/ui/org/eclipse/debug/ui
parent2123eb384fbb6bfe61a03e40ffe6836b2daf4696 (diff)
downloadeclipse.platform.debug-44c60018da2e1e14ec6b2d0b0f2b01a71df104fc.tar.gz
eclipse.platform.debug-44c60018da2e1e14ec6b2d0b0f2b01a71df104fc.tar.xz
eclipse.platform.debug-44c60018da2e1e14ec6b2d0b0f2b01a71df104fc.zip
Bug 413095 - Clean up deprecation and code warnings
Diffstat (limited to 'org.eclipse.debug.ui/ui/org/eclipse/debug/ui')
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/ui/InspectPopupDialog.java15
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/ui/actions/ImportBreakpointsOperation.java6
2 files changed, 17 insertions, 4 deletions
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/ui/InspectPopupDialog.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/ui/InspectPopupDialog.java
index 90d5babe2..c0c71c341 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/ui/InspectPopupDialog.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/ui/InspectPopupDialog.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2005, 2012 IBM Corporation and others.
+ * Copyright (c) 2005, 2013 IBM Corporation and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
@@ -13,6 +13,8 @@ package org.eclipse.debug.ui;
import java.util.List;
import org.eclipse.core.runtime.CoreException;
+import org.eclipse.core.runtime.preferences.IEclipsePreferences;
+import org.eclipse.core.runtime.preferences.InstanceScope;
import org.eclipse.debug.core.DebugPlugin;
import org.eclipse.debug.core.model.IExpression;
import org.eclipse.debug.internal.ui.DebugUIPlugin;
@@ -50,6 +52,7 @@ import org.eclipse.ui.IViewPart;
import org.eclipse.ui.IWorkbenchPage;
import org.eclipse.ui.IWorkbenchPartSite;
import org.eclipse.ui.PartInitException;
+import org.osgi.service.prefs.BackingStoreException;
/**
* A <code>DebugPopup</code> that can be used to inspect an
@@ -194,7 +197,15 @@ public class InspectPopupDialog extends DebugPopup {
int[] weights = fSashForm.getWeights();
if (weights.length == 2){
String weightString = weights[0] + ":" + weights[1]; //$NON-NLS-1$
- DebugUIPlugin.getDefault().getPluginPreferences().setValue(PREF_INSPECT_POPUP_SASH_WEIGHTS, weightString);
+ IEclipsePreferences node = InstanceScope.INSTANCE.getNode(DebugUIPlugin.getUniqueIdentifier());
+ if(node != null) {
+ node.put(PREF_INSPECT_POPUP_SASH_WEIGHTS, weightString);
+ try {
+ node.flush();
+ } catch (BackingStoreException e) {
+ DebugUIPlugin.log(e);
+ }
+ }
}
}
}
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/ui/actions/ImportBreakpointsOperation.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/ui/actions/ImportBreakpointsOperation.java
index 2599e5477..5e94b9d18 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/ui/actions/ImportBreakpointsOperation.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/ui/actions/ImportBreakpointsOperation.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2005, 2012 IBM Corporation and others.
+ * Copyright (c) 2005, 2013 IBM Corporation and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
@@ -182,7 +182,9 @@ public class ImportBreakpointsOperation implements IRunnableWithProgress {
return;
}
attributes = collectBreakpointProperties(nodes[i]);
-
+ if(attributes == null) {
+ continue;
+ }
IResource resource;
if(fImportBreakpoints) {
resource = workspace.findMember((String) attributes.get(IImportExportConstants.IE_NODE_PATH));

Back to the top