|
Lines 13-19
Link Here
|
| 13 |
*******************************************************************************/ |
13 |
*******************************************************************************/ |
| 14 |
package org.eclipse.ui.internal; |
14 |
package org.eclipse.ui.internal; |
| 15 |
|
15 |
|
|
|
16 |
import org.eclipse.core.runtime.IStatus; |
| 16 |
import org.eclipse.jface.action.IMenuManager; |
17 |
import org.eclipse.jface.action.IMenuManager; |
|
|
18 |
import org.eclipse.ui.IMemento; |
| 17 |
import org.eclipse.ui.internal.presentations.PresentablePart; |
19 |
import org.eclipse.ui.internal.presentations.PresentablePart; |
| 18 |
import org.eclipse.ui.internal.presentations.PresentationFactoryUtil; |
20 |
import org.eclipse.ui.internal.presentations.PresentationFactoryUtil; |
| 19 |
import org.eclipse.ui.internal.presentations.SystemMenuDetach; |
21 |
import org.eclipse.ui.internal.presentations.SystemMenuDetach; |
|
Lines 95-100
Link Here
|
| 95 |
return false; |
97 |
return false; |
| 96 |
} |
98 |
} |
| 97 |
|
99 |
|
|
|
100 |
// Durable folders should not move |
| 101 |
if (durable) { |
| 102 |
return false; |
| 103 |
} |
| 104 |
|
| 98 |
// We need to search if one of the presentations is not moveable |
105 |
// We need to search if one of the presentations is not moveable |
| 99 |
// if that's the case the whole folder should not be moveable |
106 |
// if that's the case the whole folder should not be moveable |
| 100 |
IStackPresentationSite presenationSite; |
107 |
IStackPresentationSite presenationSite; |
|
Lines 227-230
Link Here
|
| 227 |
public boolean getDurable () { |
234 |
public boolean getDurable () { |
| 228 |
return this.durable; |
235 |
return this.durable; |
| 229 |
} |
236 |
} |
|
|
237 |
|
| 238 |
public IStatus saveState(IMemento memento) { |
| 239 |
memento.putBoolean(IWorkbenchConstants.TAG_DURABLE, durable); |
| 240 |
return super.saveState(memento); |
| 241 |
} |
| 242 |
|
| 243 |
public IStatus restoreState(IMemento memento) { |
| 244 |
Boolean result = memento.getBoolean(IWorkbenchConstants.TAG_DURABLE); |
| 245 |
if (result != null) { |
| 246 |
this.durable = result.booleanValue(); |
| 247 |
} |
| 248 |
return super.restoreState(memento); |
| 249 |
} |
| 230 |
} |
250 |
} |