aboutsummaryrefslogtreecommitdiffstats
path: root/eclipse
diff options
context:
space:
mode:
authorSiva Velusamy <vsiva@google.com>2012-11-15 12:41:03 -0800
committerSiva Velusamy <vsiva@google.com>2012-11-15 12:41:03 -0800
commiteb843e219013194f8f9170837e77b0cec61ace7b (patch)
treec1a22785adbd4826d05195e504597e7334a1b1b1 /eclipse
parentdc08099a240d50eacc989a230af53273799bc578 (diff)
downloadsdk-eb843e219013194f8f9170837e77b0cec61ace7b.zip
sdk-eb843e219013194f8f9170837e77b0cec61ace7b.tar.gz
sdk-eb843e219013194f8f9170837e77b0cec61ace7b.tar.bz2
monitor: Display message when plat-tools is missing.
Change-Id: I1feb9abf01b635ca9e5de07aa0a269c773814640
Diffstat (limited to 'eclipse')
-rw-r--r--eclipse/plugins/com.android.ide.eclipse.monitor/src/com/android/ide/eclipse/monitor/MonitorApplication.java8
1 files changed, 8 insertions, 0 deletions
diff --git a/eclipse/plugins/com.android.ide.eclipse.monitor/src/com/android/ide/eclipse/monitor/MonitorApplication.java b/eclipse/plugins/com.android.ide.eclipse.monitor/src/com/android/ide/eclipse/monitor/MonitorApplication.java
index 9c66205..ef8f186 100644
--- a/eclipse/plugins/com.android.ide.eclipse.monitor/src/com/android/ide/eclipse/monitor/MonitorApplication.java
+++ b/eclipse/plugins/com.android.ide.eclipse.monitor/src/com/android/ide/eclipse/monitor/MonitorApplication.java
@@ -29,6 +29,7 @@ import org.eclipse.core.runtime.Path;
import org.eclipse.core.runtime.Platform;
import org.eclipse.equinox.app.IApplication;
import org.eclipse.equinox.app.IApplicationContext;
+import org.eclipse.jface.dialogs.MessageDialog;
import org.eclipse.jface.window.Window;
import org.eclipse.osgi.service.datalocation.Location;
import org.eclipse.swt.widgets.Display;
@@ -63,6 +64,13 @@ public class MonitorApplication implements IApplication {
ILogger sdkLog = NullLogger.getLogger();
SdkManager manager = SdkManager.createManager(sdkPath, sdkLog);
if (manager.getPlatformToolsVersion() == null) {
+ boolean install = MessageDialog.openQuestion(new Shell(display),
+ "Monitor",
+ "The platform tools package that provides adb is missing from your SDK installation. "
+ + "Monitor requires this package to work properly. Would you like to install that package now?");
+ if (!install) {
+ return Integer.valueOf(-1);
+ }
AdtUpdateDialog window = new AdtUpdateDialog(new Shell(display), sdkLog, sdkPath);
window.installPlatformTools();
}