|
From: <caw...@us...> - 2007-01-19 21:23:17
|
Revision: 1826
http://svn.sourceforge.net/rubyeclipse/?rev=1826&view=rev
Author: cawilliams
Date: 2007-01-19 13:23:16 -0800 (Fri, 19 Jan 2007)
Log Message:
-----------
just try to get back to building properly...
Modified Paths:
--------------
trunk/org.rubypeople.rdt.ui/src/org/rubypeople/rdt/internal/ui/infoviews/RIView.java
trunk/org.rubypeople.rdt.ui/src/org/rubypeople/rdt/internal/ui/rdocexport/RDocUtility.java
trunk/org.rubypeople.rdt.ui/src/org/rubypeople/rdt/internal/ui/text/ruby/hover/RiDocHoverProvider.java
Modified: trunk/org.rubypeople.rdt.ui/src/org/rubypeople/rdt/internal/ui/infoviews/RIView.java
===================================================================
--- trunk/org.rubypeople.rdt.ui/src/org/rubypeople/rdt/internal/ui/infoviews/RIView.java 2007-01-19 21:17:23 UTC (rev 1825)
+++ trunk/org.rubypeople.rdt.ui/src/org/rubypeople/rdt/internal/ui/infoviews/RIView.java 2007-01-19 21:23:16 UTC (rev 1826)
@@ -46,6 +46,7 @@
import org.rubypeople.rdt.internal.ui.rdocexport.RdocListener;
import org.rubypeople.rdt.launching.IVMInstall;
import org.rubypeople.rdt.launching.IVMInstallChangedListener;
+import org.rubypeople.rdt.launching.IVMRunner;
import org.rubypeople.rdt.launching.PropertyChangeEvent;
import org.rubypeople.rdt.launching.RubyRuntime;
import org.rubypeople.rdt.ui.PreferenceConstants;
@@ -228,6 +229,7 @@
private void initSearchList() {
RubyInvoker invoker = new RubyInvoker() {
protected void handleOutput(Process process) {
+ if (process == null) return;
riFound = false;
BufferedReader reader = new BufferedReader(new InputStreamReader(process.getInputStream()));
String line = null;
@@ -318,6 +320,7 @@
}
protected void handleOutput(final Process process) {
+ if (process == null) return;
// any output?
final StreamRedirector outputRedirect = new StreamRedirector(process.getInputStream(), "");
// kick them off
@@ -379,15 +382,17 @@
return;
}
- try {
+// try {
List args = getArgList();
args.add(0, riPath.toString());
- final Process p = RubyRuntime.getDefault().getDefaultVMInstall().exec(args, null);
+ IVMRunner runner = RubyRuntime.getDefaultVMInstall().getVMRunner("run");
+ // XXX How in the world do we do these quick little background launches and grab the process?
+ final Process p = null;
handleOutput(p);
- } catch (CoreException coreException) {
- // message of RuntimeException will be displayed in the RI View
- throw new RuntimeException(coreException.getStatus().getMessage());
- }
+// } catch (CoreException coreException) {
+// // message of RuntimeException will be displayed in the RI View
+// throw new RuntimeException(coreException.getStatus().getMessage());
+// }
}
}
Modified: trunk/org.rubypeople.rdt.ui/src/org/rubypeople/rdt/internal/ui/rdocexport/RDocUtility.java
===================================================================
--- trunk/org.rubypeople.rdt.ui/src/org/rubypeople/rdt/internal/ui/rdocexport/RDocUtility.java 2007-01-19 21:17:23 UTC (rev 1825)
+++ trunk/org.rubypeople.rdt.ui/src/org/rubypeople/rdt/internal/ui/rdocexport/RDocUtility.java 2007-01-19 21:23:16 UTC (rev 1826)
@@ -85,7 +85,7 @@
public final void invoke() {
log("Generating RDoc for " + resource.getName());
- IVMInstall interpreter = RubyRuntime.getDefault().getDefaultVMInstall();
+ IVMInstall interpreter = RubyRuntime.getDefaultVMInstall();
if (interpreter == null) {
MessageDialog.openInformation(RubyPlugin.getActiveWorkbenchShell(), LaunchingMessages.RdtLaunchingPlugin_noInterpreterSelectedTitle, LaunchingMessages.RdtLaunchingPlugin_noInterpreterSelected);
return ;
@@ -108,14 +108,16 @@
args.add(rdocPath.toString());
args.add("-r");
args.add(resource.getLocation().toOSString());
- try {
- final Process p = interpreter.exec(args, null);
+// try {
+ // XXX How do we do quick background launches of the interpreter?
+// final Process p = interpreter.exec(args, null);
+ final Process p = null;
handleOutput(p, args);
- } catch (CoreException e) {
- RubyPlugin.log(e);
- log(e.getMessage());
- ErrorDialog.openError(RubyPlugin.getActiveWorkbenchShell(), RubyUIMessages.getString("ErrorRunningRdocTitle"), e.getMessage(), new StatusInfo(StatusInfo.ERROR, e.getMessage()));
- }
+// } catch (CoreException e) {
+// RubyPlugin.log(e);
+// log(e.getMessage());
+// ErrorDialog.openError(RubyPlugin.getActiveWorkbenchShell(), RubyUIMessages.getString("ErrorRunningRdocTitle"), e.getMessage(), new StatusInfo(StatusInfo.ERROR, e.getMessage()));
+// }
}
/**
Modified: trunk/org.rubypeople.rdt.ui/src/org/rubypeople/rdt/internal/ui/text/ruby/hover/RiDocHoverProvider.java
===================================================================
--- trunk/org.rubypeople.rdt.ui/src/org/rubypeople/rdt/internal/ui/text/ruby/hover/RiDocHoverProvider.java 2007-01-19 21:17:23 UTC (rev 1825)
+++ trunk/org.rubypeople.rdt.ui/src/org/rubypeople/rdt/internal/ui/text/ruby/hover/RiDocHoverProvider.java 2007-01-19 21:23:16 UTC (rev 1826)
@@ -36,7 +36,10 @@
args.add(symbol);
IVMInstall selectedInterpreter = RubyRuntime.getDefault().getDefaultVMInstall();
if (selectedInterpreter == null) return null;
- Process p = selectedInterpreter.exec(args, null);
+// XXX How in the world do we do these quick little background launches and grab the process?
+// Process p = selectedInterpreter.exec(args, null);
+ Process p = null;
+ if (p == null) return null;
br = new BufferedReader(new InputStreamReader(p.getInputStream()));
// TODO: format the documentation that was fetched from RI
// for now: read the first 15 lines so
@@ -55,8 +58,8 @@
return "" + buf.toString();
} catch (BadLocationException e) {
RubyPlugin.log(e);
- } catch (CoreException e) {
- RubyPlugin.log(e);
+// } catch (CoreException e) {
+// RubyPlugin.log(e);
} catch (IOException e) {
RubyPlugin.log(e);
} finally {
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|