Blob Blame History Raw
From 4024fefade6e4f03891e938307d9860403d6dc0b Mon Sep 17 00:00:00 2001
From: Alexander Kurtakov
Date: Fri, 24 Apr 2015 13:53:38 +0300
Subject: Allow compiling against Mars.

Add stubs for implementing IScrollLockStateProvider interface.
IConsoleView extends it but it's not mandatory for implementation. 

Change-Id: I32d3d4659e1f1dccd396744bf33c3dbd9c5454dc
Signed-off-by: Alexander Kurtakov <akurtako@redhat.com>

diff --git a/core/plugins/org.eclipse.dltk.debug.ui/src/org/eclipse/dltk/debug/ui/display/ScriptDisplayView.java b/core/plugins/org.eclipse.dltk.debug.ui/src/org/eclipse/dltk/debug/ui/display/ScriptDisplayView.java
index fc31a34..2475818 100644
--- a/core/plugins/org.eclipse.dltk.debug.ui/src/org/eclipse/dltk/debug/ui/display/ScriptDisplayView.java
+++ b/core/plugins/org.eclipse.dltk.debug.ui/src/org/eclipse/dltk/debug/ui/display/ScriptDisplayView.java
@@ -64,8 +64,8 @@ import org.eclipse.ui.part.PageBookView;
 import org.eclipse.ui.part.PageSwitcher;
 import org.eclipse.ui.progress.IWorkbenchSiteProgressService;
 
-public class ScriptDisplayView extends PageBookView implements IConsoleView,
-		IPropertyChangeListener, IPartListener2 {
+public class ScriptDisplayView extends PageBookView
+		implements IConsoleView, IPropertyChangeListener, IPartListener2 {
 
 	/**
 	 * Whether this console is pinned.
@@ -167,9 +167,8 @@ public class ScriptDisplayView extends PageBookView implements IConsoleView,
 	/*
 	 * (non-Javadoc)
 	 * 
-	 * @see
-	 * org.eclipse.ui.part.PageBookView#showPageRec(org.eclipse.ui.part.PageBookView
-	 * .PageRec)
+	 * @see org.eclipse.ui.part.PageBookView#showPageRec(org.eclipse.ui.part.
+	 * PageBookView .PageRec)
 	 */
 	protected void showPageRec(PageRec pageRec) {
 		// don't show the page when pinned, unless this is the first console to
@@ -285,9 +284,8 @@ public class ScriptDisplayView extends PageBookView implements IConsoleView,
 	/*
 	 * (non-Javadoc)
 	 * 
-	 * @see
-	 * org.eclipse.ui.part.PageBookView#doDestroyPage(org.eclipse.ui.IWorkbenchPart
-	 * , org.eclipse.ui.part.PageBookView.PageRec)
+	 * @see org.eclipse.ui.part.PageBookView#doDestroyPage(org.eclipse.ui.
+	 * IWorkbenchPart , org.eclipse.ui.part.PageBookView.PageRec)
 	 */
 	protected void doDestroyPage(IWorkbenchPart part, PageRec pageRecord) {
 		IConsole console = fPartToConsole.get(part);
@@ -343,9 +341,8 @@ public class ScriptDisplayView extends PageBookView implements IConsoleView,
 	/*
 	 * (non-Javadoc)
 	 * 
-	 * @see
-	 * org.eclipse.ui.part.PageBookView#doCreatePage(org.eclipse.ui.IWorkbenchPart
-	 * )
+	 * @see org.eclipse.ui.part.PageBookView#doCreatePage(org.eclipse.ui.
+	 * IWorkbenchPart )
 	 */
 	protected PageRec doCreatePage(IWorkbenchPart dummyPart) {
 		ConsoleWorkbenchPart part = (ConsoleWorkbenchPart) dummyPart;
@@ -357,7 +354,8 @@ public class ScriptDisplayView extends PageBookView implements IConsoleView,
 
 		// initialize page participants
 		final ListenerList participants = new ListenerList();
-		IConsolePageParticipant[] consoleParticipants = getPageParticipants(console);
+		IConsolePageParticipant[] consoleParticipants = getPageParticipants(
+				console);
 		for (int i = 0; i < consoleParticipants.length; i++) {
 			participants.add(consoleParticipants[i]);
 		}
@@ -389,9 +387,8 @@ public class ScriptDisplayView extends PageBookView implements IConsoleView,
 	/*
 	 * (non-Javadoc)
 	 * 
-	 * @see
-	 * org.eclipse.ui.part.PageBookView#isImportant(org.eclipse.ui.IWorkbenchPart
-	 * )
+	 * @see org.eclipse.ui.part.PageBookView#isImportant(org.eclipse.ui.
+	 * IWorkbenchPart )
 	 */
 	protected boolean isImportant(IWorkbenchPart part) {
 		return part instanceof ConsoleWorkbenchPart;
@@ -538,9 +535,8 @@ public class ScriptDisplayView extends PageBookView implements IConsoleView,
 	/*
 	 * (non-Javadoc)
 	 * 
-	 * @see
-	 * org.eclipse.ui.console.IConsoleView#display(org.eclipse.ui.console.IConsole
-	 * )
+	 * @see org.eclipse.ui.console.IConsoleView#display(org.eclipse.ui.console.
+	 * IConsole )
 	 */
 	public void display(IConsole console) {
 		if (fPinned && fActiveConsole != null) {
@@ -630,7 +626,8 @@ public class ScriptDisplayView extends PageBookView implements IConsoleView,
 
 	private void createDebugConsole() {
 		addConsole(new DebugConsole(Messages.ScriptDisplayView_consoleName,
-				DebugConsole.class.getName(), new DebugScriptInterpreter(this)));
+				DebugConsole.class.getName(),
+				new DebugScriptInterpreter(this)));
 	}
 
 	/**
@@ -669,8 +666,8 @@ public class ScriptDisplayView extends PageBookView implements IConsoleView,
 	}
 
 	public IConsole[] getConsoles() {
-		return fConsoleToPart.keySet().toArray(
-				new IConsole[fConsoleToPart.size()]);
+		return fConsoleToPart.keySet()
+				.toArray(new IConsole[fConsoleToPart.size()]);
 	}
 
 	/**
@@ -923,4 +920,12 @@ public class ScriptDisplayView extends PageBookView implements IConsoleView,
 	public void removeConsoleListener(IEvaluateConsoleListener listener) {
 		consoleListeners.remove(listener);
 	}
+
+	public void setAutoScrollLock(boolean scrollLock) {
+		// Ignore as not implemented
+	}
+
+	public boolean getAutoScrollLock() {
+		return false;
+	}
 }
-- 
cgit v0.10.1-9-gd18e